Commit Graph

417 Commits

Author SHA1 Message Date
Jan de Mooij
0f65c9be84 Bug 1286159 - Clean up FinishOffThread* APIs for off-thread parsing. r=jonco 2016-07-19 09:19:54 +02:00
Nicholas Nethercote
2ebfc5116b Bug 1197973 - Use MOZ_MUST_USE in AutoJSAPI. r=bz. 2016-07-14 13:18:11 +10:00
Boris Zbarsky
4f728ae258 Bug 1278608. Just bail out of mozJSComponentLoader::LoadModule if it's called on a non-main thread. r=bholley 2016-07-07 20:08:25 -04:00
Christoph Kerschbaumer
e327196a9a Bug 1279481 - Convert mozJSComponentLoader.cpp to use channel->Open2() r=bholley 2016-06-10 14:32:09 +02:00
Ralph Giles
f608c28218 Bug 1275744 - Reference MOZ_LOG in xpconnect comments. r=erahm
NSPR_LOG_MODULES is deprecated.

MozReview-Commit-ID: 7a3EwGBFExT

--HG--
extra : rebase_source : fd4a85fcb89ac06038a1d30afd3607151a9e63ec
2016-05-25 16:31:13 -07:00
Jonathan Watt
b15368cfcb Bug 1279451 - Remove a lot of unnecessary includes of nsAutoPtr.h. rs=sparky 2016-06-07 21:10:18 +01:00
Boris Zbarsky
c22814a653 Bug 1276400 part 4. Stop setting dontReportUncaught in XPConnect code, since all consumers got their JSContext from an AutoEntryScript or AutoJSAPI. r=bkelly 2016-05-31 22:04:34 -04:00
Jan de Mooij
d6e128e540 Bug 1274915. Switch JS::DescribeScriptedCaller to walk through saved frames when walking the JS stack. r=bzbarsky 2016-05-26 20:36:09 -04:00
Chris Peterson
353ee65255 Bug 1272513 - Part 1: Suppress -Wshadow warnings-as-errors in some directories. r=glandium 2016-05-11 00:00:01 -07:00
Kyle Huey
c73656947b Bug 1265927: Move nsRunnable to mozilla::Runnable, CancelableRunnable to mozilla::CancelableRunnable. r=froydnj 2016-04-25 17:23:21 -07:00
Kris Maglione
bd8adfebce Bug 1254194: Add XPCOMUtils.defineLazyPreferenceGetter. r=billm
MozReview-Commit-ID: JBVelZ0Xg2H

--HG--
extra : rebase_source : 3909e75aa6b24ed2a1d2663c11be69c27f4de1e7
2016-04-14 16:37:30 -07:00
Boris Zbarsky
e3b2de6aa9 Bug 1255817 part 2. Get rid of AutoJSAPI::OwnsErrorReporting and AutoJSAPI::TakeOwnershipOfErrorReporting. r=bholley 2016-03-23 11:44:54 -04:00
Carsten "Tomcat" Book
53f935b036 Merge mozilla-central to mozilla-inbound 2016-03-22 12:31:09 +01:00
Nick Alexander
e90bd4aabb Bug 1256401 - Part 2: Remove references to b2gdroid. r=fabrice
MozReview-Commit-ID: 63yJGdgPbhe

--HG--
extra : rebase_source : 2256e0a12588703a83f4cba06971231ac3c64592
extra : amend_source : 1f35a04191f37225986bd7ff4d0b6b2c34a71b05
extra : histedit_source : 82d351700936c8e1297eeca91ce00f96340e2f2c
2016-03-18 14:41:51 -07:00
Tooru Fujisawa
49dcc9b049 Bug 1153978 - Part 2: Clear pending exception thrown from XDR related APIs when ignoring ReadCachedScript failure. r=bz 2016-03-22 16:48:38 +09:00
Benjamin Bouvier
70202e15a1 Bug 1251308; r=luke
MozReview-Commit-ID: AqsMX4m7Qh9

