JRuby (please use github issues at http://bugs.jruby.org)
  1. JRuby (please use github issues at http://bugs.jruby.org)
  2. JRUBY-6581

"yield called out of block" for Enumerators created with enum_for

    Details

    • Type: Bug Bug
    • Status: Resolved Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: JRuby 1.7.1
    • Component/s: None
    • Labels:
      None
    • Environment:
      jruby 1.6.7 (ruby-1.8.7-p357) (2012-02-22 3e82bc8) (Java HotSpot(TM) Server VM 1.7.0_02) [linux-i386-java]
    • Number of attachments :
      0

      Description

      class Foo
      def each
      yield 1
      end
      end

      enum = Foo.new.enum_for
      puts enum.next #fails with "yield called out of block"

        Activity

        Hide
        Charles Oliver Nutter added a comment -

        Confirmed on master too.

        Show
        Charles Oliver Nutter added a comment - Confirmed on master too.
        Hide
        Thomas E Enebo added a comment -

        Fixed by JRUBY-6995

        Show
        Thomas E Enebo added a comment - Fixed by JRUBY-6995

          People

          • Assignee:
            Thomas E Enebo
            Reporter:
            John Pelly
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: