[regression] Recent JumpTarget refactoring breaks 29 proc rubyspecs in 1.9 mode
-------------------------------------------------------------------------------

                 Key: JRUBY-4457
                 URL: http://jira.codehaus.org/browse/JRUBY-4457
             Project: JRuby
          Issue Type: Bug
          Components: Core Classes/Modules, Ruby 1.9, RubySpec
    Affects Versions: JRuby 1.5
            Reporter: Vladimir Sizikov
            Assignee: Charles Oliver Nutter
            Priority: Critical
             Fix For: JRuby 1.5


The following commit: 

{code}
[3587b5568a35e5b1b2e6fade9365d8b329a0b912] Replace the JumpTarget class with an 
int wherever it's used, to help ensure it will be unique (within a given 
thread). Also includes a replacement of catch/throw logic with "one-shot" 
callcc logic to avoid the need for ThrowJump and JumpTarget in catch logic.
{code}

Leads to 29 new proc rubyspec failures in 1.9 mode:

{noformat}
mspec ci -t j -T --1.9  core/proc
jruby 1.5.0.dev (ruby 1.9.2dev trunk 24787) (2010-01-12 9cf69a6) (Java 
HotSpot(TM) Client VM 1.6.0_03) [i386-java]
...........................................................EEEEEEEEEEEEEEEE.FEEEEEEEEFFEE

1)
Proc#parameters returns an empty Array for a proc expecting no parameters ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x1931579>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:6
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

2)
Proc#parameters returns an Array of Arrays for a proc expecting parameters ERROR
NoMethodError: undefined method `parameters' for #<Proc:0xbd09e8>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:11
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

3)
Proc#parameters sets the first element of each sub-Array to :opt for optional 
arguments ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x14627a>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:16
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

4)
Proc#parameters regards named parameters in procs as optional ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x20807c>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:21
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

5)
Proc#parameters regards parameters with default values as optional ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x16d835f>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:25
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

6)
Proc#parameters sets the first element of each sub-Array to :req for required 
arguments ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x10a5c21>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:30
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

7)
Proc#parameters regards named parameters in lambdas as required ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x739f3f>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:35
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

8)
Proc#parameters sets the first element of each sub-Array to :rest for 
parameters prefixed with asterisks ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x98350a>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:39
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

9)
Proc#parameters sets the first element of each sub-Array to :block for 
parameters prefixed with ampersands ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x15f4a7f>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:46
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

10)
Proc#parameters sets the second element of each sub-Array to the name of the 
argument ERROR
NoMethodError: undefined method `parameters' for #<Proc:0x156b386>
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:53
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:4
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:3
/opt/work/rubyspec.git/core/proc/versions/parameters_1.9.rb:23:in `require'
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:1
/opt/work/rubyspec.git/core/proc/parameters_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

11)
Proc#source_location returns an Array ERROR
NoMethodError: undefined method `source_location' for #<Proc:0x1cbfa42>
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:13
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:5
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:4
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

12)
Proc#source_location sets the first value to the path of the file in which the 
proc was defined ERROR
NoMethodError: undefined method `source_location' for #<Proc:0x1de4dd8>
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:19
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:5
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:4
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

13)
Proc#source_location sets the last value to a Fixnum representing the line on 
which the proc was defined ERROR
NoMethodError: undefined method `source_location' for #<Proc:0x3f4ebd>
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:33
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:5
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:4
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

14)
Proc#source_location works even if the proc was created on the same line ERROR
NoMethodError: undefined method `source_location' for #<Proc:0x1fcf790>
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:47
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:5
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:4
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

15)
Proc#source_location returns the first line of a multi-line proc (i.e. the line 
containing 'proc do') ERROR
NoMethodError: undefined method `source_location' for #<Proc:0x1a7789c>
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:53
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:5
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:4
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

16)
Proc#source_location returns the location of the proc's body; not necessarily 
the proc itself ERROR
NoMethodError: undefined method `source_location' for #<Proc:0x1de891b>
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:59
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:5
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:4
/opt/work/rubyspec.git/core/proc/source_location_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

17)
Proc#to_s returns a description of self FAILED
Expected "#<Proc:0x44d990@/opt/work/rubyspec.git/core/proc/to_s_spec.rb:16>"
to match /^#<Proc:(.*?)@(.*)\/to_s_spec\.rb:16 \(lambda\)>$/

/opt/work/rubyspec.git/core/proc/to_s_spec.rb:16
/opt/work/rubyspec.git/core/proc/to_s_spec.rb:3
/opt/work/rubyspec.git/core/proc/to_s_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

18)
Proc#yield invokes self ERROR
NoMethodError: undefined method `yield' for #<Proc:0x87e704>
/opt/work/rubyspec.git/core/proc/shared/call.rb:3
/opt/work/rubyspec.git/core/proc/yield_spec.rb:7
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

