Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2)

Side by Side Diff: src/js/v8natives.js

Issue 1441043002: [proxies] Implement [[PreventExtensions]] and [[IsExtensible]]. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Various changes. Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/builtins.cc ('k') | src/messages.h » ('j') | src/objects.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 (function(global, utils) { 5 (function(global, utils) {
6 6
7 %CheckIsBootstrapping(); 7 %CheckIsBootstrapping();
8 8
9 // ---------------------------------------------------------------------------- 9 // ----------------------------------------------------------------------------
10 // Imports 10 // Imports
(...skipping 1203 matching lines...) Expand 10 before | Expand all | Expand 10 after
1214 if (IsDataDescriptor(desc) && desc.isWritable()) return false; 1214 if (IsDataDescriptor(desc) && desc.isWritable()) return false;
1215 if (desc.isConfigurable()) return false; 1215 if (desc.isConfigurable()) return false;
1216 } 1216 }
1217 return true; 1217 return true;
1218 } 1218 }
1219 1219
1220 1220
1221 // ES5 section 15.2.3.13 1221 // ES5 section 15.2.3.13
1222 function ObjectIsExtensible(obj) { 1222 function ObjectIsExtensible(obj) {
1223 if (!IS_SPEC_OBJECT(obj)) return false; 1223 if (!IS_SPEC_OBJECT(obj)) return false;
1224 if (%_IsJSProxy(obj)) {
1225 return true;
1226 }
1227 return %IsExtensible(obj); 1224 return %IsExtensible(obj);
1228 } 1225 }
1229 1226
1230 1227
1231 // ECMA-262, Edition 6, section 19.1.2.1 1228 // ECMA-262, Edition 6, section 19.1.2.1
1232 function ObjectAssign(target, sources) { 1229 function ObjectAssign(target, sources) {
1233 // TODO(bmeurer): Move this to toplevel. 1230 // TODO(bmeurer): Move this to toplevel.
1234 "use strict"; 1231 "use strict";
1235 var to = TO_OBJECT(target); 1232 var to = TO_OBJECT(target);
1236 var argsLen = %_ArgumentsLength(); 1233 var argsLen = %_ArgumentsLength();
(...skipping 574 matching lines...) Expand 10 before | Expand all | Expand 10 after
1811 1808
1812 %InstallToContext([ 1809 %InstallToContext([
1813 "global_eval_fun", GlobalEval, 1810 "global_eval_fun", GlobalEval,
1814 "object_value_of", ObjectValueOf, 1811 "object_value_of", ObjectValueOf,
1815 "object_to_string", ObjectToString, 1812 "object_to_string", ObjectToString,
1816 "object_get_own_property_descriptor", ObjectGetOwnPropertyDescriptor, 1813 "object_get_own_property_descriptor", ObjectGetOwnPropertyDescriptor,
1817 "to_complete_property_descriptor", ToCompletePropertyDescriptor, 1814 "to_complete_property_descriptor", ToCompletePropertyDescriptor,
1818 ]); 1815 ]);
1819 1816
1820 }) 1817 })
OLDNEW
« no previous file with comments | « src/builtins.cc ('k') | src/messages.h » ('j') | src/objects.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698