History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: JRUBY-2247
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Critical Critical
Assignee: Vladimir Sizikov
Reporter: Vladimir Sizikov
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
JRuby

Object#methods is incorrect in some cases

Created: 08/Mar/08 11:30 AM   Updated: 04/Jul/08 09:07 AM
Component/s: Core Classes/Modules
Affects Version/s: JRuby 1.1RC2
Fix Version/s: JRuby 1.1.2

Time Tracking:
Not Specified

File Attachments: 1. Text File jruby-2247-v2.patch (2 kb)
2. Text File jruby-2247.patch (3 kb)

Environment: JRuby 1.1RC2
Issue Links:
Duplicate
 
Related
 


 Description  « Hide
1. Time.methods doesn't return "now" method:

Time.methods.grep('now') == > []

2. In MRI: Time.methods(false) => ["at", "utc", "_load", "today", "mktime", "now", "local", "times", "gm"]
But JRuby's implementation of "methods" with false argument always returns [].



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Thomas E Enebo - 17/Mar/08 06:20 PM
Not enough time...punting

Vladimir Sizikov - 19/Mar/08 12:09 PM
Most propbably releated to JRUBY-1166.

Vladimir Sizikov - 28/Apr/08 12:17 PM
Raising the priority of this issue, looks like important functionality is seriously broken.

Daniel Luz - 10/May/08 10:15 PM
This patch does the minimum needed to fix this particular bug. It does not fix completely JRUBY-1166, for instance, which has some unrelated parts.

A small summary of the fix: the generated source files from apt were declaring singleton methods with implementationClass == module, when they should point to the module's singleton class.


Daniel Luz - 10/May/08 10:55 PM
Eh, for some reason I completely ignored setImplementationClass. No need to add a new method.

Vladimir Sizikov - 24/May/08 02:50 PM
Resolved in rev. r6779 on trunk.

Patch by Daniel Luz.. Thanks!!