lib/rconf/platform.rb in rconf-0.9.18 vs lib/rconf/platform.rb in rconf-0.9.19

- old
+ new

@@ -61,18 +61,18 @@ # e.g. # # Platform.dispatch(2) { :echo } # # will result in 'echo_linux(2)' being executed in self if running on linux, - # 'echo_windows(2)' if running on Windows and 'echo_darwin(2)' if on + # 'echo_windows(2)' if running on Windows and 'echo_darwin(2)' if on # Mac OS X. Note that the method is run in the instance of the caller. # # === Parameters # args:: Pass-through arguments # # === Block - # Given block should not take any argument and return a symbol for the + # Given block should not take any argument and return a symbol for the # method that should be called # # === Return # res(ObjecT):: Result returned by platform specific implementation def dispatch(*args, &blk) @@ -80,10 +80,10 @@ binding = blk.binding.eval('self') meth = blk.call target = dispatch_candidates(meth).detect do |candidate| binding.respond_to?(candidate) end - raise "No platform dispatch target found in #{binding.class} for " + + raise "No platform dispatch target found in #{binding.class} for " + "'#{meth.inspect}', tried " + dispatch_candidates(meth).join(', ') unless target binding.__send__(target, *args) end protected