Bug 1438278 - Part 1: Rename json.* -> builtin/JSON.*. r=jandem.
authorJason Orendorff <jorendorff@mozilla.com>
Wed, 14 Feb 2018 13:35:54 -0600
changeset 404194 745176a7ab4a5197f3e2b77c749b4559a7a5b4c4
parent 404193 02d24f7856d50c678016cd33292882217ce29f36
child 404195 249a7398961afcefa7a6c1f2b9172d8c85e9104a
push id99965
push userjorendorff@mozilla.com
push dateFri, 16 Feb 2018 21:07:25 +0000
treeherdermozilla-inbound@b3ee97dce95a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjandem
bugs1438278
milestone60.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1438278 - Part 1: Rename json.* -> builtin/JSON.*. r=jandem.
js/src/builtin/JSON.cpp
js/src/builtin/JSON.h
js/src/jsapi.cpp
js/src/json.cpp
js/src/json.h
js/src/moz.build
js/src/vm/GlobalObject.cpp
rename from js/src/json.cpp
rename to js/src/builtin/JSON.cpp
--- a/js/src/json.cpp
+++ b/js/src/builtin/JSON.cpp
@@ -1,15 +1,15 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
  * vim: set ts=8 sts=4 et sw=4 tw=99:
  * This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "json.h"
+#include "builtin/JSON.h"
 
 #include "mozilla/FloatingPoint.h"
 #include "mozilla/Range.h"
 #include "mozilla/ScopeExit.h"
 
 #include "jsarray.h"
 #include "jsnum.h"
 #include "jsstr.h"
rename from js/src/json.h
rename to js/src/builtin/JSON.h
--- a/js/src/json.h
+++ b/js/src/builtin/JSON.h
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
  * vim: set ts=8 sts=4 et sw=4 tw=99:
  * This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#ifndef json_h
-#define json_h
+#ifndef builtin_JSON_h
+#define builtin_JSON_h
 
 #include "mozilla/Range.h"
 
 #include "NamespaceImports.h"
 
 #include "js/RootingAPI.h"
 
 namespace js {
@@ -35,9 +35,9 @@ Stringify(JSContext* cx, js::MutableHand
 
 template <typename CharT>
 extern bool
 ParseJSONWithReviver(JSContext* cx, const mozilla::Range<const CharT> chars,
                      HandleValue reviver, MutableHandleValue vp);
 
 } // namespace js
 
-#endif /* json_h */
+#endif /* builtin_JSON_h */
--- a/js/src/jsapi.cpp
+++ b/js/src/jsapi.cpp
@@ -26,26 +26,26 @@
 #include "jsarray.h"
 #include "jsbool.h"
 #include "jsdate.h"
 #include "jsexn.h"
 #include "jsfriendapi.h"
 #include "jsiter.h"
 #include "jsmath.h"
 #include "jsnum.h"
-#include "json.h"
 #include "jsprf.h"
 #include "jsstr.h"
 #include "jstypes.h"
 #include "jsutil.h"
 #include "jsweakmap.h"
 #include "jswrapper.h"
 
 #include "builtin/AtomicsObject.h"
 #include "builtin/Eval.h"
+#include "builtin/JSON.h"
 #include "builtin/MapObject.h"
 #include "builtin/Promise.h"
 #include "builtin/RegExp.h"
 #include "builtin/Stream.h"
 #include "builtin/SymbolObject.h"
 #ifdef ENABLE_SIMD
 # include "builtin/SIMD.h"
 #endif
--- a/js/src/moz.build
+++ b/js/src/moz.build
@@ -27,17 +27,17 @@ with Files('gc/**'):
 with Files('jit/**'):
     BUG_COMPONENT = component_jit
 
 # File-specific metadata
 for gcfile in ['jsgc*', 'devtools/rootAnalysis', 'devtools/gc-ubench', 'devtools/gctrace']:
     with Files(gcfile):
         BUG_COMPONENT = component_gc
 
-for stlfile in ['jsarray.*', 'jsbool*', 'jsdate.*', 'jsnum.*', 'json.*', 'jsstr.*']:
+for stlfile in ['jsarray.*', 'jsbool*', 'jsdate.*', 'jsnum.*', 'jsstr.*']:
     with Files(stlfile):
         BUG_COMPONENT = component_stl
 
 with Files('builtin/intl/*'):
     BUG_COMPONENT = component_intl
 
 
 if CONFIG['JS_BUNDLED_EDITLINE']:
@@ -160,16 +160,17 @@ UNIFIED_SOURCES += [
     'builtin/intl/Collator.cpp',
     'builtin/intl/CommonFunctions.cpp',
     'builtin/intl/DateTimeFormat.cpp',
     'builtin/intl/IntlObject.cpp',
     'builtin/intl/NumberFormat.cpp',
     'builtin/intl/PluralRules.cpp',
     'builtin/intl/RelativeTimeFormat.cpp',
     'builtin/intl/SharedIntlData.cpp',
+    'builtin/JSON.cpp',
     'builtin/MapObject.cpp',
     'builtin/ModuleObject.cpp',
     'builtin/Object.cpp',
     'builtin/Profilers.cpp',
     'builtin/Promise.cpp',
     'builtin/Reflect.cpp',
     'builtin/ReflectParse.cpp',
     'builtin/SIMD.cpp',
@@ -293,17 +294,16 @@ UNIFIED_SOURCES += [
     'jsbool.cpp',
     'jsdate.cpp',
     'jsexn.cpp',
     'jsfriendapi.cpp',
     'jsgc.cpp',
     'jsiter.cpp',
     'jsnativestack.cpp',
     'jsnum.cpp',
-    'json.cpp',
     'jsopcode.cpp',
     'jsprf.cpp',
     'jsstr.cpp',
     'jsweakmap.cpp',
     'perf/jsperf.cpp',
     'proxy/BaseProxyHandler.cpp',
     'proxy/CrossCompartmentWrapper.cpp',
     'proxy/DeadObjectProxy.cpp',
--- a/js/src/vm/GlobalObject.cpp
+++ b/js/src/vm/GlobalObject.cpp
@@ -5,22 +5,22 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "vm/GlobalObject.h"
 
 #include "jsdate.h"
 #include "jsexn.h"
 #include "jsfriendapi.h"
 #include "jsmath.h"
-#include "json.h"
 #include "jsprototypes.h"
 
 #include "builtin/AtomicsObject.h"
 #include "builtin/DataViewObject.h"
 #include "builtin/Eval.h"
+#include "builtin/JSON.h"
 #include "builtin/MapObject.h"
 #include "builtin/ModuleObject.h"
 #include "builtin/Object.h"
 #include "builtin/Promise.h"
 #include "builtin/RegExp.h"
 #include "builtin/SelfHostingDefines.h"
 #include "builtin/Stream.h"
 #include "builtin/SymbolObject.h"