[MacRuby-devel] [MacRuby] #293: Object.methods in macirb returns crazy results

MacRuby ruby-noreply at macosforge.org
Wed Jul 8 18:18:13 PDT 2009


#293: Object.methods in macirb returns crazy results
-------------------------------+--------------------------------------------
 Reporter:  tjw@…              |       Owner:  lsansonetti@…        
     Type:  defect             |      Status:  new                  
 Priority:  blocker            |   Milestone:                       
Component:  MacRuby            |    Keywords:                       
-------------------------------+--------------------------------------------
 Experimental, r2001

 Using this method prints out the methods, and then a bunch of source and
 corrupted bytes afterward:

 irb(main):003:0> Object.methods
 => [:define_method, :public_instance_method, :instance_method, :autoload?,
 :autoload, :private_class_method, :public_class_method,
 :protected_method_defined?, :private_method_defined?,
 :public_method_defined?, :method_defined?, :module_function, :private,
 :protected, :public, :alias_method, :undef_method, :remove_method,
 :class_exec, :module_exec, :class_eval, :module_eval, :include,
 :extend_object, :append_features, :allocate, :class_variable_defined?,
 :class_variable_set, :class_variable_get, :remove_class_variable,
 :class_variables, :const_missing, :remove_const, :const_defined?,
 :const_set, :const_get, :constants, :private_instance_methods,
 :protected_instance_methods, :public_instance_methods, :instance_methods,
 :attr_accessor, :attr_writer, :attr_reader, :attr, :__meta__?, :ib_outlet,
 :ancestors, :name, :include?, :included_modules, :to_s, :initialize_copy,
 :>=, :>, :<=, :<, :<=>, :==, :===, :freeze, :method_signature,
 :method_undefined, :method_removed, :method_added, :extended, :included,
 :inherited, :new, :irb_current_working_workspace, :irb_change_workspace,
 :irb_workspaces, :irb_push_workspace, :irb_pop_workspace, :irb_load,
 :irb_require, :irb_source, :irb, :irb_jobs, :irb_fg, :irb_kill, :irb_help,
 :default_src_encoding, :irb_binding, :load_bridge_support_file, :enum_for,
 :to_enum, :object_id, :__id__, :binding, :define_singleton_method,
 :public_method, :method, :lambda, :proc, :framework, :require, :load,
 :abort, :exit, :sleep, :spawn, :system, :exit!, :fork, :exec, :trap,
 :rand, :srand, :test, :display, :p, :`, :readlines, :select, :readline,
 :gets, :puts, :putc, :print, :printf, :open, :syscall, :at_exit,
 :untrace_var, :trace_var, :extend, :respond_to?, :caller, :public_send,
 :send, :__send__, :method_missing, :instance_exec, :instance_eval, :loop,
 :throw, :catch, :__callee__, :__method__, :local_variables,
 :global_variables, :fail, :raise, :block_given?, :iterator?, :eval,
 :Array, :String, :Float, :Integer, :format, :sprintf, :__native__?, :tap,
 :is_a?, :kind_of?, :instance_of?, :remove_instance_variable,
 :instance_variable_defined?, :instance_variable_set,
 :instance_variable_get, :instance_variables, :public_methods,
 :private_methods, :protected_methods, :singleton_methods, :methods,
 :inspect, :frozen?, :untaint, :tainted?, :taint, :dup, :clone, :eql?, :!~,
 :=~, :nil?, :singleton_method_undefined, :singleton_method_removed,
 :singleton_method_added, :!=, :!, :equal?, :initialize, :hash]equal?,
 :initialize, :hash]_char_no == 0 && peek(0) =~ /\s/}) do
       |op, io|
       @ltype = "="
       until getc == "\n"; end
       until peek_equal?("=end") && peek(4) =~ /\s/
         until getc == "\n"; end
       end
       gets
       @ltype = nil
       Token(TkRD_COMMENT)
     end
 ...

       |op, io|
       identify_string(op)
     end

     @OP.=> ????????
 irb(main):004:0>

-- 
Ticket URL: <http://www.macruby.org/trac/ticket/293>
MacRuby <http://macruby.org/>



More information about the MacRuby-devel mailing list