gecko-dev/dom/bindings
Nathan Froyd e3ebda1914 Bug 1223932 - delete guard object uses from the tree; r=jwalden
CLOSED TREE

We don't need these macros anymore, for two reasons:

1. We have static analysis to provide the same sort of checks via `MOZ_RAII`
   and friends.
2. clang now warns for the "temporary that should have been a declaration" case.

The extra requirements on class construction also show up during debug tests
as performance problems.

This change was automated by using the following sed script:

```
# Remove declarations in classes.
/MOZ_DECL_USE_GUARD_OBJECT_NOTIFIER/d
/MOZ_GUARD_OBJECT_NOTIFIER_INIT/d

# Remove individual macros, carefully.
{
  # We don't have to worry about substrings here because the closing
  # parenthesis "anchors" the match.
  s/MOZ_GUARD_OBJECT_NOTIFIER_PARAM)/)/g;
  s/MOZ_GUARD_OBJECT_NOTIFIER_PARAM_TO_PARENT)/)/g;
  s/MOZ_GUARD_OBJECT_NOTIFIER_PARAM_IN_IMPL)/)/g;
  s/MOZ_GUARD_OBJECT_NOTIFIER_ONLY_PARAM_IN_IMPL)/)/g;

  # Remove the longer identifier first.
  s/MOZ_GUARD_OBJECT_NOTIFIER_ONLY_PARAM_TO_PARENT//g;
  s/MOZ_GUARD_OBJECT_NOTIFIER_ONLY_PARAM//g;
}

# Remove the actual include.
\@# *include "mozilla/GuardObjects.h"@d
```

and running:

```
find . -name \*.cpp -o -name \*.h | grep -v 'GuardObjects.h' |xargs sed -i -f script 2>/dev/null
mach clang-format
```

