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

Side by Side Diff: src/objects.h

Issue 20646006: Pipe a script's CORS status through V8 during compilation. (Closed) Base URL: https://chromium.googlesource.com/external/v8.git@master
Patch Set: . Created 7 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
« no previous file with comments | « src/debug.cc ('k') | src/objects-inl.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 // 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 5855 matching lines...) Expand 10 before | Expand all | Expand 10 after
5866 // [compilation_type]: how the the script was compiled. Encoded in the 5866 // [compilation_type]: how the the script was compiled. Encoded in the
5867 // 'flags' field. 5867 // 'flags' field.
5868 inline CompilationType compilation_type(); 5868 inline CompilationType compilation_type();
5869 inline void set_compilation_type(CompilationType type); 5869 inline void set_compilation_type(CompilationType type);
5870 5870
5871 // [compilation_state]: determines whether the script has already been 5871 // [compilation_state]: determines whether the script has already been
5872 // compiled. Encoded in the 'flags' field. 5872 // compiled. Encoded in the 'flags' field.
5873 inline CompilationState compilation_state(); 5873 inline CompilationState compilation_state();
5874 inline void set_compilation_state(CompilationState state); 5874 inline void set_compilation_state(CompilationState state);
5875 5875
5876 // [is_shared_cross_origin]: An opaque boolean set by the embedder via
5877 // ScriptOrigin, and used by the embedder to make decisions about the
5878 // script's level of privilege. V8 just passes this through. Encoded in
5879 // the 'flags' field.
5880 DECL_BOOLEAN_ACCESSORS(is_shared_cross_origin)
5881
5876 static inline Script* cast(Object* obj); 5882 static inline Script* cast(Object* obj);
5877 5883
5878 // If script source is an external string, check that the underlying 5884 // If script source is an external string, check that the underlying
5879 // resource is accessible. Otherwise, always return true. 5885 // resource is accessible. Otherwise, always return true.
5880 inline bool HasValidSource(); 5886 inline bool HasValidSource();
5881 5887
5882 // Dispatched behavior. 5888 // Dispatched behavior.
5883 DECLARE_PRINTER(Script) 5889 DECLARE_PRINTER(Script)
5884 DECLARE_VERIFIER(Script) 5890 DECLARE_VERIFIER(Script)
5885 5891
(...skipping 11 matching lines...) Expand all
5897 static const int kEvalFrominstructionsOffsetOffset = 5903 static const int kEvalFrominstructionsOffsetOffset =
5898 kEvalFromSharedOffset + kPointerSize; 5904 kEvalFromSharedOffset + kPointerSize;
5899 static const int kFlagsOffset = 5905 static const int kFlagsOffset =
5900 kEvalFrominstructionsOffsetOffset + kPointerSize; 5906 kEvalFrominstructionsOffsetOffset + kPointerSize;
5901 static const int kSize = kFlagsOffset + kPointerSize; 5907 static const int kSize = kFlagsOffset + kPointerSize;
5902 5908
5903 private: 5909 private:
5904 // Bit positions in the flags field. 5910 // Bit positions in the flags field.
5905 static const int kCompilationTypeBit = 0; 5911 static const int kCompilationTypeBit = 0;
5906 static const int kCompilationStateBit = 1; 5912 static const int kCompilationStateBit = 1;
5913 static const int kIsSharedCrossOriginBit = 2;
5907 5914
5908 DISALLOW_IMPLICIT_CONSTRUCTORS(Script); 5915 DISALLOW_IMPLICIT_CONSTRUCTORS(Script);
5909 }; 5916 };
5910 5917
5911 5918
5912 // List of builtin functions we want to identify to improve code 5919 // List of builtin functions we want to identify to improve code
5913 // generation. 5920 // generation.
5914 // 5921 //
5915 // Each entry has a name of a global object property holding an object 5922 // Each entry has a name of a global object property holding an object
5916 // optionally followed by ".prototype", a name of a builtin function 5923 // optionally followed by ".prototype", a name of a builtin function
(...skipping 3972 matching lines...) Expand 10 before | Expand all | Expand 10 after
9889 } else { 9896 } else {
9890 value &= ~(1 << bit_position); 9897 value &= ~(1 << bit_position);
9891 } 9898 }
9892 return value; 9899 return value;
9893 } 9900 }
9894 }; 9901 };
9895 9902
9896 } } // namespace v8::internal 9903 } } // namespace v8::internal
9897 9904
9898 #endif // V8_OBJECTS_H_ 9905 #endif // V8_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/debug.cc ('k') | src/objects-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698