[MacRuby] #1266: NameError: `@_save_parents:_sentinel' is not allowed as an instance variable name
MacRuby
ruby-noreply at macosforge.org
Thu May 5 18:22:05 PDT 2011
#1266: NameError: `@_save_parents:_sentinel' is not allowed as an instance
variable name
------------------------------+---------------------------------------------
Reporter: jhamor@… | Owner: lsansonetti@…
Type: defect | Status: new
Priority: blocker | Milestone:
Component: MacRuby | Keywords:
------------------------------+---------------------------------------------
Comment(by lsansonetti@…):
{{{
def run_once(default)
caller_method = Kernel.caller(1).first[/`([^'?!]+)[?!]?'/, 1]
sentinel = "@_#{caller_method}_sentinel"
return instance_variable_get(sentinel) if
instance_variable_defined?(sentinel)
}}}
I suspect that here #caller returns selectors with the trailing ':'
character.
--
Ticket URL: <http://www.macruby.org/trac/ticket/1266#comment:2>
MacRuby <http://macruby.org/>
More information about the macruby-tickets
mailing list