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

Unified Diff: src/globals.h

Issue 1731063007: Remove the global Strength enum class completely. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@local_strong-remove-literals
Patch Set: Remove more cruft. Created 4 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/factory.cc ('k') | src/isolate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/globals.h
diff --git a/src/globals.h b/src/globals.h
index be401a62eca1750d462d757676e7a6482717ec69..f6ab4a35194f01969d0e7d7d82ae56fbc092f8c4 100644
--- a/src/globals.h
+++ b/src/globals.h
@@ -300,35 +300,6 @@ inline LanguageMode construct_language_mode(bool strict_bit, bool strong_bit) {
}
-// Strong mode behaviour must sometimes be signalled by a two valued enum where
-// caching is involved, to prevent sloppy and strict mode from being incorrectly
-// differentiated.
-enum class Strength : bool {
- WEAK, // sloppy, strict behaviour
- STRONG // strong behaviour
-};
-
-
-inline bool is_strong(Strength strength) {
- return strength == Strength::STRONG;
-}
-
-
-inline std::ostream& operator<<(std::ostream& os, const Strength& strength) {
- return os << (is_strong(strength) ? "strong" : "weak");
-}
-
-
-inline Strength strength(LanguageMode language_mode) {
- return is_strong(language_mode) ? Strength::STRONG : Strength::WEAK;
-}
-
-
-inline size_t hash_value(Strength strength) {
- return static_cast<size_t>(strength);
-}
-
-
// Mask for the sign bit in a smi.
const intptr_t kSmiSignMask = kIntptrSignBit;
« no previous file with comments | « src/factory.cc ('k') | src/isolate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698