Details

    • Type: New Feature New Feature
    • Status: Closed Closed
    • Priority: Minor Minor
    • Resolution: Not A Bug
    • Affects Version/s: JRuby 1.5.6, JRuby 1.6.1
    • Fix Version/s: None
    • Labels:
      None
    • Number of attachments :
      0

      Description

      In MRI, procs have properties _line_ and _file_. The method call

      lambda {}._line_

      succeeds. In JRuby, this call fails with

      NoMethodError: undefined method `_line_' for #<Proc:...

      The linenumber is available in the class, as it is shown in inspect:

      "#<Proc:0x56f449b8@(irb):3>"

      I've browsed through the sources a bit, but didn't see where it was appended.

      Rubinius doesn't implement _line_ either BTW.

        Activity

        Hide
        Thomas E Enebo added a comment -

        I don't see these in MRI in 1.8.7 or 1.9.2? In source or from the command-line? Does maybe a library you use add these somehow?

        Show
        Thomas E Enebo added a comment - I don't see these in MRI in 1.8.7 or 1.9.2? In source or from the command-line? Does maybe a library you use add these somehow?
        Hide
        Ivo Wever added a comment -

        Ah, we've always used Ruby Enterprise Edition and I've come to equate it to 'MRI', but in this case there is a difference. It seems these methods are specific to Ruby Enterprise. Sorry for the unnecessary issue; close as 'Not a Bug'?

        Show
        Ivo Wever added a comment - Ah, we've always used Ruby Enterprise Edition and I've come to equate it to 'MRI', but in this case there is a difference. It seems these methods are specific to Ruby Enterprise. Sorry for the unnecessary issue; close as 'Not a Bug'?
        Hide
        Thomas E Enebo added a comment -

        I am marking as not a bug based on this being an implementation-specific feature of REE.

        Show
        Thomas E Enebo added a comment - I am marking as not a bug based on this being an implementation-specific feature of REE.

          People

          • Assignee:
            Thomas E Enebo
            Reporter:
            Ivo Wever
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: