Clean up incorrect V8_DEPRECATION macro usage and enable deprecatitions
authorjochen@chromium.org <jochen@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Fri, 22 Nov 2013 10:57:55 +0000 (10:57 +0000)
committerjochen@chromium.org <jochen@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Fri, 22 Nov 2013 10:57:55 +0000 (10:57 +0000)
We turn the default for standalone builds on, however, I added overrides
to all targets to turn it locally off again. In follow up CLs, I'll
clean up one target at a time.

BUG=v8:3023
R=dcarney@chromium.org, machenbach@chromium.org
LOG=n

Review URL: https://codereview.chromium.org/82763004

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@18002 ce2b1a6d-e550-0410-aec6-3dcde31c8c00

build/standalone.gypi
include/v8.h
samples/samples.gyp
src/d8.gyp
test/cctest/cctest.gyp
tools/gyp/v8.gyp

index 4cb5e00..b1aec36 100644 (file)
@@ -37,6 +37,7 @@
     'visibility%': 'hidden',
     'v8_enable_backtrace%': 0,
     'v8_enable_i18n_support%': 1,
+    'v8_deprecation_warnings': 1,
     'msvs_multi_core_compile%': '1',
     'mac_deployment_target%': '10.5',
     'variables': {
index e44c0bf..51b2262 100644 (file)
@@ -1736,7 +1736,7 @@ class V8_EXPORT String : public Primitive {
    * the function calls 'strlen' to determine the buffer length.
    */
   V8_DEPRECATED(
-      "Use NewFromOneByte instead",
+      "Use NewFromUtf8 instead",
       V8_INLINE static Local<String> New(const char* data, int length = -1));
 
   /** Allocates a new string from 16-bit character codes.*/
@@ -2535,7 +2535,7 @@ class V8_EXPORT Function : public Object {
   /**
    * Returns scriptId object.
    */
-  V8_DEPRECATED("Use ScriptId instead", Handle<Value> GetScriptId()) const;
+  V8_DEPRECATED("Use ScriptId instead", Handle<Value> GetScriptId() const);
 
   /**
    * Returns scriptId.
@@ -2899,7 +2899,7 @@ class V8_EXPORT Date : public Object {
 
   V8_DEPRECATED(
       "Use ValueOf instead",
-      double NumberValue()) const { return ValueOf(); }
+      double NumberValue() const) { return ValueOf(); }
 
   /**
    * A specialization of Value::NumberValue that is more efficient
@@ -2937,7 +2937,7 @@ class V8_EXPORT NumberObject : public Object {
 
   V8_DEPRECATED(
       "Use ValueOf instead",
-      double NumberValue()) const { return ValueOf(); }
+      double NumberValue() const) { return ValueOf(); }
 
   /**
    * Returns the Number held by the object.
@@ -2960,7 +2960,7 @@ class V8_EXPORT BooleanObject : public Object {
 
   V8_DEPRECATED(
       "Use ValueOf instead",
-      bool BooleanValue()) const { return ValueOf(); }
+      bool BooleanValue() const) { return ValueOf(); }
 
   /**
    * Returns the Boolean held by the object.
@@ -2983,7 +2983,7 @@ class V8_EXPORT StringObject : public Object {
 
   V8_DEPRECATED(
       "Use ValueOf instead",
-      Local<String> StringValue()) const { return ValueOf(); }
+      Local<String> StringValue() const) { return ValueOf(); }
 
   /**
    * Returns the String held by the object.
@@ -3008,7 +3008,7 @@ class V8_EXPORT SymbolObject : public Object {
 
   V8_DEPRECATED(
       "Use ValueOf instead",
-      Local<Symbol> SymbolValue()) const { return ValueOf(); }
+      Local<Symbol> SymbolValue() const) { return ValueOf(); }
 
   /**
    * Returns the Symbol held by the object.
@@ -6047,7 +6047,7 @@ Handle<Boolean> Boolean::New(bool value) {
 
 
 void Template::Set(const char* name, v8::Handle<Data> value) {
-  Set(v8::String::New(name), value);
+  Set(v8::String::NewFromUtf8(Isolate::GetCurrent(), name), value);
 }
 
 
index dfc7410..0e8e9c4 100644 (file)
     'include_dirs': [
       '../include',
     ],
+    'variables': {
+      # TODO(jochen): enable warnings.
+      'v8_deprecation_warnings': 0,
+    },
     'conditions': [
       ['v8_enable_i18n_support==1', {
         'dependencies': [
index 097abc0..1e6e2c3 100644 (file)
     'v8_enable_vtunejit%': 0,
     'v8_enable_i18n_support%': 1,
   },
+  'target_defaults': {
+    'variables': {
+      # TODO(jochen): enable warnings.
+      'v8_deprecation_warnings': 0,
+    },
+  },
   'includes': ['../build/toolchain.gypi', '../build/features.gypi'],
   'targets': [
     {
index 2017d61..bf98268 100644 (file)
     'v8_code': 1,
     'generated_file': '<(SHARED_INTERMEDIATE_DIR)/resources.cc',
   },
+  'target_defaults': {
+    'variables': {
+      # TODO(jochen): enable warnings.
+      'v8_deprecation_warnings': 0,
+    },
+  },
   'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
   'targets': [
     {
index 65d5fb8..5940deb 100644 (file)
     'v8_code': 1,
     'v8_random_seed%': 314159265,
   },
+  'target_defaults': {
+    'variables': {
+      # TODO(jochen): enable warnings.
+      'v8_deprecation_warnings': 0,
+    },
+  },
   'includes': ['../../build/toolchain.gypi', '../../build/features.gypi'],
   'targets': [
     {