lib/rio/context.rb in rio-0.5.1 vs lib/rio/context.rb in rio-0.6.0

- old
+ new

@@ -1,8 +1,8 @@ #-- # =========================================================================== -# Copyright (c) 2005-2012 Christopher Kleckner +# Copyright (c) 2005-2017 Christopher Kleckner # All rights reserved # # This file is part of the Rio library for ruby. # # Rio is free software; you can redistribute it and/or modify @@ -39,11 +39,10 @@ super @values = @values.clone @explicit = @explicit.clone end BEQUEATH_KEYS = %w[chomp strip rename closeoneof closeoncopy] - #BEQUEATH_KEYS = %w[chomp strip rename] def bequeath(oldcx) keys = BEQUEATH_KEYS ncx = oldcx.clone #ncx = Vars.new keys.each { |key| @@ -111,10 +110,15 @@ str += strs.join(',') str +='>' str end - extend Forwardable - def_instance_delegators(:@values,:[],:has_key?,:values_at,:keys) + extend RIO::Fwd + fwd_readers :@values, + :has_key?, + :values_at, + :keys, + :[] + end end end