19)
Proc#yield sets self's parameters to the given values ERROR
NoMethodError: undefined method `yield' for #<Proc:0x135f44e>
/opt/work/rubyspec.git/core/proc/shared/call.rb:9
/opt/work/rubyspec.git/core/proc/yield_spec.rb:7
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

20)
Proc#yield can receive block arguments ERROR
NoMethodError: undefined method `yield' for #<Proc:0x20c906>
/opt/work/rubyspec.git/core/proc/shared/call_arguments.rb:3
/opt/work/rubyspec.git/core/proc/yield_spec.rb:7
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

21)
Proc#yield on a Proc created with Proc.new replaces missing arguments with nil 
ERROR
NoMethodError: undefined method `yield' for #<Proc:0x1263db>
/opt/work/rubyspec.git/core/proc/shared/call.rb:48
/opt/work/rubyspec.git/core/proc/yield_spec.rb:12
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

22)
Proc#yield on a Proc created with Proc.new silently ignores extra arguments 
ERROR
NoMethodError: undefined method `yield' for #<Proc:0x1469658>
/opt/work/rubyspec.git/core/proc/shared/call.rb:53
/opt/work/rubyspec.git/core/proc/yield_spec.rb:12
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

23)
Proc#yield on a Proc created with Proc.new auto-explodes a single Array 
argument ERROR
NoMethodError: undefined method `yield' for #<Proc:0x158689a>
/opt/work/rubyspec.git/core/proc/shared/call.rb:58
/opt/work/rubyspec.git/core/proc/yield_spec.rb:12
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

24)
Proc#yield on a Proc created with Kernel#lambda or Kernel#proc ignores excess 
arguments when self is a proc ERROR
NoMethodError: undefined method `yield' for #<Proc:0x1a0b53e>
/opt/work/rubyspec.git/core/proc/shared/call.rb:89
/opt/work/rubyspec.git/core/proc/yield_spec.rb:16
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

25)
Proc#yield on a Proc created with Kernel#lambda or Kernel#proc substitutes nil 
for missing arguments when self is a proc ERROR
NoMethodError: undefined method `yield' for #<Proc:0x1a8d460>
/opt/work/rubyspec.git/core/proc/shared/call.rb:97
/opt/work/rubyspec.git/core/proc/yield_spec.rb:16
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

26)
Proc#yield on a Proc created with Kernel#lambda or Kernel#proc raises an 
ArgumentError on excess arguments when self is a lambda FAILED
Expected ArgumentError
but got NoMethodError (undefined method `yield' for #<Proc:0x3228a1>)
/opt/work/rubyspec.git/core/proc/shared/call.rb:104
/opt/work/rubyspec.git/core/proc/yield_spec.rb:16
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

27)
Proc#yield on a Proc created with Kernel#lambda or Kernel#proc raises an 
ArgumentError on missing arguments when self is a lambda FAILED
Expected ArgumentError
but got NoMethodError (undefined method `yield' for #<Proc:0xedbe39>)
/opt/work/rubyspec.git/core/proc/shared/call.rb:114
/opt/work/rubyspec.git/core/proc/yield_spec.rb:16
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

28)
Proc#yield on a Proc created with Kernel#lambda or Kernel#proc treats a single 
Array argument as a single argument when self is a lambda ERROR
NoMethodError: undefined method `yield' for #<Proc:0x15c97e4>
/opt/work/rubyspec.git/core/proc/shared/call.rb:124
/opt/work/rubyspec.git/core/proc/yield_spec.rb:16
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

29)
Proc#yield on a Proc created with Kernel#lambda or Kernel#proc treats a single 
Array argument as a single argument when self is a proc ERROR
NoMethodError: undefined method `yield' for #<Proc:0x23bdd1>
/opt/work/rubyspec.git/core/proc/shared/call.rb:129
/opt/work/rubyspec.git/core/proc/yield_spec.rb:16
/opt/work/rubyspec.git/core/proc/yield_spec.rb:6
/opt/work/rubyspec.git/core/proc/yield_spec.rb:55:in `load'
/opt/work/mspec.git/bin/mspec-ci:8

Finished in 0.511000 seconds
{noformat}

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to