tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit 7b3bb279a64a46a2740f1f648738021d8899f001
parent 6a09a9ad8b53c6918ccb1c170a1e5976d7070fd2
Author: serge-sans-paille <sguelton@mozilla.com>
Date:   Thu,  9 Oct 2025 12:58:06 +0000

Bug 1993118 - Document why MOZ_HAS_JS_RUST is a macro function and not a macro definition r=hsivonen

Differential Revision: https://phabricator.services.mozilla.com/D267877

Diffstat:
Mmfbt/JsRust.h | 5+++++
1 file changed, 5 insertions(+), 0 deletions(-)

diff --git a/mfbt/JsRust.h b/mfbt/JsRust.h @@ -11,6 +11,11 @@ #ifndef mozilla_JsRust_h #define mozilla_JsRust_h +/* MOZ_HAS_JSRUST is defined as a macro function instead of a macro definition + * so that checking #if MOZ_HAS_JSRUST() when this header is not included ends + * up as an error, where #if MOZ_HAS_JSRUST or #ifdef MOZ_HAS_JSRUST would + * silently pass. + */ #if (defined(MOZ_HAS_MOZGLUE) || defined(MOZILLA_INTERNAL_API)) && \ !defined(MOZ_PRETEND_NO_JSRUST) # define MOZ_HAS_JSRUST() 1