--HG--
extra : rebase_source : 519aef2cf8c0bb39771d4589069e8fd1a06970c3
2016-03-09 11:20:11 +01:00
sajitk
823704b8d6 Bug 1219482: Replace PRLogModuleInfo with LazyLogModule in various files.r=benjamin 2016-01-28 10:35:00 -08:00
Boris Zbarsky
36d4079be7 Bug 1254847 part 3. Make AutoEntryScript always take ownership of error reporting. r=bholley 2016-03-09 19:02:03 -05:00
Boris Zbarsky
bf71c8ea5b Bug 1254848 part 3. Take ownership of error reporting on the AutoEntryScript in AsyncScriptLoader::OnStreamComplete. r=bholley
There is no one else who cares about an exception left on the JSContext here: we're coming in off the event loop.
2016-03-09 15:28:42 -05:00
Boris Zbarsky
9c955ac670 Bug 1254848 part 2. Take ownership of error reporting on the AutoEntryScript in mozJSComponentLoader::PrepareObjectForLocation. r=bholley
This is only used for calling JS_FireOnNewGlobalObject, which never throws.
2016-03-09 15:28:41 -05:00
Boris Zbarsky
731f2ec68f Bug 1254848 part 1. Take ownership of error reporting on the AutoEntryScript in mozJSComponentLoader::ObjectForLocation. r=bholley
The code as it stood is a bit weird.  It sets up an AutoJSAPI that takes
ownership of error reporting.  Then later it also sets up an
AutoEntryScript... but keeps using the JSContext it got from the AutoJSAPI.
It's not obvious that there is any guarantee that this matches the JSContext
from the AutoEntryScript!

