mirror of
				https://github.com/tc39/test262.git
				synced 2025-11-04 05:33:50 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			20 lines
		
	
	
		
			615 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			20 lines
		
	
	
		
			615 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
// Copyright (C) 2018 Kevin Gibbons. All rights reserved.
 | 
						|
// This code is governed by the BSD license found in the LICENSE file.
 | 
						|
 | 
						|
/*---
 | 
						|
esid: sec-object.fromentries
 | 
						|
description: When given an empty list, makes an empty object.
 | 
						|
info: |
 | 
						|
  Object.fromEntries ( iterable )
 | 
						|
 | 
						|
  ...
 | 
						|
  4. Let stepsDefine be the algorithm steps defined in CreateDataPropertyOnObject Functions.
 | 
						|
  5. Let adder be CreateBuiltinFunction(stepsDefine, « »).
 | 
						|
  6. Return ? AddEntriesFromIterable(obj, iterable, adder).
 | 
						|
 | 
						|
features: [Object.fromEntries]
 | 
						|
---*/
 | 
						|
 | 
						|
var result = Object.fromEntries([]);
 | 
						|
assert.sameValue(Object.keys(result).length, 0);
 |