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

Side by Side Diff: src/math.js

Issue 450303003: Tag all prototypes as proto, except those set using __proto__ (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Remove is_shared from Map Created 6 years, 4 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/generator.js ('k') | src/objects.h » ('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 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 "use strict"; 5 "use strict";
6 6
7 // This file relies on the fact that the following declarations have been made 7 // This file relies on the fact that the following declarations have been made
8 // in runtime.js: 8 // in runtime.js:
9 // var $Object = global.Object; 9 // var $Object = global.Object;
10 10
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 } else { // Use regular log if not close enough to 0. 365 } else { // Use regular log if not close enough to 0.
366 return MathLog(1 + x); 366 return MathLog(1 + x);
367 } 367 }
368 } 368 }
369 369
370 // ------------------------------------------------------------------- 370 // -------------------------------------------------------------------
371 371
372 function SetUpMath() { 372 function SetUpMath() {
373 %CheckIsBootstrapping(); 373 %CheckIsBootstrapping();
374 374
375 %SetPrototype($Math, $Object.prototype); 375 %InternalSetPrototype($Math, $Object.prototype);
376 %AddNamedProperty(global, "Math", $Math, DONT_ENUM); 376 %AddNamedProperty(global, "Math", $Math, DONT_ENUM);
377 %FunctionSetInstanceClassName(MathConstructor, 'Math'); 377 %FunctionSetInstanceClassName(MathConstructor, 'Math');
378 378
379 // Set up math constants. 379 // Set up math constants.
380 InstallConstants($Math, $Array( 380 InstallConstants($Math, $Array(
381 // ECMA-262, section 15.8.1.1. 381 // ECMA-262, section 15.8.1.1.
382 "E", 2.7182818284590452354, 382 "E", 2.7182818284590452354,
383 // ECMA-262, section 15.8.1.2. 383 // ECMA-262, section 15.8.1.2.
384 "LN10", 2.302585092994046, 384 "LN10", 2.302585092994046,
385 // ECMA-262, section 15.8.1.3. 385 // ECMA-262, section 15.8.1.3.
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 "expm1", MathExpm1 432 "expm1", MathExpm1
433 )); 433 ));
434 434
435 %SetInlineBuiltinFlag(MathCeil); 435 %SetInlineBuiltinFlag(MathCeil);
436 %SetInlineBuiltinFlag(MathRandom); 436 %SetInlineBuiltinFlag(MathRandom);
437 %SetInlineBuiltinFlag(MathSin); 437 %SetInlineBuiltinFlag(MathSin);
438 %SetInlineBuiltinFlag(MathCos); 438 %SetInlineBuiltinFlag(MathCos);
439 } 439 }
440 440
441 SetUpMath(); 441 SetUpMath();
OLDNEW
« no previous file with comments | « src/generator.js ('k') | src/objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698