So we go ahead and change the things that are nominally using the
AutoEntryScript to use it JSContext and take ownership of error reporting on it
explicitly.  If the JSContext is the same as that of the AutoJSAPI, then we were
getting backstopped by its taking ownership of error reporting anyway.  If it's
not, we don't want to leave exceptions dangling on it.
2016-03-09 15:28:33 -05:00
Boris Zbarsky
d0363ce0e6 Bug 1254846. Add an AutoEntryScript constructor that takes a JSObject instead of an nsIGlobalObject, for convenience. r=bholley 2016-03-09 15:28:26 -05:00
Christoph Kerschbaumer
205c4c430e Bug 1254303 - Remove SEC_NORMAL from js/. r=sicking
MozReview-Commit-ID: JhPDn2yZE2g
2016-03-07 14:19:50 -08:00
Nathan Froyd
12d9670a60 Bug 1249389 - part 4 - make StartupCache::GetBuffer take a UniquePtr outparam; r=erahm
This change eliminates a number of nsAutoArrayPtr usages, as well as
making the pattern GetBuffer() -> NewObjectInputStreamFromBuffer more
pleasant.
2016-02-18 12:26:28 -05:00
Wes Kocher
b9d77f5943 Backed out changeset 2c56aed63687 (bug 1219482) to hopefully fix the intermittent hazard failures CLOSED TREE
--HG--
extra : commitid : 7egFNnxx2ut
2016-01-29 10:15:38 -08:00
sajitk
6fdb9b782e Bug 1219482 - Replace PRLogModuleInfo with LazyLogModule in various files. r=bsmedberg
--HG--
extra : rebase_source : 37e8f53a8aa5242058ab8fc867804cbc8940653e
2016-01-28 10:35:00 -05:00
Luke Wagner
72ea23c63e Bug 1239601 - improve the UniquePtr situation (r=jandem)
--HG--
extra : commitid : JegWAoGsuQ9
extra : rebase_source : 995c1b6ab8e4fd3b83c44741cd84a2d7b0d934d7
2016-01-15 18:26:20 -06:00
Lars T Hansen
05ef2926fd Bug 1231337 - part 1, hook SAB+Atomics runtime enablement into xpconnect. r=mrbkap
--HG--
extra : rebase_source : bf784389bbf81ae80ba31364092744f45475ec0e
extra : histedit_source : f3e7b35038b6364e1129978ee3fbeb166c3df8e7
2016-01-04 14:54:16 +01:00
Nathan Froyd
26acea99b2 Bug 1236571 - convert easy cases of nsAutoArrayPtr<T> to UniquePtr<T[]> in js/xpconnect/; r=gabor
The other cases are tied up with the startup cache, and will need more
extensive refactoring.
2015-12-06 09:20:16 -05:00
Jeff Walden
5be7be38a1 Bug 1235615 - Split JS::CompartmentOptions into JS::CompartmentCreationOptions that are immutable characteristics of a compartment, and JS::CompartmentBehaviors that may be changed after the compartment's been created. r=terrence
--HG--
extra : rebase_source : f08c380ae247d3308d4c36788ac765de1b75af50
2015-12-28 16:15:52 -06:00
Yury Delendik
b984c50fec Bug 1218029 - Adds ScriptLoadHandler and implements OnIncrementalData callback. r=djvj
--HG--
extra : commitid : 7TyrlgQ2f2Z
2015-12-01 08:00:58 -06:00
Yury Delendik
66199890c4 Bug 1218029 - Adds IncrementalStreamLoader interface stubs. r=djvj
--HG--
extra : commitid : J0UubFG9gvz
2015-11-30 08:54:11 -06:00
Nicholas Nethercote
4dd2a30a0f Bug 1187146 - Replace nsBaseHashtable::Enumerate() calls in js/xpconnect/ with iterators. r=mrbkap.
--HG--
extra : rebase_source : 28dc3c5614ee36e6e6955b9cc380e85ccc618a0d
2015-11-22 18:52:40 -08:00
Mike Hommey
394d50aba5 Bug 1226119 - Clear pending exception from script cache writing failure. r=bholley 2015-11-24 11:29:14 +09:00
Birunthan Mohanathas
9985829ecc Bug 1219392 - Capitalize mozilla::unused to avoid conflicts. r=froydnj 2015-11-02 07:53:26 +02:00
Birunthan Mohanathas
44936aabb2 Bug 1217320 - Remove more XPIDL signature comments in .cpp files. r=froydnj
Comment-only, DONTBUILD.
2015-10-27 06:54:25 +02:00
Tooru Fujisawa
406d1e9fbe Bug 1215937 - Remove use of expression closure from js/xpconnect/. r=bholley
--HG--
extra : commitid : Ktu9nsb2ozN
extra : rebase_source : bd5757a6ed71461e92dec4a72f6bfa441a06bfb7
2015-10-19 00:01:58 +09:00
Nathan Froyd
01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Carsten "Tomcat" Book
08997000eb Backed out 2 changesets (bug 1202902) to recking bug 1202902 to be able to reopen inbound on a CLOSED TREE
Backed out changeset 647025383676 (bug 1202902)
Backed out changeset d70c7fe532c6 (bug 1202902)
2015-10-07 14:03:21 +02:00
Sebastian Hengst
cdcff6d0a7 Backed out changeset c6b267589d0d (bug 1202902) for Mulet Reftest, W3C Platform Test and other failures. r=backout a=backout on a CLOSED TREE 2015-10-07 13:36:26 +02:00
Shu-yu Guo
52e365bb7b Bug 1202902 - Fix the world. (r=ato for marionette, rs=Mossop for rest) 2015-10-06 14:00:30 -07:00
Shu-yu Guo
76da4d1112 Bug 1202902 - Support non-syntactic extensible lexical scopes. (r=billm) 2015-10-06 14:00:29 -07:00
Fabrice Desré
00266c87aa Bug 1211085 - Disable global reuse on b2gdroid r=khuey 2015-10-03 18:50:40 -07:00
Jeff Walden
4046fe1490 Bug 1179003 - Convert the infallible objectClassIs proxy hook into a fallible getBuiltinClass hook that indicates class type via outparam. r=efaust, r=bz on DOM bits, r=billm on IPC bits
--HG--
extra : rebase_source : 6ddc3727c411fdfced6338e5e383a10572575f0f
2015-08-28 21:55:40 -07:00
Bobby Holley
a15b59d7f8 Bug 1206817 - Take ownership of error reporting in the component loader. r=bz 2015-09-21 17:05:59 -07:00
Christoph Kerschbaumer
668ebc2ff2 Bug 1206149 - Use channel->AsyncOpen2() js/xpconnect/loader/mozJSSubScriptLoader.cpp (r=sicking) 2015-09-19 20:26:09 -07:00
Nicholas Nethercote
f44287005f Bug 1198334 (part 1) - Replace the opt-in FAIL_ON_WARNINGS with the opt-out ALLOW_COMPILER_WARNINGS. r=glandium.
The patch removes 455 occurrences of FAIL_ON_WARNINGS from moz.build files, and
adds 78 instances of ALLOW_COMPILER_WARNINGS. About half of those 78 are in
code we control and which should be removable with a little effort.

--HG--
extra : rebase_source : 82e3387abfbd5f1471e953961d301d3d97ed2973
2015-08-27 20:44:53 -07:00
Birunthan Mohanathas
7315345693 Bug 1191100 - Remove XPIDL signature comments in .cpp files. r=ehsan
Comment-only so DONTBUILD.
2015-08-04 16:17:36 -07:00
Nicholas Nethercote
d98d14fa1e Bug 1189156 (part 4) - Don't use enumeration style for nsBaseHashtable::SizeOf{In,Ex}cludingThis(). r=erahm,jfkthame.
After this change, we have ShallowSizeOf{In,Ex}cludingThis(), which don't do
anything to measure children. (They can be combined with iteration to measure
children.)

--HG--
extra : rebase_source : f98420176f50990bbc5a25e35788328154cfeb00
2015-07-30 21:19:57 -07:00
Terrence Cole
f0591ea02e Bug 1186156 - Move the PersistentRooted list heads into RootLists; r=sfink 2015-07-09 14:13:10 -07:00