Differential Revision: https://phabricator.services.mozilla.com/D85168
2020-07-30 14:22:38 +00:00
..
crashtests Bug 1644863 - fix trailing whitespace in cross-tree tests, r=emilio,marionette-reviewers,whimboo 2020-06-17 22:45:31 +00:00
docs
mozwebidlcodegen Bug 1652149 - Run `mozwebidlcodegen` unit test as part of `mozbuild` suite r=froydnj 2020-07-13 13:02:01 +00:00
parser Bug 1633156 - Don't emit cached table files from ply r=glandium 2020-05-07 00:39:28 +00:00
test Bug 1649554: Part 1 - Move deprecated component registration helpers out of XPCOMUtils. r=mccr8,remote-protocol-reviewers,marionette-reviewers,perftest-reviewers,webcompat-reviewers,whimboo,twisniewski 2020-07-10 23:58:30 +00:00
AtomList.h
BindingCallContext.h
BindingDeclarations.h Bug 1519636 - Reformat recent changes to the Google coding style r=andi 2020-05-09 14:51:53 +00:00
BindingIPCUtils.h
BindingUtils.cpp Bug 1652002 - Remove some unnecessary includes from BindingUtils.h. r=peterv 2020-07-15 15:34:49 +00:00
BindingUtils.h Bug 1223932 - delete guard object uses from the tree; r=jwalden 2020-07-30 14:22:38 +00:00
Bindings.conf Bug 1633379 - Part 2: Add support for in-process JSWindowActors, r=kmag,Yoric 2020-06-25 20:35:18 +00:00
CallbackFunction.h Bug 1632439 - Make CallbackObject methods return JSObject pointers rather than handles r=peterv 2020-05-21 14:09:02 +00:00
CallbackInterface.cpp Bug 1632439 - Make CallbackObject methods return JSObject pointers rather than handles r=peterv 2020-05-21 14:09:02 +00:00
CallbackInterface.h
CallbackObject.cpp Bug 1654526 - Remove support for realm parameter with eRethrowExceptions r=smaug 2020-07-24 08:08:53 +00:00
CallbackObject.h Bug 1654526 - Remove support for realm parameter with eRethrowExceptions r=smaug 2020-07-24 08:08:53 +00:00
Codegen.py Bug 1653228 - Move PinnedStringId to a separate header. r=peterv 2020-07-22 15:13:21 +00:00
Configuration.py Bug 1639310 - Simplify implicitJSContext support. r=mccr8 2020-05-19 20:48:29 +00:00
DOMExceptionNames.h
DOMJSClass.h Bug 1642974 - Don't expose WeakRef targets which are DOM wrappers whose target has been collected r=smaug,sfink 2020-06-06 06:58:42 +00:00
DOMJSProxyHandler.cpp Bug 1655443 - Redesign private name proxy support to be more clear and simpler r=jorendorff 2020-07-27 21:08:42 +00:00
DOMJSProxyHandler.h Bug 1655443 - Redesign private name proxy support to be more clear and simpler r=jorendorff 2020-07-27 21:08:42 +00:00
DOMString.h
ErrorIPCUtils.h
ErrorResult.h Bug 1519636 - Reformat recent changes to the Google coding style r=andi 2020-07-04 09:38:43 +00:00
Errors.msg
Exceptions.cpp
Exceptions.h
FakeString.h
GenerateCSS2PropertiesWebIDL.py Bug 1635584 - Make BackdropFilter's Availability Depend on WebRender r=emilio 2020-05-08 05:54:26 +00:00
IterableIterator.cpp
IterableIterator.h Bug 1652002 - Remove some unnecessary includes from BindingUtils.h. r=peterv 2020-07-15 15:34:49 +00:00
JSSlots.h
Makefile.in Bug 1599658 - Delete previous definition of py_action in Makefiles. Now py_action calls into Python 3 and py3_action doesn't exist. r=glandium 2020-05-05 20:04:30 +00:00
NonRefcountedDOMObject.h
Nullable.h
PinnedStringId.h Bug 1653228 - Move PinnedStringId to a separate header. r=peterv 2020-07-22 15:13:21 +00:00
PrimitiveConversions.h
ReadableStream.h
Record.h
RemoteObjectProxy.cpp Bug 1648010 - Replace uses of NS_LITERAL_STRING/NS_LITERAL_CSTRING macros by _ns literals. r=geckoview-reviewers,jgilbert,agi,hsivonen,froydnj 2020-07-01 08:29:29 +00:00
RemoteObjectProxy.h Bug 1643457 - Support ChromeOnly properties on remote proxies. r=mccr8 2020-06-05 12:45:40 +00:00
RootedDictionary.h Bug 1223932 - delete guard object uses from the tree; r=jwalden 2020-07-30 14:22:38 +00:00
RootedOwningNonNull.h
RootedRefPtr.h
SimpleGlobalObject.cpp Bug 1630947 - Update Reporting API - part 1 - ReportingObserver in workers, r=smaug 2020-04-18 12:25:57 +00:00
SimpleGlobalObject.h
SpiderMonkeyInterface.h Bug 1223932 - delete guard object uses from the tree; r=jwalden 2020-07-30 14:22:38 +00:00
ToJSValue.cpp
ToJSValue.h Bug 1652002 - Remove some unnecessary includes from BindingUtils.h. r=peterv 2020-07-15 15:34:49 +00:00
TypedArray.h
UnionMember.h
WebIDLGlobalNameHash.cpp Bug 1633145 - Replace NON_INTEGER_ATOM_TO_JSID. r=jandem 2020-04-30 18:18:35 +00:00
WebIDLGlobalNameHash.h
XrayExpandoClass.h
mach_commands.py
moz.build Bug 1653228 - Move PinnedStringId to a separate header. r=peterv 2020-07-22 15:13:21 +00:00
nsIScriptError.idl Bug 1654927 - Move js.msg and js::GetErrorMessage into a new js/public/friend directory so users of them don't have to depend on all of jsfriendapi.h. r=mgaudet 2020-07-29 04:44:50 +00:00
nsScriptError.cpp Bug 1639165 - Add an isFowardedFromContentProcess flag to nsIScriptError. r=baku. 2020-06-05 14:53:26 +00:00
nsScriptError.h Bug 1639165 - Add an isFowardedFromContentProcess flag to nsIScriptError. r=baku. 2020-06-05 14:53:26 +00:00
nsScriptErrorWithStack.cpp Bug 1648010 - Replace uses of NS_LITERAL_STRING/NS_LITERAL_CSTRING macros by _ns literals. r=geckoview-reviewers,jgilbert,agi,hsivonen,froydnj 2020-07-01 08:29:29 +00:00