mirror of
				https://github.com/ruby/ruby.git
				synced 2022-11-09 12:17:21 -05:00 
			
		
		
		
	Fix warnings in test_optimization.rb
These were introduced in the test for tracing optimized methods
added in 48c8df9e0e.
			
			
This commit is contained in:
		
							parent
							
								
									bbedd29b6e
								
							
						
					
					
						commit
						14a9c364f7
					
				
					 1 changed files with 7 additions and 6 deletions
				
			
		|  | @ -158,7 +158,7 @@ class TestRubyOptimization < Test::Unit::TestCase | |||
|       methods = [] | ||||
|       tp = TracePoint.new(type) { |tp| methods << tp.method_id } | ||||
|       tp.enable do | ||||
|         x = "a"; -x | ||||
|         x = "a"; x = -x | ||||
|         [1].max | ||||
|         [1].min | ||||
|         x = 42 + 2 | ||||
|  | @ -166,11 +166,11 @@ class TestRubyOptimization < Test::Unit::TestCase | |||
|         x = 42 * 2 | ||||
|         x = 42 / 2 | ||||
|         x = 42 % 2 | ||||
|         x == 42 | ||||
|         x < 42 | ||||
|         x <= 42 | ||||
|         x > 42 | ||||
|         x >= 42 | ||||
|         y = x == 42 | ||||
|         y = x < 42 | ||||
|         y = x <= 42 | ||||
|         y = x > 42 | ||||
|         y = x >= 42 | ||||
|         x = x << 1 | ||||
|         x = x & 1 | ||||
|         x = x | 1 | ||||
|  | @ -182,6 +182,7 @@ class TestRubyOptimization < Test::Unit::TestCase | |||
|         x = 1; x.succ | ||||
|         !x | ||||
|         x = 'a'; x =~ /a/ | ||||
|         x = y | ||||
|       end | ||||
|       assert_equal(expected, methods, bug14870) | ||||
|     end | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Jeremy Evans
						Jeremy Evans