mirror of
				https://github.com/tc39/test262.git
				synced 2025-10-31 03:34:08 +01:00 
			
		
		
		
	sourceRevisionAtLastExport: 33f2fb0e53d135f0ee17cfccd9d993eb2a6f47de targetRevisionAtLastExport: 31340cbd9add103f586d501b0c3354b7b182abc0
		
			
				
	
	
		
			49 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			49 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| // Copyright 2017 the V8 project authors. All rights reserved.
 | |
| // Use of this source code is governed by a BSD-style license that can be
 | |
| // found in the LICENSE file.
 | |
| 
 | |
| 
 | |
| (function TestSmi() {
 | |
|   var v_0 = {};
 | |
|   function f_0(constructor, closure) {
 | |
|     var v_2 = { value: 0 };
 | |
|     v_4 = closure(constructor, 1073741823, v_0, v_2);
 | |
|     assertEquals(1, v_2.value);
 | |
|   }
 | |
|   function f_1(constructor, val, deopt, v_2) {
 | |
|     if (!new constructor(val, deopt, v_2)) {
 | |
|     }
 | |
|   }
 | |
|   function f_10(constructor) {
 | |
|     f_0(constructor, f_1);
 | |
|     f_0(constructor, f_1);
 | |
|     f_0(constructor, f_1);
 | |
|   }
 | |
|   function f_12(val, deopt, v_2) {
 | |
|     v_2.value++;
 | |
|   }
 | |
|   f_10(f_12);
 | |
| })();
 | |
| 
 | |
| (function TestHeapNumber() {
 | |
|   var v_0 = {};
 | |
|   function f_0(constructor, closure) {
 | |
|     var v_2 = { value: 1.5 };
 | |
|     v_4 = closure(constructor, 1073741823, v_0, v_2);
 | |
|     assertEquals(2.5, v_2.value);
 | |
|   }
 | |
|   function f_1(constructor, val, deopt, v_2) {
 | |
|     if (!new constructor(val, deopt, v_2)) {
 | |
|     }
 | |
|   }
 | |
|   function f_10(constructor) {
 | |
|     f_0(constructor, f_1);
 | |
|     f_0(constructor, f_1);
 | |
|     f_0(constructor, f_1);
 | |
|   }
 | |
|   function f_12(val, deopt, v_2) {
 | |
|     v_2.value++;
 | |
|   }
 | |
|   f_10(f_12);
 | |
| })();
 |