Bug 937751 - Followup to compile with clang versions that treat |struct S; struct __attribute__((visibility("default"))) S {};| as an error. rs=mccr8
authorJeff Walden <jwalden@mit.edu>
Tue, 03 Dec 2013 15:53:40 -0800
changeset 174339 5036242b2d531d76027470bd07f0add17659321d
parent 174338 4856e14d1d94169c7f09d08633e7f2214b93de23
child 174340 b96d513cd89f5aff1841c6a6c926481807864589
push id445
push userffxbld
push dateMon, 10 Mar 2014 22:05:19 +0000
treeherdermozilla-release@dc38b741b04e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmccr8
bugs937751
milestone28.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 937751 - Followup to compile with clang versions that treat |struct S; struct __attribute__((visibility("default"))) S {};| as an error. rs=mccr8
js/public/SliceBudget.h
js/src/jsgc.h
--- a/js/public/SliceBudget.h
+++ b/js/public/SliceBudget.h
@@ -2,25 +2,28 @@
  * 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 js_SliceBudget_h
 #define js_SliceBudget_h
 
+#include <stdint.h>
+
 namespace js {
 
 /*
  * This class records how much work has been done in a given collection slice, so that
  * we can return before pausing for too long. Some slices are allowed to run for
  * unlimited time, and others are bounded. To reduce the number of gettimeofday
  * calls, we only check the time every 1000 operations.
  */
-struct JS_PUBLIC_API(SliceBudget) {
+struct JS_PUBLIC_API(SliceBudget)
+{
     int64_t deadline; /* in microseconds */
     intptr_t counter;
 
     static const intptr_t CounterReset = 1000;
 
     static const int64_t Unlimited = 0;
     static int64_t TimeBudget(int64_t millis);
     static int64_t WorkBudget(int64_t work);
--- a/js/src/jsgc.h
+++ b/js/src/jsgc.h
@@ -11,16 +11,17 @@
 
 #include "mozilla/DebugOnly.h"
 #include "mozilla/MemoryReporting.h"
 
 #include "jslock.h"
 #include "jsobj.h"
 
 #include "js/GCAPI.h"
+#include "js/SliceBudget.h"
 #include "js/Tracer.h"
 #include "js/Vector.h"
 
 class JSAtom;
 struct JSCompartment;
 class JSFlatString;
 class JSLinearString;
 
@@ -34,17 +35,16 @@ class DebugScopeObject;
 class GCHelperThread;
 class GlobalObject;
 class LazyScript;
 class Nursery;
 class PropertyName;
 class ScopeObject;
 class Shape;
 class UnownedBaseShape;
-struct SliceBudget;
 
 unsigned GetCPUCount();
 
 enum HeapState {
     Idle,             // doing nothing with the GC heap
     Tracing,          // tracing the GC heap without collecting, e.g. IterateCompartments()
     MajorCollecting,  // doing a GC of the major heap
     MinorCollecting   // doing a GC of the minor heap (nursery)