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

Side by Side Diff: src/objects.h

Issue 10091035: Make Value::IsUndefined and Value::IsNull inlineable. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 8 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/api.cc ('k') | no next file » | 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 // 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 662 matching lines...) Expand 10 before | Expand all | Expand 10 after
673 // Note that the types for which typeof is "function" are not continuous. 673 // Note that the types for which typeof is "function" are not continuous.
674 // Define this so that we can put assertions on discrete checks. 674 // Define this so that we can put assertions on discrete checks.
675 NUM_OF_CALLABLE_SPEC_OBJECT_TYPES = 2 675 NUM_OF_CALLABLE_SPEC_OBJECT_TYPES = 2
676 }; 676 };
677 677
678 const int kExternalArrayTypeCount = 678 const int kExternalArrayTypeCount =
679 LAST_EXTERNAL_ARRAY_TYPE - FIRST_EXTERNAL_ARRAY_TYPE + 1; 679 LAST_EXTERNAL_ARRAY_TYPE - FIRST_EXTERNAL_ARRAY_TYPE + 1;
680 680
681 STATIC_CHECK(JS_OBJECT_TYPE == Internals::kJSObjectType); 681 STATIC_CHECK(JS_OBJECT_TYPE == Internals::kJSObjectType);
682 STATIC_CHECK(FIRST_NONSTRING_TYPE == Internals::kFirstNonstringType); 682 STATIC_CHECK(FIRST_NONSTRING_TYPE == Internals::kFirstNonstringType);
683 STATIC_CHECK(ODDBALL_TYPE == Internals::kOddballType);
683 STATIC_CHECK(FOREIGN_TYPE == Internals::kForeignType); 684 STATIC_CHECK(FOREIGN_TYPE == Internals::kForeignType);
684 685
685 686
686 enum CompareResult { 687 enum CompareResult {
687 LESS = -1, 688 LESS = -1,
688 EQUAL = 0, 689 EQUAL = 0,
689 GREATER = 1, 690 GREATER = 1,
690 691
691 NOT_EQUAL = GREATER 692 NOT_EQUAL = GREATER
692 }; 693 };
(...skipping 6936 matching lines...) Expand 10 before | Expand all | Expand 10 after
7629 static const byte kTheHole = 2; 7630 static const byte kTheHole = 2;
7630 static const byte kNull = 3; 7631 static const byte kNull = 3;
7631 static const byte kArgumentMarker = 4; 7632 static const byte kArgumentMarker = 4;
7632 static const byte kUndefined = 5; 7633 static const byte kUndefined = 5;
7633 static const byte kOther = 6; 7634 static const byte kOther = 6;
7634 7635
7635 typedef FixedBodyDescriptor<kToStringOffset, 7636 typedef FixedBodyDescriptor<kToStringOffset,
7636 kToNumberOffset + kPointerSize, 7637 kToNumberOffset + kPointerSize,
7637 kSize> BodyDescriptor; 7638 kSize> BodyDescriptor;
7638 7639
7640 STATIC_CHECK(kKindOffset == Internals::kOddballKindOffset);
7641 STATIC_CHECK(kNull == Internals::kNullOddballKind);
7642 STATIC_CHECK(kUndefined == Internals::kUndefinedOddballKind);
7643
7639 private: 7644 private:
7640 DISALLOW_IMPLICIT_CONSTRUCTORS(Oddball); 7645 DISALLOW_IMPLICIT_CONSTRUCTORS(Oddball);
7641 }; 7646 };
7642 7647
7643 7648
7644 class JSGlobalPropertyCell: public HeapObject { 7649 class JSGlobalPropertyCell: public HeapObject {
7645 public: 7650 public:
7646 // [value]: value of the global property. 7651 // [value]: value of the global property.
7647 DECL_ACCESSORS(value, Object) 7652 DECL_ACCESSORS(value, Object)
7648 7653
(...skipping 975 matching lines...) Expand 10 before | Expand all | Expand 10 after
8624 } else { 8629 } else {
8625 value &= ~(1 << bit_position); 8630 value &= ~(1 << bit_position);
8626 } 8631 }
8627 return value; 8632 return value;
8628 } 8633 }
8629 }; 8634 };
8630 8635
8631 } } // namespace v8::internal 8636 } } // namespace v8::internal
8632 8637
8633 #endif // V8_OBJECTS_H_ 8638 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/api.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698