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

Side by Side Diff: src/d8.js

Issue 12385082: Make sure builtin functions don't rely on __proto__. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 9 months 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 | Annotate | Revision Log
« no previous file with comments | « src/array.js ('k') | src/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2008 the V8 project authors. All rights reserved. 1 // Copyright 2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 current = ToInspectableObject(current); 64 current = ToInspectableObject(current);
65 while (typeof current !== 'undefined') { 65 while (typeof current !== 'undefined') {
66 var mirror = new $debug.ObjectMirror(current); 66 var mirror = new $debug.ObjectMirror(current);
67 var properties = mirror.properties(); 67 var properties = mirror.properties();
68 for (var i = 0; i < properties.length; i++) { 68 for (var i = 0; i < properties.length; i++) {
69 var name = properties[i].name(); 69 var name = properties[i].name();
70 if (typeof name === 'string' && name.startsWith(last)) { 70 if (typeof name === 'string' && name.startsWith(last)) {
71 result.push(name); 71 result.push(name);
72 } 72 }
73 } 73 }
74 current = ToInspectableObject(current.__proto__); 74 current = ToInspectableObject(Object.getPrototypeOf(current));
75 } 75 }
76 return result; 76 return result;
77 } 77 }
78 78
79 79
80 // Global object holding debugger related constants and state. 80 // Global object holding debugger related constants and state.
81 var Debug = {}; 81 var Debug = {};
82 82
83 83
84 // Debug events which can occour in the V8 JavaScript engine. These originate 84 // Debug events which can occour in the V8 JavaScript engine. These originate
(...skipping 2102 matching lines...) Expand 10 before | Expand all | Expand 10 after
2187 json += NumberToJSON_(elem); 2187 json += NumberToJSON_(elem);
2188 } else if (typeof(elem) === 'string') { 2188 } else if (typeof(elem) === 'string') {
2189 json += StringToJSON_(elem); 2189 json += StringToJSON_(elem);
2190 } else { 2190 } else {
2191 json += elem; 2191 json += elem;
2192 } 2192 }
2193 } 2193 }
2194 json += ']'; 2194 json += ']';
2195 return json; 2195 return json;
2196 } 2196 }
OLDNEW
« no previous file with comments | « src/array.js ('k') | src/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698