Update On Fri Dec 8 19:42:52 CET 2023
This commit is contained in:
parent
500fd0c799
commit
d5d8068197
212 changed files with 7020 additions and 8789 deletions
|
@ -3,10 +3,10 @@
|
|||
# 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('/toolkit/toolkit.mozbuild')
|
||||
include("/toolkit/toolkit.mozbuild")
|
||||
|
||||
DIRS += ['/%s' % CONFIG['MOZ_BRANDING_DIRECTORY']]
|
||||
DIRS += ["/%s" % CONFIG["MOZ_BRANDING_DIRECTORY"]]
|
||||
|
||||
# Never add dirs after browser because they apparently won't get
|
||||
# packaged properly on Mac.
|
||||
DIRS += ['/browser']
|
||||
DIRS += ["/browser"]
|
||||
|
|
|
@ -993,7 +993,8 @@ class nsContextMenu {
|
|||
this.onLink &&
|
||||
!this.onMailtoLink &&
|
||||
!this.onTelLink &&
|
||||
!this.onMozExtLink
|
||||
!this.onMozExtLink &&
|
||||
!this.isSecureAboutPage()
|
||||
);
|
||||
|
||||
let copyLinkSeparator = document.getElementById("context-sep-copylink");
|
||||
|
@ -2296,6 +2297,23 @@ class nsContextMenu {
|
|||
return strippedLinkURI ?? this.linkURI;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if a webpage is a secure interal webpage
|
||||
* @returns {Boolean}
|
||||
*
|
||||
*/
|
||||
isSecureAboutPage() {
|
||||
let { currentURI } = this.browser;
|
||||
if (currentURI?.schemeIs("about")) {
|
||||
let module = E10SUtils.getAboutModule(currentURI);
|
||||
if (module) {
|
||||
let flags = module.getURIFlags(currentURI);
|
||||
return !!(flags & Ci.nsIAboutModule.IS_SECURE_CHROME_UI);
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
// Kept for addon compat
|
||||
linkText() {
|
||||
return this.linkTextStr;
|
||||
|
|
|
@ -44,6 +44,7 @@ let hasContainers =
|
|||
const example_base =
|
||||
// eslint-disable-next-line @microsoft/sdl/no-insecure-url
|
||||
"http://example.com/browser/browser/base/content/test/contextMenu/";
|
||||
const about_preferences_base = "about:preferences";
|
||||
const chrome_base =
|
||||
"chrome://mochitests/content/browser/browser/base/content/test/contextMenu/";
|
||||
const head_base =
|
||||
|
@ -1934,6 +1935,64 @@ add_task(async function test_background_image() {
|
|||
});
|
||||
|
||||
add_task(async function test_cleanup_html() {
|
||||
lastElementSelector = null;
|
||||
gBrowser.removeCurrentTab();
|
||||
});
|
||||
|
||||
/*
|
||||
* Testing that Copy without Site Tracking option does not
|
||||
* appear on internal about: pages.
|
||||
*/
|
||||
add_task(async function test_strip_on_share_on_secure_about_page() {
|
||||
let url = about_preferences_base;
|
||||
|
||||
let tab = await BrowserTestUtils.openNewForegroundTab({
|
||||
gBrowser,
|
||||
url,
|
||||
});
|
||||
|
||||
let browser2 = tab.linkedBrowser;
|
||||
|
||||
await SpecialPowers.spawn(browser2, [], () => {
|
||||
let link = content.document.createElement("a");
|
||||
link.href = "https://mozilla.com";
|
||||
link.textContent = "link with query param";
|
||||
link.id = "link-test-strip";
|
||||
content.document.body.appendChild(link);
|
||||
});
|
||||
|
||||
// the Copy without Site Tracking option should not
|
||||
// show up within internal about: pages
|
||||
await test_contextmenu("#link-test-strip", [
|
||||
"context-openlinkintab",
|
||||
true,
|
||||
...(hasContainers ? ["context-openlinkinusercontext-menu", true] : []),
|
||||
// We need a blank entry here because the containers submenu is
|
||||
// dynamically generated with no ids.
|
||||
...(hasContainers ? ["", null] : []),
|
||||
"context-openlink",
|
||||
true,
|
||||
"context-openlinkprivate",
|
||||
true,
|
||||
"---",
|
||||
null,
|
||||
"context-bookmarklink",
|
||||
true,
|
||||
"context-savelink",
|
||||
true,
|
||||
...(hasPocket ? ["context-savelinktopocket", true] : []),
|
||||
"context-copylink",
|
||||
true,
|
||||
"---",
|
||||
null,
|
||||
"context-searchselect",
|
||||
true,
|
||||
"context-searchselect-private",
|
||||
true,
|
||||
]);
|
||||
|
||||
// Clean up
|
||||
lastElementSelector = null;
|
||||
gBrowser.removeCurrentTab();
|
||||
});
|
||||
|
||||
|
|
|
@ -268,27 +268,6 @@ async function performLargePopupTests(win) {
|
|||
);
|
||||
await contentPainted;
|
||||
}
|
||||
|
||||
if (navigator.platform.indexOf("Mac") == 0) {
|
||||
await SpecialPowers.spawn(browser, [], async function () {
|
||||
let doc = content.document;
|
||||
doc.body.style = "padding-top: 400px;";
|
||||
|
||||
let select = doc.getElementById("one");
|
||||
select.options[41].selected = true;
|
||||
select.focus();
|
||||
});
|
||||
|
||||
await openSelectPopup("key", "select", win);
|
||||
|
||||
ok(
|
||||
selectPopup.getBoundingClientRect().top >
|
||||
browser.getBoundingClientRect().top,
|
||||
"select popup appears over selected item"
|
||||
);
|
||||
|
||||
await hideSelectPopup("escape", win);
|
||||
}
|
||||
}
|
||||
|
||||
// This test checks select elements with a large number of options to ensure that
|
||||
|
|
|
@ -4,33 +4,34 @@
|
|||
# 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/.
|
||||
|
||||
|
||||
@template
|
||||
def FirefoxBranding():
|
||||
if CONFIG['MOZ_BRANDING_DIRECTORY'] == 'browser/branding/official':
|
||||
if CONFIG["MOZ_BRANDING_DIRECTORY"] == "browser/branding/official":
|
||||
JS_PREFERENCE_PP_FILES += [
|
||||
'pref/firefox-branding.js',
|
||||
"pref/firefox-branding.js",
|
||||
]
|
||||
else:
|
||||
JS_PREFERENCE_FILES += [
|
||||
'pref/firefox-branding.js',
|
||||
"pref/firefox-branding.js",
|
||||
]
|
||||
|
||||
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
|
||||
FINAL_TARGET_FILES['..'] += [
|
||||
'firefox.VisualElementsManifest.xml',
|
||||
'private_browsing.VisualElementsManifest.xml',
|
||||
if CONFIG["MOZ_WIDGET_TOOLKIT"] == "windows":
|
||||
FINAL_TARGET_FILES[".."] += [
|
||||
"firefox.VisualElementsManifest.xml",
|
||||
"private_browsing.VisualElementsManifest.xml",
|
||||
]
|
||||
FINAL_TARGET_FILES.VisualElements += [
|
||||
'PrivateBrowsing_150.png',
|
||||
'PrivateBrowsing_70.png',
|
||||
'VisualElements_150.png',
|
||||
'VisualElements_70.png',
|
||||
"PrivateBrowsing_150.png",
|
||||
"PrivateBrowsing_70.png",
|
||||
"VisualElements_150.png",
|
||||
"VisualElements_70.png",
|
||||
]
|
||||
elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gtk':
|
||||
elif CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
|
||||
FINAL_TARGET_FILES.chrome.icons.default += [
|
||||
'default128.png',
|
||||
'default16.png',
|
||||
'default32.png',
|
||||
'default48.png',
|
||||
'default64.png',
|
||||
"default128.png",
|
||||
"default16.png",
|
||||
"default32.png",
|
||||
"default48.png",
|
||||
"default64.png",
|
||||
]
|
||||
|
|
|
@ -24,8 +24,7 @@ static const uint32_t ACTIVITY_STREAM_FLAGS =
|
|||
nsIAboutModule::ALLOW_SCRIPT | nsIAboutModule::ENABLE_INDEXED_DB |
|
||||
nsIAboutModule::URI_MUST_LOAD_IN_CHILD |
|
||||
nsIAboutModule::URI_CAN_LOAD_IN_PRIVILEGEDABOUT_PROCESS |
|
||||
nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT |
|
||||
nsIAboutModule::ALLOW_UNSANITIZED_CONTENT;
|
||||
nsIAboutModule::URI_SAFE_FOR_UNTRUSTED_CONTENT;
|
||||
|
||||
struct RedirEntry {
|
||||
const char* id;
|
||||
|
|
|
@ -1711,6 +1711,7 @@ export var Policies = {
|
|||
onBeforeAddons(manager, param) {
|
||||
let allowedPrefixes = [
|
||||
"accessibility.",
|
||||
"alerts.",
|
||||
"app.update.",
|
||||
"browser.",
|
||||
"datareporting.policy.",
|
||||
|
|
|
@ -153,6 +153,7 @@
|
|||
},
|
||||
"params": {
|
||||
"optional": true,
|
||||
"max_manifest_version": 2,
|
||||
"type": "array",
|
||||
"items": {
|
||||
"type": "object",
|
||||
|
|
|
@ -685,10 +685,7 @@ export class VirtualList extends MozLitElement {
|
|||
this.itemHeightEstimate = FXVIEW_ROW_HEIGHT_PX;
|
||||
this.maxRenderCountEstimate = Math.max(
|
||||
40,
|
||||
2 *
|
||||
Math.ceil(
|
||||
window.windowUtils.getRootBounds().height / this.itemHeightEstimate
|
||||
)
|
||||
2 * Math.ceil(window.innerHeight / this.itemHeightEstimate)
|
||||
);
|
||||
this.isSubList = false;
|
||||
this.isVisible = false;
|
||||
|
@ -702,11 +699,7 @@ export class VirtualList extends MozLitElement {
|
|||
this.parentElement.itemHeightEstimate = entry.contentRect.height;
|
||||
this.parentElement.maxRenderCountEstimate = Math.max(
|
||||
40,
|
||||
2 *
|
||||
Math.ceil(
|
||||
window.windowUtils.getRootBounds().height /
|
||||
this.itemHeightEstimate
|
||||
)
|
||||
2 * Math.ceil(window.innerHeight / this.itemHeightEstimate)
|
||||
);
|
||||
}
|
||||
});
|
||||
|
|
|
@ -19,7 +19,7 @@ class ViewState {
|
|||
currentTabWebcompatDetailsPromise;
|
||||
isURLValid = false;
|
||||
isDescriptionValid = false;
|
||||
isReasonValid = false;
|
||||
#isReasonValid = false;
|
||||
|
||||
constructor(doc) {
|
||||
this.#doc = doc;
|
||||
|
@ -78,6 +78,12 @@ class ViewState {
|
|||
return this.#mainView.querySelector("#report-broken-site-popup-reason");
|
||||
}
|
||||
|
||||
get reasonInputValidationHelper() {
|
||||
return this.#mainView.querySelector(
|
||||
"#report-broken-site-popup-missing-reason-validation-helper"
|
||||
);
|
||||
}
|
||||
|
||||
get reason() {
|
||||
const reason = this.reasonInput.selectedItem.id.replace(
|
||||
ViewState.REASON_CHOICES_ID_PREFIX,
|
||||
|
@ -107,21 +113,52 @@ class ViewState {
|
|||
this.isDescriptionValid = false;
|
||||
|
||||
this.reason = "choose";
|
||||
this.isReasonValid = false;
|
||||
this.#isReasonValid = false;
|
||||
this.toggleReasonValidationMessage(false);
|
||||
}
|
||||
|
||||
enableOrDisableSendButton(
|
||||
isReasonEnabled,
|
||||
isReasonOptional,
|
||||
isDescriptionOptional
|
||||
) {
|
||||
const isReasonOkay =
|
||||
!isReasonEnabled || isReasonOptional || this.isReasonValid;
|
||||
get isReasonValid() {
|
||||
return this.#isReasonValid;
|
||||
}
|
||||
|
||||
const isDescriptionOkay = isDescriptionOptional || this.isDescriptionValid;
|
||||
set isReasonValid(isValid) {
|
||||
this.#isReasonValid = isValid;
|
||||
this.toggleReasonValidationMessage(!isValid);
|
||||
}
|
||||
|
||||
this.sendButton.disabled =
|
||||
!this.isURLValid || !isReasonOkay || !isDescriptionOkay;
|
||||
toggleReasonValidationMessage(show) {
|
||||
const validation = this.reasonInputValidationHelper;
|
||||
validation.setCustomValidity(show ? "required" : "");
|
||||
validation.reportValidity();
|
||||
}
|
||||
|
||||
get isReasonOkay() {
|
||||
const { reasonEnabled, reasonIsOptional } =
|
||||
this.#doc.ownerGlobal.ReportBrokenSite;
|
||||
return !reasonEnabled || reasonIsOptional || this.isReasonValid;
|
||||
}
|
||||
|
||||
get isDescriptionOkay() {
|
||||
const { descriptionIsOptional } = this.#doc.ownerGlobal.ReportBrokenSite;
|
||||
return descriptionIsOptional || this.isDescriptionValid;
|
||||
}
|
||||
|
||||
checkAndShowInputValidity() {
|
||||
// This function focuses on the first invalid input (if any), updates the validity of
|
||||
// the helper input for the reason drop-down (so CSS :invalid state is updated),
|
||||
// and returns true if the form has an invalid input (false otherwise).
|
||||
const { isURLValid, isReasonOkay, isDescriptionOkay } = this;
|
||||
const validation = this.reasonInputValidationHelper;
|
||||
validation.setCustomValidity(isReasonOkay ? "" : "missing");
|
||||
validation.reportValidity();
|
||||
if (!isURLValid) {
|
||||
this.urlInput.focus();
|
||||
} else if (!isReasonOkay) {
|
||||
this.reasonInput.openMenu(true);
|
||||
} else if (!isDescriptionOkay) {
|
||||
this.descriptionInput.focus();
|
||||
}
|
||||
return !(isURLValid && isReasonOkay && isDescriptionOkay);
|
||||
}
|
||||
|
||||
get sendMoreInfoLink() {
|
||||
|
@ -221,6 +258,18 @@ export var ReportBrokenSite = new (class ReportBrokenSite {
|
|||
#descriptionIsOptional = true;
|
||||
#sendMoreInfoEnabled = true;
|
||||
|
||||
get reasonEnabled() {
|
||||
return this.#reasonEnabled;
|
||||
}
|
||||
|
||||
get reasonIsOptional() {
|
||||
return this.#reasonIsOptional;
|
||||
}
|
||||
|
||||
get descriptionIsOptional() {
|
||||
return this.#descriptionIsOptional;
|
||||
}
|
||||
|
||||
constructor() {
|
||||
for (const [name, [pref, dflt]] of Object.entries({
|
||||
dataReportingPref: [ReportBrokenSite.DATAREPORTING_PREF, false],
|
||||
|
@ -368,6 +417,9 @@ export var ReportBrokenSite = new (class ReportBrokenSite {
|
|||
|
||||
#initMainView(state) {
|
||||
state.sendButton.addEventListener("command", async ({ target }) => {
|
||||
if (state.checkAndShowInputValidity()) {
|
||||
return;
|
||||
}
|
||||
const multiview = target.closest("panelmultiview");
|
||||
this.#recordGleanEvent("send");
|
||||
await this.#sendReportAsGleanPing(state);
|
||||
|
@ -394,11 +446,6 @@ export var ReportBrokenSite = new (class ReportBrokenSite {
|
|||
const newUrlValid = target.value && target.checkValidity();
|
||||
if (state.isURLValid != newUrlValid) {
|
||||
state.isURLValid = newUrlValid;
|
||||
state.enableOrDisableSendButton(
|
||||
this.#reasonEnabled,
|
||||
this.#reasonIsOptional,
|
||||
this.#descriptionIsOptional
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -406,11 +453,6 @@ export var ReportBrokenSite = new (class ReportBrokenSite {
|
|||
const newDescValid = gDescriptionCheckRE.test(target.value);
|
||||
if (state.isDescriptionValid != newDescValid) {
|
||||
state.isDescriptionValid = newDescValid;
|
||||
state.enableOrDisableSendButton(
|
||||
this.#reasonEnabled,
|
||||
this.#reasonIsOptional,
|
||||
this.#descriptionIsOptional
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -420,11 +462,6 @@ export var ReportBrokenSite = new (class ReportBrokenSite {
|
|||
const newValidity = choiceId !== ViewState.CHOOSE_A_REASON_OPT_ID;
|
||||
if (state.isReasonValid != newValidity) {
|
||||
state.isReasonValid = newValidity;
|
||||
state.enableOrDisableSendButton(
|
||||
this.#reasonEnabled,
|
||||
this.#reasonIsOptional,
|
||||
this.#descriptionIsOptional
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -479,12 +516,6 @@ export var ReportBrokenSite = new (class ReportBrokenSite {
|
|||
state.descriptionLabelRequired.hidden = this.#descriptionIsOptional;
|
||||
state.descriptionLabelOptional.hidden = !this.#descriptionIsOptional;
|
||||
|
||||
state.enableOrDisableSendButton(
|
||||
this.#reasonEnabled,
|
||||
this.#reasonIsOptional,
|
||||
this.#descriptionIsOptional
|
||||
);
|
||||
|
||||
this.#recordGleanEvent("opened", { source });
|
||||
|
||||
if (didReset || !state.currentTabWebcompatDetailsPromise) {
|
||||
|
|
|
@ -5,7 +5,8 @@
|
|||
<panel id="report-broken-main-menu-panel"
|
||||
class="cui-widget-panel panel-no-padding"
|
||||
type="arrow"
|
||||
role="document"
|
||||
role="alertdialog"
|
||||
aria-labelledby="report-broken-site-panel-intro"
|
||||
noautofocus="true"
|
||||
tabspecific="true"
|
||||
flip="slide"
|
||||
|
@ -30,9 +31,7 @@
|
|||
</box>
|
||||
<toolbarseparator></toolbarseparator>
|
||||
<vbox id="report-broken-site-panel-container"
|
||||
class="panel-subview-body"
|
||||
role="alertdialog"
|
||||
aria-labelledby="report-broken-site-panel-intro">
|
||||
class="panel-subview-body">
|
||||
<html:p data-l10n-id="report-broken-site-panel-intro"/>
|
||||
<label id="report-broken-site-popup-url-label"
|
||||
control="report-broken-site-popup-url"
|
||||
|
@ -40,7 +39,11 @@
|
|||
<html:input id="report-broken-site-popup-url"
|
||||
allow-arrow-navigation="true"
|
||||
aria-describedby="report-broken-site-panel-intro"
|
||||
type="url"/>
|
||||
type="url" required="required" aria-required="true" />
|
||||
<label id="report-broken-site-popup-invalid-url-msg"
|
||||
class="invalid-message text-error"
|
||||
role="alert"
|
||||
data-l10n-id="report-broken-site-panel-invalid-url-label"/>
|
||||
<label id="report-broken-site-popup-reason-label"
|
||||
control="report-broken-site-popup-reason"
|
||||
hidden="true"
|
||||
|
@ -71,6 +74,12 @@
|
|||
data-l10n-id="report-broken-site-panel-reason-other"/>
|
||||
</menupopup>
|
||||
</menulist>
|
||||
<!-- menulist does not support :invalid, so we set custom validity on this input instead -->
|
||||
<html:input id="report-broken-site-popup-missing-reason-validation-helper"/>
|
||||
<label id="report-broken-site-popup-missing-reason-msg"
|
||||
class="invalid-message text-error"
|
||||
role="alert"
|
||||
data-l10n-id="report-broken-site-panel-missing-reason-label"/>
|
||||
<label id="report-broken-site-popup-description-label"
|
||||
control="report-broken-site-popup-description"
|
||||
hidden="true"
|
||||
|
|
|
@ -19,6 +19,8 @@ support-files = [
|
|||
|
||||
["browser_back_buttons.js"]
|
||||
|
||||
["browser_error_messages.js"]
|
||||
|
||||
["browser_tab_switch_handling.js"]
|
||||
|
||||
["browser_prefers_contrast.js"]
|
||||
|
|
|
@ -0,0 +1,56 @@
|
|||
/* Any copyright is dedicated to the Public Domain.
|
||||
* http://creativecommons.org/publicdomain/zero/1.0/ */
|
||||
|
||||
/* Test that the Report Broken Site errors messages are shown on
|
||||
* the UI if the user enters an invalid URL or clicks the send
|
||||
* button while it is disabled due to not selecting a "reason"
|
||||
*/
|
||||
|
||||
"use strict";
|
||||
|
||||
add_common_setup();
|
||||
|
||||
add_task(async function test() {
|
||||
ensureReportBrokenSitePreffedOn();
|
||||
ensureReasonRequired();
|
||||
|
||||
await BrowserTestUtils.withNewTab(REPORTABLE_PAGE_URL, async function () {
|
||||
for (const menu of [AppMenu(), ProtectionsPanel(), HelpMenu()]) {
|
||||
const rbs = await menu.openReportBrokenSite();
|
||||
const { reasonDropdownPopup, sendButton, URLInput } = rbs;
|
||||
|
||||
rbs.isURLInvalidMessageHidden();
|
||||
rbs.isReasonNeededMessageHidden();
|
||||
|
||||
rbs.setURL("");
|
||||
rbs.isURLInvalidMessageShown();
|
||||
rbs.isReasonNeededMessageHidden();
|
||||
|
||||
rbs.setURL("https://asdf");
|
||||
rbs.isURLInvalidMessageHidden();
|
||||
rbs.isReasonNeededMessageHidden();
|
||||
|
||||
rbs.setURL("http:/ /asdf");
|
||||
rbs.isURLInvalidMessageShown();
|
||||
rbs.isReasonNeededMessageHidden();
|
||||
|
||||
rbs.setURL("https://asdf");
|
||||
await clickAndAwait(sendButton, "popupshown", reasonDropdownPopup);
|
||||
rbs.isURLInvalidMessageHidden();
|
||||
rbs.isReasonNeededMessageShown();
|
||||
await rbs.dismissDropdownPopup();
|
||||
|
||||
rbs.chooseReason("slow");
|
||||
rbs.isURLInvalidMessageHidden();
|
||||
rbs.isReasonNeededMessageHidden();
|
||||
|
||||
rbs.setURL("");
|
||||
rbs.chooseReason("choose");
|
||||
await clickAndAwait(sendButton, "focus", URLInput);
|
||||
rbs.isURLInvalidMessageShown();
|
||||
rbs.isReasonNeededMessageShown();
|
||||
|
||||
rbs.close();
|
||||
}
|
||||
});
|
||||
});
|
|
@ -114,15 +114,21 @@ async function testTabOrder(menu) {
|
|||
|
||||
ensureReasonRequired();
|
||||
rbs = await menu.openReportBrokenSite();
|
||||
rbs.sendButton.disabled = false;
|
||||
await ensureExpectedTabOrder(showsBackButton, true, true);
|
||||
await rbs.close();
|
||||
rbs = await menu.openReportBrokenSite();
|
||||
rbs.chooseReason("slow");
|
||||
await ensureExpectedTabOrder(showsBackButton, true, true);
|
||||
await rbs.clickCancel();
|
||||
|
||||
ensureSendMoreInfoDisabled();
|
||||
rbs = await menu.openReportBrokenSite();
|
||||
rbs.sendButton.disabled = false;
|
||||
await ensureExpectedTabOrder(showsBackButton, true, false);
|
||||
await rbs.close();
|
||||
rbs = await menu.openReportBrokenSite();
|
||||
rbs.chooseReason("slow");
|
||||
await ensureExpectedTabOrder(showsBackButton, true, false);
|
||||
await rbs.clickCancel();
|
||||
|
||||
ensureReasonOptional();
|
||||
rbs = await menu.openReportBrokenSite();
|
||||
|
|
|
@ -55,7 +55,10 @@ add_task(async function testReasonDropdown() {
|
|||
ensureReasonRequired();
|
||||
rbs = await AppMenu().openReportBrokenSite();
|
||||
await rbs.isReasonRequired();
|
||||
await rbs.isSendButtonDisabled();
|
||||
await rbs.isSendButtonEnabled();
|
||||
const { reasonDropdownPopup, sendButton } = rbs;
|
||||
await clickAndAwait(sendButton, "popupshown", reasonDropdownPopup);
|
||||
await rbs.dismissDropdownPopup();
|
||||
rbs.chooseReason("media");
|
||||
await rbs.isSendButtonEnabled();
|
||||
await clickSendAndCheckPing(rbs, "media");
|
||||
|
|
|
@ -38,6 +38,12 @@ function add_common_setup() {
|
|||
});
|
||||
}
|
||||
|
||||
function clickAndAwait(toClick, evt, target) {
|
||||
const menuPromise = BrowserTestUtils.waitForEvent(target, evt);
|
||||
EventUtils.synthesizeMouseAtCenter(toClick, {}, window);
|
||||
return menuPromise;
|
||||
}
|
||||
|
||||
async function openTab(url, win) {
|
||||
const options = {
|
||||
gBrowser:
|
||||
|
@ -248,10 +254,26 @@ class ReportBrokenSiteHelper {
|
|||
return this.win.document.getElementById("report-broken-site-popup-url");
|
||||
}
|
||||
|
||||
get URLInvalidMessage() {
|
||||
return this.win.document.getElementById(
|
||||
"report-broken-site-popup-invalid-url-msg"
|
||||
);
|
||||
}
|
||||
|
||||
get reasonInput() {
|
||||
return this.win.document.getElementById("report-broken-site-popup-reason");
|
||||
}
|
||||
|
||||
get reasonDropdownPopup() {
|
||||
return this.reasonInput.querySelector("menupopup");
|
||||
}
|
||||
|
||||
get reasonRequiredMessage() {
|
||||
return this.win.document.getElementById(
|
||||
"report-broken-site-popup-missing-reason-msg"
|
||||
);
|
||||
}
|
||||
|
||||
get reasonLabelRequired() {
|
||||
return this.win.document.getElementById(
|
||||
"report-broken-site-popup-reason-label"
|
||||
|
@ -322,6 +344,15 @@ class ReportBrokenSiteHelper {
|
|||
);
|
||||
}
|
||||
|
||||
dismissDropdownPopup() {
|
||||
const menuPromise = BrowserTestUtils.waitForEvent(
|
||||
this.reasonDropdownPopup,
|
||||
"popuphidden"
|
||||
);
|
||||
EventUtils.synthesizeKey("KEY_Escape");
|
||||
return menuPromise;
|
||||
}
|
||||
|
||||
setDescription(value) {
|
||||
this.#setInput(this.descriptionTextarea, value);
|
||||
}
|
||||
|
@ -330,6 +361,34 @@ class ReportBrokenSiteHelper {
|
|||
is(this.URLInput.value, expected);
|
||||
}
|
||||
|
||||
isURLInvalidMessageShown() {
|
||||
ok(
|
||||
BrowserTestUtils.is_visible(this.URLInvalidMessage),
|
||||
"'Please enter a valid URL' message is shown"
|
||||
);
|
||||
}
|
||||
|
||||
isURLInvalidMessageHidden() {
|
||||
ok(
|
||||
!BrowserTestUtils.is_visible(this.URLInvalidMessage),
|
||||
"'Please enter a valid URL' message is hidden"
|
||||
);
|
||||
}
|
||||
|
||||
isReasonNeededMessageShown() {
|
||||
ok(
|
||||
BrowserTestUtils.is_visible(this.reasonRequiredMessage),
|
||||
"'Please choose a reason' message is shown"
|
||||
);
|
||||
}
|
||||
|
||||
isReasonNeededMessageHidden() {
|
||||
ok(
|
||||
!BrowserTestUtils.is_visible(this.reasonRequiredMessage),
|
||||
"'Please choose a reason' message is hidden"
|
||||
);
|
||||
}
|
||||
|
||||
isSendButtonEnabled() {
|
||||
ok(BrowserTestUtils.is_visible(this.sendButton), "Send button is visible");
|
||||
ok(!this.sendButton.disabled, "Send button is enabled");
|
||||
|
|
|
@ -1,82 +0,0 @@
|
|||
/* 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/. */
|
||||
|
||||
"use strict";
|
||||
|
||||
module.exports = {
|
||||
rules: {
|
||||
// Rules from the mozilla plugin
|
||||
"mozilla/balanced-listeners": "error",
|
||||
"mozilla/no-aArgs": "error",
|
||||
"mozilla/var-only-at-top-level": "error",
|
||||
|
||||
// No expressions where a statement is expected
|
||||
"no-unused-expressions": "error",
|
||||
|
||||
// No declaring variables that are never used
|
||||
"no-unused-vars": [
|
||||
"error",
|
||||
{
|
||||
args: "none",
|
||||
vars: "all",
|
||||
},
|
||||
],
|
||||
|
||||
// No using variables before defined
|
||||
"no-use-before-define": "error",
|
||||
|
||||
// Disallow using variables outside the blocks they are defined (especially
|
||||
// since only let and const are used, see "no-var").
|
||||
"block-scoped-var": "error",
|
||||
|
||||
// Warn about cyclomatic complexity in functions.
|
||||
complexity: ["error", { max: 26 }],
|
||||
|
||||
// Maximum depth callbacks can be nested.
|
||||
"max-nested-callbacks": ["error", 4],
|
||||
|
||||
// Disallow using the console API, except for error statments.
|
||||
"no-console": ["error", { allow: ["error"] }],
|
||||
|
||||
// Disallow fallthrough of case statements, except if there is a comment.
|
||||
"no-fallthrough": "error",
|
||||
|
||||
// Disallow use of multiline strings (use template strings instead).
|
||||
"no-multi-str": "error",
|
||||
|
||||
// Disallow usage of __proto__ property.
|
||||
"no-proto": "error",
|
||||
|
||||
// Disallow use of assignment in return statement. It is preferable for a
|
||||
// single line of code to have only one easily predictable effect.
|
||||
"no-return-assign": "error",
|
||||
|
||||
// Require use of the second argument for parseInt().
|
||||
radix: "error",
|
||||
|
||||
// Require "use strict" to be defined globally in the script.
|
||||
strict: ["error", "global"],
|
||||
|
||||
// Disallow Yoda conditions (where literal value comes first).
|
||||
yoda: "error",
|
||||
|
||||
// Disallow function or variable declarations in nested blocks
|
||||
"no-inner-declarations": "error",
|
||||
},
|
||||
|
||||
overrides: [
|
||||
{
|
||||
files: "**/head.js",
|
||||
rules: {
|
||||
"no-unused-vars": [
|
||||
"error",
|
||||
{
|
||||
args: "none",
|
||||
vars: "local",
|
||||
},
|
||||
],
|
||||
},
|
||||
},
|
||||
],
|
||||
};
|
|
@ -10,6 +10,8 @@ support-files = [
|
|||
"head_address.js",
|
||||
]
|
||||
|
||||
["browser_address_capture_form_removal.js"]
|
||||
|
||||
["browser_address_doorhanger_display.js"]
|
||||
|
||||
["browser_address_doorhanger_invalid_fields.js"]
|
||||
|
|
|
@ -0,0 +1,124 @@
|
|||
"use strict";
|
||||
|
||||
async function expectSavedAddresses(expectedAddresses) {
|
||||
const addresses = await getAddresses();
|
||||
is(
|
||||
addresses.length,
|
||||
expectedAddresses.length,
|
||||
`${addresses.length} address in the storage`
|
||||
);
|
||||
|
||||
for (let i = 0; i < expectedAddresses.length; i++) {
|
||||
for (const [key, value] of Object.entries(expectedAddresses[i])) {
|
||||
is(addresses[i][key] ?? "", value, `field ${key} should be equal`);
|
||||
}
|
||||
}
|
||||
return addresses;
|
||||
}
|
||||
|
||||
const ADDRESS_FIELD_VALUES = {
|
||||
"given-name": "Test User",
|
||||
organization: "Sesame Street",
|
||||
"street-address": "123 Sesame Street",
|
||||
};
|
||||
|
||||
add_setup(async function () {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [
|
||||
["extensions.formautofill.addresses.capture.v2.enabled", true],
|
||||
["extensions.formautofill.addresses.supported", "on"],
|
||||
["extensions.formautofill.heuristics.captureOnFormRemoval", true],
|
||||
],
|
||||
});
|
||||
await removeAllRecords();
|
||||
});
|
||||
|
||||
/**
|
||||
* Tests if the address is captured (address doorhanger is shown) after a
|
||||
* successful xhr or fetch request followed by a form removal and
|
||||
* that the stored address record has the right values.
|
||||
*/
|
||||
add_task(async function test_address_captured_after_form_removal() {
|
||||
const onStorageChanged = waitForStorageChangedEvents("add");
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: ADDRESS_FORM_URL },
|
||||
async function (browser) {
|
||||
const onPopupShown = waitForPopupShown();
|
||||
|
||||
info("Update identified address fields");
|
||||
// We don't submit the form
|
||||
await focusUpdateSubmitForm(
|
||||
browser,
|
||||
{
|
||||
focusSelector: "#given-name",
|
||||
newValues: {
|
||||
"#given-name": ADDRESS_FIELD_VALUES["given-name"],
|
||||
"#organization": ADDRESS_FIELD_VALUES.organization,
|
||||
"#street-address": ADDRESS_FIELD_VALUES["street-address"],
|
||||
},
|
||||
},
|
||||
false
|
||||
);
|
||||
|
||||
info("Infer a successfull fetch request");
|
||||
await SpecialPowers.spawn(browser, [], async () => {
|
||||
await content.fetch(
|
||||
"https://example.org/browser/browser/extensions/formautofill/test/browser/empty.html"
|
||||
);
|
||||
});
|
||||
|
||||
info("Infer form removal");
|
||||
await SpecialPowers.spawn(browser, [], async function () {
|
||||
let form = content.document.getElementById("form");
|
||||
form.parentNode.remove(form);
|
||||
});
|
||||
info("Wait for address doorhanger");
|
||||
await onPopupShown;
|
||||
|
||||
info("Click Save in address doorhanger");
|
||||
await clickDoorhangerButton(MAIN_BUTTON, 0);
|
||||
}
|
||||
);
|
||||
|
||||
info("Wait for the address to be added to the storage.");
|
||||
await onStorageChanged;
|
||||
|
||||
info("Ensure that address record was captured and saved correctly.");
|
||||
await expectSavedAddresses([ADDRESS_FIELD_VALUES]);
|
||||
|
||||
await removeAllRecords();
|
||||
});
|
||||
|
||||
/**
|
||||
* Tests that the address is not captured without a prior fetch or xhr request event
|
||||
*/
|
||||
add_task(async function test_address_not_captured_without_prior_fetch() {
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: ADDRESS_FORM_URL },
|
||||
async function (browser) {
|
||||
info("Update identified address fields");
|
||||
// We don't submit the form
|
||||
await focusUpdateSubmitForm(
|
||||
browser,
|
||||
{
|
||||
focusSelector: "#given-name",
|
||||
newValues: {
|
||||
"#given-name": ADDRESS_FIELD_VALUES["given-name"],
|
||||
"#organization": ADDRESS_FIELD_VALUES.organization,
|
||||
"#street-address": ADDRESS_FIELD_VALUES["street-address"],
|
||||
},
|
||||
},
|
||||
false
|
||||
);
|
||||
|
||||
info("Infer form removal");
|
||||
await SpecialPowers.spawn(browser, [], async function () {
|
||||
let form = content.document.getElementById("form");
|
||||
form.parentNode.remove(form);
|
||||
});
|
||||
|
||||
info("Ensure that address doorhanger is not shown");
|
||||
await ensureNoDoorhanger(browser);
|
||||
}
|
||||
);
|
||||
});
|
|
@ -17,6 +17,8 @@ support-files = [
|
|||
["browser_anti_clickjacking.js"]
|
||||
skip-if = ["!debug && os == 'mac'"] # perma-fail see Bug 1600059
|
||||
|
||||
["browser_creditCard_capture_form_removal.js"]
|
||||
|
||||
["browser_creditCard_doorhanger_action.js"]
|
||||
skip-if = [
|
||||
"!debug && os == 'mac'", # perma-fail see Bug 1655601
|
||||
|
|
|
@ -0,0 +1,115 @@
|
|||
"use strict";
|
||||
|
||||
const CC_VALUES = {
|
||||
"cc-name": "User",
|
||||
"cc-number": "5577000055770004",
|
||||
"cc-exp-month": 12,
|
||||
"cc-exp-year": 2017,
|
||||
};
|
||||
|
||||
add_setup(async function () {
|
||||
await SpecialPowers.pushPrefEnv({
|
||||
set: [["extensions.formautofill.heuristics.captureOnFormRemoval", true]],
|
||||
});
|
||||
await removeAllRecords();
|
||||
});
|
||||
|
||||
/**
|
||||
* Tests if the credit card is captured (cc doorhanger is shown) after a
|
||||
* successful xhr or fetch request followed by a form removal and
|
||||
* that the stored credit card record has the right values.
|
||||
*/
|
||||
add_task(async function test_credit_card_captured_after_form_removal() {
|
||||
const onStorageChanged = waitForStorageChangedEvents("add");
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: CREDITCARD_FORM_URL },
|
||||
async function (browser) {
|
||||
const onPopupShown = waitForPopupShown();
|
||||
info("Update identified credit card fields");
|
||||
// We don't submit the form
|
||||
await focusUpdateSubmitForm(
|
||||
browser,
|
||||
{
|
||||
focusSelector: "#cc-name",
|
||||
newValues: {
|
||||
"#cc-name": CC_VALUES["cc-name"],
|
||||
"#cc-number": CC_VALUES["cc-number"],
|
||||
"#cc-exp-month": CC_VALUES["cc-exp-month"],
|
||||
"#cc-exp-year": CC_VALUES["cc-exp-year"],
|
||||
},
|
||||
},
|
||||
false
|
||||
);
|
||||
|
||||
info("Infer a successfull fetch request");
|
||||
await SpecialPowers.spawn(browser, [], async () => {
|
||||
await content.fetch(
|
||||
"https://example.org/browser/browser/extensions/formautofill/test/browser/empty.html"
|
||||
);
|
||||
});
|
||||
|
||||
info("Infer form removal");
|
||||
await SpecialPowers.spawn(browser, [], async function () {
|
||||
let form = content.document.getElementById("form");
|
||||
form.parentNode.remove(form);
|
||||
});
|
||||
|
||||
info("Wait for credit card doorhanger");
|
||||
await onPopupShown;
|
||||
|
||||
info("Click Save in credit card doorhanger");
|
||||
await clickDoorhangerButton(MAIN_BUTTON);
|
||||
}
|
||||
);
|
||||
|
||||
info("Wait for the credit card to be added to the storage.");
|
||||
await onStorageChanged;
|
||||
|
||||
const storedCreditCards = await getCreditCards();
|
||||
let actualCreditCard = storedCreditCards[0];
|
||||
actualCreditCard["cc-number"] = await OSKeyStore.decrypt(
|
||||
actualCreditCard["cc-number-encrypted"]
|
||||
);
|
||||
|
||||
for (let key in CC_VALUES) {
|
||||
let expected = CC_VALUES[key];
|
||||
let actual = actualCreditCard[key];
|
||||
is(expected, actual, `${key} should be equal`);
|
||||
}
|
||||
await removeAllRecords();
|
||||
});
|
||||
|
||||
/**
|
||||
* Tests that the credit card is not captured without a prior fetch or xhr request event
|
||||
*/
|
||||
add_task(async function test_credit_card_not_captured_without_prior_fetch() {
|
||||
await BrowserTestUtils.withNewTab(
|
||||
{ gBrowser, url: CREDITCARD_FORM_URL },
|
||||
async function (browser) {
|
||||
info("Update identified credit card fields");
|
||||
// We don't submit the form
|
||||
await focusUpdateSubmitForm(
|
||||
browser,
|
||||
{
|
||||
focusSelector: "#cc-name",
|
||||
newValues: {
|
||||
"#cc-name": CC_VALUES["cc-name"],
|
||||
"#cc-number": CC_VALUES["cc-number"],
|
||||
"#cc-exp-month": CC_VALUES["cc-exp-month"],
|
||||
"#cc-exp-year": CC_VALUES["cc-exp-year"],
|
||||
},
|
||||
},
|
||||
false
|
||||
);
|
||||
|
||||
info("Infer form removal");
|
||||
await SpecialPowers.spawn(browser, [], async function () {
|
||||
let form = content.document.getElementById("form");
|
||||
form.parentNode.remove(form);
|
||||
});
|
||||
|
||||
info("Ensure that credit card doorhanger is not shown");
|
||||
await ensureNoDoorhanger(browser);
|
||||
}
|
||||
);
|
||||
});
|
|
@ -244,7 +244,7 @@ add_task(async function test_popup_opened() {
|
|||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_exp: "undetected" },
|
||||
{ cc_exp: "undetected", cc_number_multi_parts: 1 },
|
||||
"autocomplete"
|
||||
),
|
||||
},
|
||||
|
@ -312,7 +312,12 @@ add_task(async function test_popup_opened_form_without_autocomplete() {
|
|||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_number: "1", cc_name: "1", cc_exp: "undetected" },
|
||||
{
|
||||
cc_number: "1",
|
||||
cc_name: "1",
|
||||
cc_exp: "undetected",
|
||||
cc_number_multi_parts: 1,
|
||||
},
|
||||
"regexp"
|
||||
),
|
||||
},
|
||||
|
@ -368,7 +373,10 @@ add_task(
|
|||
await assertGleanTelemetry([
|
||||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra({ cc_number: "1" }, "undetected"),
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_number: "1", cc_number_multi_parts: 1 },
|
||||
"undetected"
|
||||
),
|
||||
},
|
||||
{
|
||||
event_name: "formPopupShown",
|
||||
|
@ -520,7 +528,7 @@ add_task(async function test_submit_creditCard_new() {
|
|||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_exp: "undetected" },
|
||||
{ cc_exp: "undetected", cc_number_multi_parts: 1 },
|
||||
"autocomplete"
|
||||
),
|
||||
},
|
||||
|
@ -634,7 +642,7 @@ add_task(async function test_submit_creditCard_autofill() {
|
|||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_exp: "undetected" },
|
||||
{ cc_exp: "undetected", cc_number_multi_parts: 1 },
|
||||
"autocomplete"
|
||||
),
|
||||
},
|
||||
|
@ -767,7 +775,7 @@ add_task(async function test_submit_creditCard_update() {
|
|||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_exp: "undetected" },
|
||||
{ cc_exp: "undetected", cc_number_multi_parts: 1 },
|
||||
"autocomplete"
|
||||
),
|
||||
},
|
||||
|
@ -1043,7 +1051,7 @@ add_task(async function test_clear_creditCard_autofill() {
|
|||
{
|
||||
event_name: "formDetected",
|
||||
expected_extra: buildccFormv2Extra(
|
||||
{ cc_exp: "undetected" },
|
||||
{ cc_exp: "undetected", cc_number_multi_parts: 1 },
|
||||
"autocomplete"
|
||||
),
|
||||
},
|
||||
|
|
|
@ -48,3 +48,6 @@ report-broken-site-panel-report-sent-header =
|
|||
.label = Your report has been sent
|
||||
.title = Your report has been sent
|
||||
report-broken-site-panel-report-sent-text = Thank you for helping { -brand-product-name } make the web more open, accessible, and better for everyone.
|
||||
|
||||
report-broken-site-panel-invalid-url-label = Please enter a valid URL
|
||||
report-broken-site-panel-missing-reason-label = Please choose a reason
|
||||
|
|
|
@ -339,7 +339,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "51f050366c17768410c43c96443c80681e066661"
|
||||
"revision": "c7a8f688fdbc2af3a722734ef371ea96aa5ad525"
|
||||
},
|
||||
"da": {
|
||||
"pin": false,
|
||||
|
@ -357,7 +357,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "45445f8cba3aa1ecbee70872d1e61f94d783452f"
|
||||
"revision": "6bd9641be8a71be067a466cec44da109dc8243d1"
|
||||
},
|
||||
"de": {
|
||||
"pin": false,
|
||||
|
@ -375,7 +375,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "5a6826c793e4fe5adf0bcbca29b47693b0f44ee2"
|
||||
"revision": "bad6bdd5d7e6e575a9067a0b74a5a4728567067b"
|
||||
},
|
||||
"dsb": {
|
||||
"pin": false,
|
||||
|
@ -393,7 +393,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "e925651655ea24637c1d5b4ab6f7c8e19ac583d1"
|
||||
"revision": "efe00a1cbfcadfb4dac875062ad3d18e3c11b542"
|
||||
},
|
||||
"el": {
|
||||
"pin": false,
|
||||
|
@ -411,7 +411,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "84b86adea796234e43d6ef96f1a191aea3e13a81"
|
||||
"revision": "c7d8b6525617245678e1bd609b52d3715287c775"
|
||||
},
|
||||
"en-CA": {
|
||||
"pin": false,
|
||||
|
@ -483,7 +483,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "79337d1715622ca476f1aa373faa3878baf4f02c"
|
||||
"revision": "7bcb8ca6d98736fdcc4df2ffbed7ac0797f6ef23"
|
||||
},
|
||||
"es-CL": {
|
||||
"pin": false,
|
||||
|
@ -645,7 +645,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "6b923d9639f8498070848d977edf724ca57a647a"
|
||||
"revision": "313b0d72a9e454039dd74482feaea4f44db08cfe"
|
||||
},
|
||||
"fur": {
|
||||
"pin": false,
|
||||
|
@ -663,7 +663,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "5ad6da14f202f5b3f4ea7d0d609de24c2e588919"
|
||||
"revision": "f8aaf8ba5a0241e27c9acebfd08185ea8b8e072d"
|
||||
},
|
||||
"fy-NL": {
|
||||
"pin": false,
|
||||
|
@ -789,7 +789,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "97a1b34dde65909913a9b87d4130f16132b6eeec"
|
||||
"revision": "0d4b415374e69c3be59de96df7f41c381b2fe09b"
|
||||
},
|
||||
"hi-IN": {
|
||||
"pin": false,
|
||||
|
@ -843,7 +843,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "c7c81e6d9d21db0bb8265be3ef5da2c6a3fb26dd"
|
||||
"revision": "b8cfeff5291f171b6535212422e92fd3f995064e"
|
||||
},
|
||||
"hu": {
|
||||
"pin": false,
|
||||
|
@ -951,7 +951,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "7f438e9f8363ef2c8352d68631009ff5cc2950d8"
|
||||
"revision": "9d7a272215838c6b535d29f6a54aae3a9ae8d0bb"
|
||||
},
|
||||
"it": {
|
||||
"pin": false,
|
||||
|
@ -969,7 +969,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "8cbc161106c3bed261810d3d4366f3feb1771e56"
|
||||
"revision": "8a68364c0a781ca8941046c8e8d1aae7d886626b"
|
||||
},
|
||||
"ja": {
|
||||
"pin": false,
|
||||
|
@ -1299,7 +1299,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "70e4415a0257cd69624ec83854a0768a1ac66d9c"
|
||||
"revision": "1cd5df10d59cb0b07e29eb9f7c0dea33d06f057d"
|
||||
},
|
||||
"ne-NP": {
|
||||
"pin": false,
|
||||
|
@ -1335,7 +1335,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "55b7e4654fd71d3702518cd9ad4b399856a13f3b"
|
||||
"revision": "218f30bde251a563692e7bd01237738ac3b41e3d"
|
||||
},
|
||||
"nn-NO": {
|
||||
"pin": false,
|
||||
|
@ -1389,7 +1389,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "10555078c2e11cdb239fcddc0ae618608268f483"
|
||||
"revision": "d9aba4728533f9f42d4084e66be4c6a1148563dd"
|
||||
},
|
||||
"pl": {
|
||||
"pin": false,
|
||||
|
@ -1425,7 +1425,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "8bef6d84911700709073d5df1aaf52cee7937fa0"
|
||||
"revision": "fe1439dc3bdf244818f738c42b71799bbf62ea79"
|
||||
},
|
||||
"pt-PT": {
|
||||
"pin": false,
|
||||
|
@ -1461,7 +1461,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "d657c2f22786766da93976dc284fe02be5be67fa"
|
||||
"revision": "21ecaed0f3f279e82df3e11c2838fa35e3416c83"
|
||||
},
|
||||
"ro": {
|
||||
"pin": false,
|
||||
|
@ -1497,7 +1497,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "89db9b49ef8277c5d8035258ee9314f8cad9a94b"
|
||||
"revision": "efcc94aa7fe302149e27bcef97d38917d0249d0f"
|
||||
},
|
||||
"sat": {
|
||||
"pin": false,
|
||||
|
@ -1713,7 +1713,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "3402309cc1c5d9aa00770cecfefa8db4207d537c"
|
||||
"revision": "a753ec0a910bc5bc3173d6525ae7a9ba9d8c42a9"
|
||||
},
|
||||
"szl": {
|
||||
"pin": false,
|
||||
|
@ -1803,7 +1803,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "000f753244cc15bf4b0d0e13979b37416718bcde"
|
||||
"revision": "7d702dc4f71f374149b6eb5c5d4b01135249cde5"
|
||||
},
|
||||
"tl": {
|
||||
"pin": false,
|
||||
|
@ -1875,7 +1875,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "1c039c8eb431d19c482c01e7ebfe3bf754470a5a"
|
||||
"revision": "543226a34b9b930d140e802f76c9d48d254c0c43"
|
||||
},
|
||||
"ur": {
|
||||
"pin": false,
|
||||
|
@ -1929,7 +1929,7 @@
|
|||
"win64-aarch64-devedition",
|
||||
"win64-devedition"
|
||||
],
|
||||
"revision": "c406a6b38d7ea5e99e058e8e1fceaf807fc4a229"
|
||||
"revision": "1ac4becc8100dd53228974dceb23a8465c4b235c"
|
||||
},
|
||||
"wo": {
|
||||
"pin": false,
|
||||
|
|
|
@ -2068,15 +2068,40 @@ panelview:not([mainview]) #PanelUI-whatsNew-title {
|
|||
}
|
||||
}
|
||||
|
||||
input:invalid,
|
||||
menulist:has(+ input:invalid) {
|
||||
border-color: transparent;
|
||||
outline: 2px solid var(--color-error-outline);
|
||||
outline-offset: -1px;
|
||||
}
|
||||
|
||||
> .panel-subview-body > label {
|
||||
margin-block: 1.5em 0.5em;
|
||||
|
||||
&.invalid-message {
|
||||
margin-block: 0.5em 0;
|
||||
background-image: url("chrome://global/skin/icons/error.svg");
|
||||
background-position: left center;
|
||||
background-repeat: no-repeat;
|
||||
-moz-context-properties: fill;
|
||||
fill: var(--icon-color-critical);
|
||||
padding-inline-start: calc(16px + 0.25em);
|
||||
|
||||
&:-moz-locale-dir(rtl) {
|
||||
background-position-x: right;
|
||||
}
|
||||
|
||||
input:valid + & {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.main-view {
|
||||
p {
|
||||
margin-block: 0;
|
||||
}
|
||||
|
||||
> .panel-subview-body > label {
|
||||
margin-block: 1.5em 0.5em;
|
||||
}
|
||||
|
||||
a {
|
||||
margin-top: 1.5em;
|
||||
}
|
||||
|
@ -2112,3 +2137,11 @@ panelview:not([mainview]) #PanelUI-whatsNew-title {
|
|||
#report-broken-site-panel-container {
|
||||
padding: 8px 16px 16px;
|
||||
}
|
||||
|
||||
/* <menulist> does not support :invalid, so we use setCustomValidity
|
||||
* on a "helper" input. We must hide it with CSS, as using the HTML
|
||||
* "hidden" attribute will also keep it from working with :invalid.
|
||||
*/
|
||||
#report-broken-site-popup-missing-reason-validation-helper {
|
||||
display: none;
|
||||
}
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
HOST_SOURCES += [
|
||||
# 'AlphaChecker.cpp',
|
||||
"NonStdMoveChecker.cpp",
|
||||
'TempRefPtrChecker.cpp',
|
||||
"TempRefPtrChecker.cpp",
|
||||
]
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
SOURCES += [
|
||||
# 'AlphaTest.cpp',
|
||||
"TestNonStdMove.cpp",
|
||||
'TestTempRefPtr.cpp',
|
||||
"TestTempRefPtr.cpp",
|
||||
]
|
||||
|
|
|
@ -4,9 +4,10 @@
|
|||
# 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/.
|
||||
|
||||
|
||||
@template
|
||||
def GeckoBinary(linkage='dependent', mozglue=None):
|
||||
'''Template for Gecko-related binaries.
|
||||
def GeckoBinary(linkage="dependent", mozglue=None):
|
||||
"""Template for Gecko-related binaries.
|
||||
|
||||
This template is meant to be used in other templates.
|
||||
|
||||
|
@ -21,104 +22,104 @@ def GeckoBinary(linkage='dependent', mozglue=None):
|
|||
so, what linkage to apply. Valid values are None (mozglue not linked),
|
||||
'program' (mozglue linked to an executable program), or 'library' (mozglue
|
||||
linked to a shared library).
|
||||
'''
|
||||
if linkage == 'dependent':
|
||||
"""
|
||||
if linkage == "dependent":
|
||||
USE_LIBS += [
|
||||
'nspr',
|
||||
'xul-real',
|
||||
"nspr",
|
||||
"xul-real",
|
||||
]
|
||||
elif linkage == 'standalone':
|
||||
DEFINES['XPCOM_GLUE'] = True
|
||||
elif linkage == "standalone":
|
||||
DEFINES["XPCOM_GLUE"] = True
|
||||
|
||||
USE_LIBS += [
|
||||
'xpcomglue',
|
||||
"xpcomglue",
|
||||
]
|
||||
elif linkage != None:
|
||||
error('`linkage` must be "dependent", "standalone" or None')
|
||||
|
||||
if mozglue:
|
||||
if mozglue == 'program':
|
||||
USE_LIBS += ['mozglue']
|
||||
DEFINES['MOZ_HAS_MOZGLUE'] = True
|
||||
if CONFIG['MOZ_GLUE_IN_PROGRAM'] and CONFIG['CC_TYPE'] in ('clang', 'gcc'):
|
||||
LDFLAGS += ['-rdynamic']
|
||||
elif mozglue == 'library':
|
||||
LIBRARY_DEFINES['MOZ_HAS_MOZGLUE'] = True
|
||||
if not CONFIG['MOZ_GLUE_IN_PROGRAM']:
|
||||
USE_LIBS += ['mozglue']
|
||||
if mozglue == "program":
|
||||
USE_LIBS += ["mozglue"]
|
||||
DEFINES["MOZ_HAS_MOZGLUE"] = True
|
||||
if CONFIG["MOZ_GLUE_IN_PROGRAM"] and CONFIG["CC_TYPE"] in ("clang", "gcc"):
|
||||
LDFLAGS += ["-rdynamic"]
|
||||
elif mozglue == "library":
|
||||
LIBRARY_DEFINES["MOZ_HAS_MOZGLUE"] = True
|
||||
if not CONFIG["MOZ_GLUE_IN_PROGRAM"]:
|
||||
USE_LIBS += ["mozglue"]
|
||||
else:
|
||||
error('`mozglue` must be "program" or "library"')
|
||||
|
||||
|
||||
@template
|
||||
def GeckoProgram(name, linkage='standalone', **kwargs):
|
||||
'''Template for program executables related to Gecko.
|
||||
def GeckoProgram(name, linkage="standalone", **kwargs):
|
||||
"""Template for program executables related to Gecko.
|
||||
|
||||
`name` identifies the executable base name.
|
||||
|
||||
See the documentation for `GeckoBinary` for other possible arguments,
|
||||
with the notable difference that the default for `linkage` is 'standalone'.
|
||||
'''
|
||||
"""
|
||||
Program(name)
|
||||
|
||||
kwargs.setdefault('mozglue', 'program')
|
||||
kwargs.setdefault("mozglue", "program")
|
||||
|
||||
GeckoBinary(linkage=linkage, **kwargs)
|
||||
|
||||
|
||||
@template
|
||||
def GeckoSimplePrograms(names, **kwargs):
|
||||
'''Template for simple program executables related to Gecko.
|
||||
"""Template for simple program executables related to Gecko.
|
||||
|
||||
`names` identifies the executable base names for each executable.
|
||||
|
||||
See the documentation for `GeckoBinary` for other possible arguments.
|
||||
'''
|
||||
"""
|
||||
SimplePrograms(names)
|
||||
|
||||
kwargs.setdefault('mozglue', 'program')
|
||||
kwargs.setdefault("mozglue", "program")
|
||||
|
||||
GeckoBinary(**kwargs)
|
||||
|
||||
|
||||
@template
|
||||
def GeckoCppUnitTests(names, **kwargs):
|
||||
'''Template for C++ unit tests related to Gecko.
|
||||
"""Template for C++ unit tests related to Gecko.
|
||||
|
||||
`names` identifies the executable base names for each executable.
|
||||
|
||||
See the documentation for `GeckoBinary` for other possible arguments.
|
||||
'''
|
||||
"""
|
||||
CppUnitTests(names)
|
||||
|
||||
kwargs.setdefault('mozglue', 'program')
|
||||
kwargs.setdefault("mozglue", "program")
|
||||
|
||||
GeckoBinary(**kwargs)
|
||||
|
||||
|
||||
@template
|
||||
def GeckoSharedLibrary(name, output_category=None, **kwargs):
|
||||
'''Template for shared libraries related to Gecko.
|
||||
"""Template for shared libraries related to Gecko.
|
||||
|
||||
`name` identifies the library base name.
|
||||
See the documentation for `GeckoBinary` for other possible arguments.
|
||||
'''
|
||||
"""
|
||||
SharedLibrary(name, output_category)
|
||||
|
||||
kwargs.setdefault('mozglue', 'library')
|
||||
kwargs.setdefault("mozglue", "library")
|
||||
|
||||
GeckoBinary(**kwargs)
|
||||
|
||||
|
||||
@template
|
||||
def GeckoFramework(name, output_category=None, **kwargs):
|
||||
'''Template for OSX frameworks related to Gecko.
|
||||
"""Template for OSX frameworks related to Gecko.
|
||||
|
||||
`name` identifies the library base name.
|
||||
See the documentation for `GeckoBinary` for other possible arguments.
|
||||
'''
|
||||
"""
|
||||
Framework(name, output_category)
|
||||
|
||||
kwargs.setdefault('mozglue', 'library')
|
||||
kwargs.setdefault("mozglue", "library")
|
||||
|
||||
GeckoBinary(**kwargs)
|
||||
|
|
|
@ -4,108 +4,106 @@
|
|||
# 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('gyp_base.mozbuild')
|
||||
include("gyp_base.mozbuild")
|
||||
|
||||
gyp_vars.update({
|
||||
'lsan': 0,
|
||||
'asan': 0,
|
||||
'tsan': 1 if CONFIG['MOZ_TSAN'] else 0,
|
||||
'ubsan' : 0,
|
||||
'fuzzing' : 1 if CONFIG['FUZZING'] else 0,
|
||||
'libfuzzer' : 1 if CONFIG['LIBFUZZER'] else 0,
|
||||
'libfuzzer_fuzzer_no_link_flag' : 1 if CONFIG['HAVE_LIBFUZZER_FLAG_FUZZER_NO_LINK'] else 0,
|
||||
'build_with_mozilla': 1,
|
||||
'build_with_chromium': 0,
|
||||
# 10.9 once we move to TC cross-compiles - bug 1270217
|
||||
'mac_sdk_min': '10.9',
|
||||
'mac_deployment_target': '10.9',
|
||||
'use_official_google_api_keys': 0,
|
||||
'have_clock_monotonic': 1 if CONFIG['HAVE_CLOCK_MONOTONIC'] else 0,
|
||||
'have_ethtool_cmd_speed_hi': 1 if CONFIG['MOZ_WEBRTC_HAVE_ETHTOOL_SPEED_HI'] else 0,
|
||||
'include_alsa_audio': 1 if CONFIG['MOZ_ALSA'] else 0,
|
||||
'include_pulse_audio': 1 if CONFIG['MOZ_PULSEAUDIO'] else 0,
|
||||
# basic stuff for everything
|
||||
'include_internal_video_render': 0,
|
||||
'clang': 1 if CONFIG['CC_TYPE'] == 'clang' else 0,
|
||||
'clang_cl': 1 if CONFIG['CC_TYPE'] == 'clang-cl' else 0,
|
||||
'clang_use_chrome_plugins': 0,
|
||||
'enable_protobuf': 0,
|
||||
'include_tests': 0,
|
||||
'enable_android_opensl': 1,
|
||||
'enable_android_opensl_output': 0,
|
||||
# use_system_lib* still seems to be in use in trunk/build
|
||||
'use_system_libjpeg': 0,
|
||||
'use_system_libvpx': 0,
|
||||
'build_json': 0,
|
||||
'build_libjpeg': 0,
|
||||
'build_libyuv': 0,
|
||||
'build_libvpx': 0,
|
||||
'build_libevent': 0,
|
||||
'build_ssl': 0,
|
||||
'build_json': 0,
|
||||
'build_icu': 0,
|
||||
'build_opus': 0,
|
||||
'libyuv_dir': '/media/libyuv/libyuv',
|
||||
# don't use openssl
|
||||
'use_openssl': 0,
|
||||
# Must match build/gyp.mozbuild WEBRTC_BUILD_LIBEVENT
|
||||
#'enable_libevent': 0, default according to OS
|
||||
gyp_vars.update(
|
||||
{
|
||||
"lsan": 0,
|
||||
"asan": 0,
|
||||
"tsan": 1 if CONFIG["MOZ_TSAN"] else 0,
|
||||
"ubsan": 0,
|
||||
"fuzzing": 1 if CONFIG["FUZZING"] else 0,
|
||||
"libfuzzer": 1 if CONFIG["LIBFUZZER"] else 0,
|
||||
"libfuzzer_fuzzer_no_link_flag": 1
|
||||
if CONFIG["HAVE_LIBFUZZER_FLAG_FUZZER_NO_LINK"]
|
||||
else 0,
|
||||
"build_with_mozilla": 1,
|
||||
"build_with_chromium": 0,
|
||||
# 10.9 once we move to TC cross-compiles - bug 1270217
|
||||
"mac_sdk_min": "10.9",
|
||||
"mac_deployment_target": "10.9",
|
||||
"use_official_google_api_keys": 0,
|
||||
"have_clock_monotonic": 1 if CONFIG["HAVE_CLOCK_MONOTONIC"] else 0,
|
||||
"have_ethtool_cmd_speed_hi": 1
|
||||
if CONFIG["MOZ_WEBRTC_HAVE_ETHTOOL_SPEED_HI"]
|
||||
else 0,
|
||||
"include_alsa_audio": 1 if CONFIG["MOZ_ALSA"] else 0,
|
||||
"include_pulse_audio": 1 if CONFIG["MOZ_PULSEAUDIO"] else 0,
|
||||
# basic stuff for everything
|
||||
"include_internal_video_render": 0,
|
||||
"clang": 1 if CONFIG["CC_TYPE"] == "clang" else 0,
|
||||
"clang_cl": 1 if CONFIG["CC_TYPE"] == "clang-cl" else 0,
|
||||
"clang_use_chrome_plugins": 0,
|
||||
"enable_protobuf": 0,
|
||||
"include_tests": 0,
|
||||
"enable_android_opensl": 1,
|
||||
"enable_android_opensl_output": 0,
|
||||
# use_system_lib* still seems to be in use in trunk/build
|
||||
"use_system_libjpeg": 0,
|
||||
"use_system_libvpx": 0,
|
||||
"build_json": 0,
|
||||
"build_libjpeg": 0,
|
||||
"build_libyuv": 0,
|
||||
"build_libvpx": 0,
|
||||
"build_libevent": 0,
|
||||
"build_ssl": 0,
|
||||
"build_json": 0,
|
||||
"build_icu": 0,
|
||||
"build_opus": 0,
|
||||
"libyuv_dir": "/media/libyuv/libyuv",
|
||||
# don't use openssl
|
||||
"use_openssl": 0,
|
||||
# Must match build/gyp.mozbuild WEBRTC_BUILD_LIBEVENT
|
||||
#'enable_libevent': 0, default according to OS
|
||||
"debug": 1 if CONFIG["DEBUG"] else 0,
|
||||
"use_x11": 1 if CONFIG["MOZ_X11"] else 0,
|
||||
"use_glib": 1 if CONFIG["GLIB_LIBS"] else 0,
|
||||
# bug 1373485 - avoid pkg-config for gtk2 in webrtc
|
||||
"use_gtk": 0,
|
||||
# turn off mandatory use of NEON and instead use NEON detection
|
||||
"arm_neon": 0,
|
||||
"arm_neon_optional": 1,
|
||||
# (for vp8) chromium sets to 0 also
|
||||
"use_temporal_layers": 0,
|
||||
# Creates AEC internal sample dump files in current directory
|
||||
"aec_debug_dump": 1,
|
||||
# codec enable/disables:
|
||||
"include_g711": 1,
|
||||
"include_opus": 1,
|
||||
"include_g722": 1,
|
||||
"include_ilbc": 0,
|
||||
# We turn on ISAC because the AGC uses parts of it, and depend on the
|
||||
# linker to throw away uneeded bits.
|
||||
"include_isac": 1,
|
||||
"include_pcm16b": 1,
|
||||
#'rtc_opus_variable_complexity': 1,
|
||||
"apm_debug_dump": 1,
|
||||
}
|
||||
)
|
||||
|
||||
'debug': 1 if CONFIG['DEBUG'] else 0,
|
||||
if os == "Android":
|
||||
gyp_vars.update(gtest_target_type="executable")
|
||||
|
||||
'use_x11': 1 if CONFIG['MOZ_X11'] else 0,
|
||||
'use_glib': 1 if CONFIG['GLIB_LIBS'] else 0,
|
||||
# bug 1373485 - avoid pkg-config for gtk2 in webrtc
|
||||
'use_gtk': 0,
|
||||
|
||||
# turn off mandatory use of NEON and instead use NEON detection
|
||||
'arm_neon': 0,
|
||||
'arm_neon_optional': 1,
|
||||
|
||||
# (for vp8) chromium sets to 0 also
|
||||
'use_temporal_layers': 0,
|
||||
|
||||
# Creates AEC internal sample dump files in current directory
|
||||
'aec_debug_dump': 1,
|
||||
|
||||
# codec enable/disables:
|
||||
'include_g711': 1,
|
||||
'include_opus': 1,
|
||||
'include_g722': 1,
|
||||
'include_ilbc': 0,
|
||||
# We turn on ISAC because the AGC uses parts of it, and depend on the
|
||||
# linker to throw away uneeded bits.
|
||||
'include_isac': 1,
|
||||
'include_pcm16b': 1,
|
||||
|
||||
#'rtc_opus_variable_complexity': 1,
|
||||
|
||||
'apm_debug_dump': 1,
|
||||
})
|
||||
|
||||
if os == 'Android':
|
||||
gyp_vars.update(gtest_target_type='executable')
|
||||
|
||||
if CONFIG['ARM_ARCH']:
|
||||
if int(CONFIG['ARM_ARCH']) < 7:
|
||||
gyp_vars['armv7'] = 0
|
||||
gyp_vars['arm_neon_optional'] = 0
|
||||
elif os == 'Android':
|
||||
gyp_vars['armv7'] = 1
|
||||
gyp_vars['arm_neon'] = 1
|
||||
gyp_vars['build_with_neon'] = 1
|
||||
if CONFIG["ARM_ARCH"]:
|
||||
if int(CONFIG["ARM_ARCH"]) < 7:
|
||||
gyp_vars["armv7"] = 0
|
||||
gyp_vars["arm_neon_optional"] = 0
|
||||
elif os == "Android":
|
||||
gyp_vars["armv7"] = 1
|
||||
gyp_vars["arm_neon"] = 1
|
||||
gyp_vars["build_with_neon"] = 1
|
||||
else:
|
||||
# CPU detection for ARM works on Android only. armv7 always uses CPU
|
||||
# detection, so we have to set armv7=0 for non-Android target
|
||||
gyp_vars['armv7'] = 0
|
||||
gyp_vars["armv7"] = 0
|
||||
# For libyuv
|
||||
gyp_vars['arm_version'] = int(CONFIG['ARM_ARCH'])
|
||||
gyp_vars["arm_version"] = int(CONFIG["ARM_ARCH"])
|
||||
|
||||
if CONFIG['MACOS_SDK_DIR']:
|
||||
gyp_vars['mac_sdk_path'] = CONFIG['MACOS_SDK_DIR']
|
||||
if CONFIG["MACOS_SDK_DIR"]:
|
||||
gyp_vars["mac_sdk_path"] = CONFIG["MACOS_SDK_DIR"]
|
||||
|
||||
if not CONFIG['MOZ_SYSTEM_LIBVPX']:
|
||||
gyp_vars['libvpx_dir'] = '/media/libvpx/libvpx'
|
||||
if not CONFIG["MOZ_SYSTEM_LIBVPX"]:
|
||||
gyp_vars["libvpx_dir"] = "/media/libvpx/libvpx"
|
||||
|
||||
if not CONFIG['MOZ_SYSTEM_LIBEVENT']:
|
||||
gyp_vars['libevent_dir'] = '/ipc/chromium/src/third_party/libevent'
|
||||
if not CONFIG["MOZ_SYSTEM_LIBEVENT"]:
|
||||
gyp_vars["libevent_dir"] = "/ipc/chromium/src/third_party/libevent"
|
||||
|
|
|
@ -6,34 +6,34 @@
|
|||
|
||||
gyp_vars = {}
|
||||
|
||||
os = CONFIG['OS_TARGET']
|
||||
os = CONFIG["OS_TARGET"]
|
||||
|
||||
if os == 'WINNT':
|
||||
if os == "WINNT":
|
||||
gyp_vars.update(
|
||||
MSVS_VERSION=CONFIG['MSVS_VERSION'],
|
||||
MSVS_OS_BITS=64 if CONFIG['HAVE_64BIT_BUILD'] else 32,
|
||||
MSVS_VERSION=CONFIG["MSVS_VERSION"],
|
||||
MSVS_OS_BITS=64 if CONFIG["HAVE_64BIT_BUILD"] else 32,
|
||||
)
|
||||
|
||||
flavors = {
|
||||
'WINNT': 'win',
|
||||
'Android': 'android',
|
||||
'Linux': 'linux',
|
||||
'Darwin': 'mac' if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa' else 'ios',
|
||||
'SunOS': 'solaris',
|
||||
'GNU/kFreeBSD': 'freebsd',
|
||||
'DragonFly': 'dragonfly',
|
||||
'FreeBSD': 'freebsd',
|
||||
'NetBSD': 'netbsd',
|
||||
'OpenBSD': 'openbsd',
|
||||
"WINNT": "win",
|
||||
"Android": "android",
|
||||
"Linux": "linux",
|
||||
"Darwin": "mac" if CONFIG["MOZ_WIDGET_TOOLKIT"] == "cocoa" else "ios",
|
||||
"SunOS": "solaris",
|
||||
"GNU/kFreeBSD": "freebsd",
|
||||
"DragonFly": "dragonfly",
|
||||
"FreeBSD": "freebsd",
|
||||
"NetBSD": "netbsd",
|
||||
"OpenBSD": "openbsd",
|
||||
}
|
||||
gyp_vars['OS'] = flavors.get(os)
|
||||
gyp_vars["OS"] = flavors.get(os)
|
||||
|
||||
arches = {
|
||||
'x86_64': 'x64',
|
||||
'x86': 'ia32',
|
||||
'aarch64': 'arm64',
|
||||
'ppc64': 'ppc64le' if CONFIG['TARGET_ENDIANNESS'] == 'little' else 'ppc64',
|
||||
"x86_64": "x64",
|
||||
"x86": "ia32",
|
||||
"aarch64": "arm64",
|
||||
"ppc64": "ppc64le" if CONFIG["TARGET_ENDIANNESS"] == "little" else "ppc64",
|
||||
}
|
||||
|
||||
gyp_vars['host_arch'] = arches.get(CONFIG['HOST_CPU_ARCH'], CONFIG['HOST_CPU_ARCH'])
|
||||
gyp_vars['target_arch'] = arches.get(CONFIG['CPU_ARCH'], CONFIG['CPU_ARCH'])
|
||||
gyp_vars["host_arch"] = arches.get(CONFIG["HOST_CPU_ARCH"], CONFIG["HOST_CPU_ARCH"])
|
||||
gyp_vars["target_arch"] = arches.get(CONFIG["CPU_ARCH"], CONFIG["CPU_ARCH"])
|
||||
|
|
|
@ -828,7 +828,8 @@ add_old_configure_assignment("OS_ARCH", target_variables.OS_ARCH)
|
|||
set_config("CPU_ARCH", target.cpu)
|
||||
add_old_configure_assignment("CPU_ARCH", target.cpu)
|
||||
set_config("INTEL_ARCHITECTURE", target_variables.INTEL_ARCHITECTURE)
|
||||
set_config("TARGET_CPU", target.raw_cpu)
|
||||
set_config("TARGET_CPU", target.cpu)
|
||||
set_config("TARGET_RAW_CPU", target.raw_cpu)
|
||||
set_config("TARGET_OS", target.os)
|
||||
set_config("TARGET_RAW_OS", target.raw_os)
|
||||
set_config("TARGET_ENDIANNESS", target.endianness)
|
||||
|
|
|
@ -4,73 +4,80 @@
|
|||
# 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/.
|
||||
|
||||
|
||||
@template
|
||||
def Binary():
|
||||
'''Generic template for target binaries. Meant to be used by other
|
||||
templates.'''
|
||||
"""Generic template for target binaries. Meant to be used by other
|
||||
templates."""
|
||||
|
||||
# Add -llog by default, since we use it all over the place.
|
||||
if CONFIG['OS_TARGET'] == 'Android':
|
||||
OS_LIBS += ['log']
|
||||
if CONFIG["OS_TARGET"] == "Android":
|
||||
OS_LIBS += ["log"]
|
||||
|
||||
|
||||
@template
|
||||
def Program(name):
|
||||
'''Template for program executables.'''
|
||||
"""Template for program executables."""
|
||||
PROGRAM = name
|
||||
|
||||
Binary()
|
||||
|
||||
|
||||
@template
|
||||
def SimplePrograms(names, ext='.cpp'):
|
||||
'''Template for simple program executables.
|
||||
def SimplePrograms(names, ext=".cpp"):
|
||||
"""Template for simple program executables.
|
||||
|
||||
Those have a single source with the same base name as the executable.
|
||||
'''
|
||||
"""
|
||||
SIMPLE_PROGRAMS += names
|
||||
SOURCES += ['%s%s' % (name, ext) for name in names]
|
||||
SOURCES += ["%s%s" % (name, ext) for name in names]
|
||||
|
||||
Binary()
|
||||
|
||||
|
||||
@template
|
||||
def CppUnitTests(names, ext='.cpp'):
|
||||
'''Template for C++ unit tests.
|
||||
def CppUnitTests(names, ext=".cpp"):
|
||||
"""Template for C++ unit tests.
|
||||
|
||||
Those have a single source with the same base name as the executable.
|
||||
'''
|
||||
COMPILE_FLAGS['EXTRA_INCLUDES'] = ['-I%s/dist/include' % TOPOBJDIR,
|
||||
'-I%s/dist/include/testing' % TOPOBJDIR]
|
||||
"""
|
||||
COMPILE_FLAGS["EXTRA_INCLUDES"] = [
|
||||
"-I%s/dist/include" % TOPOBJDIR,
|
||||
"-I%s/dist/include/testing" % TOPOBJDIR,
|
||||
]
|
||||
CPP_UNIT_TESTS += names
|
||||
SOURCES += ['%s%s' % (name, ext) for name in names]
|
||||
SOURCES += ["%s%s" % (name, ext) for name in names]
|
||||
|
||||
Binary()
|
||||
|
||||
|
||||
@template
|
||||
def Library(name):
|
||||
'''Template for libraries.'''
|
||||
"""Template for libraries."""
|
||||
LIBRARY_NAME = name
|
||||
|
||||
|
||||
@template
|
||||
def AllowCompilerWarnings():
|
||||
COMPILE_FLAGS['WARNINGS_AS_ERRORS'] = []
|
||||
WASM_FLAGS['WARNINGS_AS_ERRORS'] = []
|
||||
COMPILE_FLAGS["WARNINGS_AS_ERRORS"] = []
|
||||
WASM_FLAGS["WARNINGS_AS_ERRORS"] = []
|
||||
|
||||
|
||||
@template
|
||||
def DisableCompilerWarnings():
|
||||
# Keep the -Wno-* flags to disable warnings that may be enabled through other means.
|
||||
def filter(flags):
|
||||
return [f for f in flags or [] if f.startswith('-Wno-')]
|
||||
COMPILE_FLAGS['WARNINGS_CFLAGS'] = filter(CONFIG['WARNINGS_CFLAGS'])
|
||||
COMPILE_FLAGS['WARNINGS_CXXFLAGS'] = filter(CONFIG['WARNINGS_CXXFLAGS'])
|
||||
HOST_COMPILE_FLAGS['WARNINGS_CFLAGS'] = filter(CONFIG['WARNINGS_HOST_CFLAGS'])
|
||||
HOST_COMPILE_FLAGS['WARNINGS_CXXFLAGS'] = filter(CONFIG['WARNINGS_HOST_CXXFLAGS'])
|
||||
return [f for f in flags or [] if f.startswith("-Wno-")]
|
||||
|
||||
COMPILE_FLAGS["WARNINGS_CFLAGS"] = filter(CONFIG["WARNINGS_CFLAGS"])
|
||||
COMPILE_FLAGS["WARNINGS_CXXFLAGS"] = filter(CONFIG["WARNINGS_CXXFLAGS"])
|
||||
HOST_COMPILE_FLAGS["WARNINGS_CFLAGS"] = filter(CONFIG["WARNINGS_HOST_CFLAGS"])
|
||||
HOST_COMPILE_FLAGS["WARNINGS_CXXFLAGS"] = filter(CONFIG["WARNINGS_HOST_CXXFLAGS"])
|
||||
|
||||
|
||||
@template
|
||||
def RustLibrary(name, features=None, output_category=None, is_gkrust=False):
|
||||
'''Template for Rust libraries.'''
|
||||
"""Template for Rust libraries."""
|
||||
Library(name)
|
||||
|
||||
IS_RUST_LIBRARY = True
|
||||
|
@ -94,7 +101,7 @@ def RustLibrary(name, features=None, output_category=None, is_gkrust=False):
|
|||
|
||||
@template
|
||||
def SharedLibrary(name, output_category=None):
|
||||
'''Template for shared libraries.'''
|
||||
"""Template for shared libraries."""
|
||||
Library(name)
|
||||
|
||||
FORCE_SHARED_LIB = True
|
||||
|
@ -107,7 +114,7 @@ def SharedLibrary(name, output_category=None):
|
|||
|
||||
@template
|
||||
def Framework(name, output_category=None):
|
||||
'''Template for OSX Frameworks.'''
|
||||
"""Template for OSX Frameworks."""
|
||||
SharedLibrary(name, output_category)
|
||||
|
||||
IS_FRAMEWORK = True
|
||||
|
@ -115,40 +122,43 @@ def Framework(name, output_category=None):
|
|||
|
||||
@template
|
||||
def HostProgram(name):
|
||||
'''Template for build tools executables.'''
|
||||
"""Template for build tools executables."""
|
||||
HOST_PROGRAM = name
|
||||
|
||||
|
||||
@template
|
||||
def HostSimplePrograms(names, ext='.cpp'):
|
||||
'''Template for simple build tools executables.
|
||||
def HostSimplePrograms(names, ext=".cpp"):
|
||||
"""Template for simple build tools executables.
|
||||
|
||||
Those have a single source with the same base name as the executable.
|
||||
'''
|
||||
"""
|
||||
HOST_SIMPLE_PROGRAMS += names
|
||||
HOST_SOURCES += ['%s%s' % (name.replace('host_', ''), ext)
|
||||
for name in names]
|
||||
HOST_SOURCES += ["%s%s" % (name.replace("host_", ""), ext) for name in names]
|
||||
|
||||
|
||||
@template
|
||||
def HostSharedLibrary(name):
|
||||
'''Template for build tools libraries.'''
|
||||
if name != 'clang-plugin':
|
||||
error('Please make sure host shared library support is complete '
|
||||
'before using for something else than the clang plugin')
|
||||
"""Template for build tools libraries."""
|
||||
if name != "clang-plugin":
|
||||
error(
|
||||
"Please make sure host shared library support is complete "
|
||||
"before using for something else than the clang plugin"
|
||||
)
|
||||
|
||||
HOST_LIBRARY_NAME = name
|
||||
|
||||
FORCE_SHARED_LIB = True
|
||||
|
||||
|
||||
@template
|
||||
def HostLibrary(name):
|
||||
'''Template for build tools libraries.'''
|
||||
"""Template for build tools libraries."""
|
||||
HOST_LIBRARY_NAME = name
|
||||
|
||||
|
||||
@template
|
||||
def HostRustLibrary(name, features=None):
|
||||
'''Template for host Rust libraries.'''
|
||||
"""Template for host Rust libraries."""
|
||||
HostLibrary(name)
|
||||
|
||||
IS_RUST_LIBRARY = True
|
||||
|
@ -158,44 +168,49 @@ def HostRustLibrary(name, features=None):
|
|||
if features:
|
||||
HOST_RUST_LIBRARY_FEATURES = features
|
||||
|
||||
|
||||
@template
|
||||
def DisableStlWrapping():
|
||||
COMPILE_FLAGS['STL'] = []
|
||||
COMPILE_FLAGS["STL"] = []
|
||||
|
||||
|
||||
@template
|
||||
def NoVisibilityFlags():
|
||||
COMPILE_FLAGS['VISIBILITY'] = []
|
||||
COMPILE_FLAGS["VISIBILITY"] = []
|
||||
|
||||
|
||||
@template
|
||||
def ForceInclude(*headers):
|
||||
"""Force includes a set of header files in C++ compilations"""
|
||||
if CONFIG['CC_TYPE'] == 'clang-cl':
|
||||
include_flag = '-FI'
|
||||
if CONFIG["CC_TYPE"] == "clang-cl":
|
||||
include_flag = "-FI"
|
||||
else:
|
||||
include_flag = '-include'
|
||||
include_flag = "-include"
|
||||
for header in headers:
|
||||
CXXFLAGS += [include_flag, header]
|
||||
|
||||
|
||||
@template
|
||||
def GeneratedFile(name, *names, **kwargs):
|
||||
"""Add one or more GENERATED_FILES with the given attributes.
|
||||
|
||||
You must pass in at least one generated file (the "name" argument). Other
|
||||
names can be included as positional arguments after "name"."""
|
||||
script = kwargs.pop('script', None)
|
||||
entry_point = kwargs.pop('entry_point', None)
|
||||
inputs = kwargs.pop('inputs', [])
|
||||
flags = kwargs.pop('flags', [])
|
||||
force = kwargs.pop('force', False)
|
||||
script = kwargs.pop("script", None)
|
||||
entry_point = kwargs.pop("entry_point", None)
|
||||
inputs = kwargs.pop("inputs", [])
|
||||
flags = kwargs.pop("flags", [])
|
||||
force = kwargs.pop("force", False)
|
||||
if kwargs:
|
||||
error('Unrecognized argument(s) to GeneratedFile: %s' %
|
||||
', '.join(kwargs))
|
||||
error("Unrecognized argument(s) to GeneratedFile: %s" % ", ".join(kwargs))
|
||||
if entry_point and not script:
|
||||
error('entry_point cannot be provided if script is not provided')
|
||||
if script and ':' in script:
|
||||
error('script should not include a `:`. If you want to provide an '
|
||||
'alternative entry point for your script, use the entry_point '
|
||||
'parameter.')
|
||||
error("entry_point cannot be provided if script is not provided")
|
||||
if script and ":" in script:
|
||||
error(
|
||||
"script should not include a `:`. If you want to provide an "
|
||||
"alternative entry point for your script, use the entry_point "
|
||||
"parameter."
|
||||
)
|
||||
|
||||
key = (name,) + names if names else name
|
||||
GENERATED_FILES += [key]
|
||||
|
@ -203,18 +218,20 @@ def GeneratedFile(name, *names, **kwargs):
|
|||
if script and not entry_point:
|
||||
generated_file.script = script
|
||||
if script and entry_point:
|
||||
generated_file.script = script + ':' + entry_point
|
||||
generated_file.script = script + ":" + entry_point
|
||||
generated_file.inputs = inputs
|
||||
generated_file.flags = flags
|
||||
generated_file.force = force
|
||||
|
||||
|
||||
@template
|
||||
def CbindgenHeader(name, inputs):
|
||||
"""Add one GENERATED_FILES by running RunCbindgen.py"""
|
||||
|
||||
inputs = ['!/config/cbindgen-metadata.json'] + inputs
|
||||
GeneratedFile(name, script='/build/RunCbindgen.py',
|
||||
entry_point='generate', inputs=inputs)
|
||||
inputs = ["!/config/cbindgen-metadata.json"] + inputs
|
||||
GeneratedFile(
|
||||
name, script="/build/RunCbindgen.py", entry_point="generate", inputs=inputs
|
||||
)
|
||||
|
||||
|
||||
include('gecko_templates.mozbuild')
|
||||
include("gecko_templates.mozbuild")
|
||||
|
|
|
@ -100,17 +100,15 @@ static inline __attribute__((always_inline)) void do_relocations(
|
|||
ptr = (Elf_Addr*)((intptr_t)&__ehdr_start + *entry);
|
||||
*ptr += (intptr_t)&__ehdr_start;
|
||||
} else {
|
||||
size_t remaining = (8 * sizeof(Elf_Addr) - 1);
|
||||
Elf_Addr bits = *entry;
|
||||
Elf_Addr* end = ptr + 8 * sizeof(Elf_Addr) - 1;
|
||||
do {
|
||||
bits >>= 1;
|
||||
remaining--;
|
||||
ptr++;
|
||||
bits >>= 1;
|
||||
if (bits & 1) {
|
||||
*ptr += (intptr_t)&__ehdr_start;
|
||||
}
|
||||
} while (bits);
|
||||
ptr += remaining;
|
||||
} while (ptr < end);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
596
config/external/icu/common/sources.mozbuild
vendored
596
config/external/icu/common/sources.mozbuild
vendored
|
@ -1,305 +1,305 @@
|
|||
# THIS FILE IS GENERATED BY /intl/icu_sources_data.py DO NOT EDIT
|
||||
sources = [
|
||||
'/intl/icu/source/common/appendable.cpp',
|
||||
'/intl/icu/source/common/bmpset.cpp',
|
||||
'/intl/icu/source/common/brkeng.cpp',
|
||||
'/intl/icu/source/common/brkiter.cpp',
|
||||
'/intl/icu/source/common/bytesinkutil.cpp',
|
||||
'/intl/icu/source/common/bytestream.cpp',
|
||||
'/intl/icu/source/common/bytestrie.cpp',
|
||||
'/intl/icu/source/common/bytestriebuilder.cpp',
|
||||
'/intl/icu/source/common/caniter.cpp',
|
||||
'/intl/icu/source/common/characterproperties.cpp',
|
||||
'/intl/icu/source/common/chariter.cpp',
|
||||
'/intl/icu/source/common/charstr.cpp',
|
||||
'/intl/icu/source/common/cmemory.cpp',
|
||||
'/intl/icu/source/common/cstring.cpp',
|
||||
'/intl/icu/source/common/dictbe.cpp',
|
||||
'/intl/icu/source/common/dictionarydata.cpp',
|
||||
'/intl/icu/source/common/dtintrv.cpp',
|
||||
'/intl/icu/source/common/edits.cpp',
|
||||
'/intl/icu/source/common/emojiprops.cpp',
|
||||
'/intl/icu/source/common/errorcode.cpp',
|
||||
'/intl/icu/source/common/filteredbrk.cpp',
|
||||
'/intl/icu/source/common/filterednormalizer2.cpp',
|
||||
'/intl/icu/source/common/loadednormalizer2impl.cpp',
|
||||
'/intl/icu/source/common/localebuilder.cpp',
|
||||
'/intl/icu/source/common/localematcher.cpp',
|
||||
'/intl/icu/source/common/localeprioritylist.cpp',
|
||||
'/intl/icu/source/common/locavailable.cpp',
|
||||
'/intl/icu/source/common/locbased.cpp',
|
||||
'/intl/icu/source/common/locdispnames.cpp',
|
||||
'/intl/icu/source/common/locdistance.cpp',
|
||||
'/intl/icu/source/common/locdspnm.cpp',
|
||||
'/intl/icu/source/common/locid.cpp',
|
||||
'/intl/icu/source/common/loclikely.cpp',
|
||||
'/intl/icu/source/common/loclikelysubtags.cpp',
|
||||
'/intl/icu/source/common/locmap.cpp',
|
||||
'/intl/icu/source/common/locresdata.cpp',
|
||||
'/intl/icu/source/common/locutil.cpp',
|
||||
'/intl/icu/source/common/lsr.cpp',
|
||||
'/intl/icu/source/common/lstmbe.cpp',
|
||||
'/intl/icu/source/common/messagepattern.cpp',
|
||||
'/intl/icu/source/common/mlbe.cpp',
|
||||
'/intl/icu/source/common/normalizer2.cpp',
|
||||
'/intl/icu/source/common/normalizer2impl.cpp',
|
||||
'/intl/icu/source/common/normlzr.cpp',
|
||||
'/intl/icu/source/common/parsepos.cpp',
|
||||
'/intl/icu/source/common/patternprops.cpp',
|
||||
'/intl/icu/source/common/propname.cpp',
|
||||
'/intl/icu/source/common/punycode.cpp',
|
||||
'/intl/icu/source/common/putil.cpp',
|
||||
'/intl/icu/source/common/rbbi.cpp',
|
||||
'/intl/icu/source/common/rbbi_cache.cpp',
|
||||
'/intl/icu/source/common/rbbidata.cpp',
|
||||
'/intl/icu/source/common/rbbinode.cpp',
|
||||
'/intl/icu/source/common/rbbirb.cpp',
|
||||
'/intl/icu/source/common/rbbiscan.cpp',
|
||||
'/intl/icu/source/common/rbbisetb.cpp',
|
||||
'/intl/icu/source/common/rbbistbl.cpp',
|
||||
'/intl/icu/source/common/rbbitblb.cpp',
|
||||
'/intl/icu/source/common/resbund.cpp',
|
||||
'/intl/icu/source/common/resource.cpp',
|
||||
'/intl/icu/source/common/restrace.cpp',
|
||||
'/intl/icu/source/common/ruleiter.cpp',
|
||||
'/intl/icu/source/common/schriter.cpp',
|
||||
'/intl/icu/source/common/serv.cpp',
|
||||
'/intl/icu/source/common/servlk.cpp',
|
||||
'/intl/icu/source/common/servlkf.cpp',
|
||||
'/intl/icu/source/common/servls.cpp',
|
||||
'/intl/icu/source/common/servnotf.cpp',
|
||||
'/intl/icu/source/common/servrbf.cpp',
|
||||
'/intl/icu/source/common/servslkf.cpp',
|
||||
'/intl/icu/source/common/sharedobject.cpp',
|
||||
'/intl/icu/source/common/simpleformatter.cpp',
|
||||
'/intl/icu/source/common/static_unicode_sets.cpp',
|
||||
'/intl/icu/source/common/stringpiece.cpp',
|
||||
'/intl/icu/source/common/stringtriebuilder.cpp',
|
||||
'/intl/icu/source/common/uarrsort.cpp',
|
||||
'/intl/icu/source/common/ubidi.cpp',
|
||||
'/intl/icu/source/common/ubidi_props.cpp',
|
||||
'/intl/icu/source/common/ubidiln.cpp',
|
||||
'/intl/icu/source/common/ubidiwrt.cpp',
|
||||
'/intl/icu/source/common/ubrk.cpp',
|
||||
'/intl/icu/source/common/ucase.cpp',
|
||||
'/intl/icu/source/common/ucasemap.cpp',
|
||||
'/intl/icu/source/common/ucasemap_titlecase_brkiter.cpp',
|
||||
'/intl/icu/source/common/uchar.cpp',
|
||||
'/intl/icu/source/common/ucharstrie.cpp',
|
||||
'/intl/icu/source/common/ucharstriebuilder.cpp',
|
||||
'/intl/icu/source/common/ucharstrieiterator.cpp',
|
||||
'/intl/icu/source/common/uchriter.cpp',
|
||||
'/intl/icu/source/common/ucln_cmn.cpp',
|
||||
'/intl/icu/source/common/ucmndata.cpp',
|
||||
'/intl/icu/source/common/ucnv.cpp',
|
||||
'/intl/icu/source/common/ucnv_bld.cpp',
|
||||
'/intl/icu/source/common/ucnv_cb.cpp',
|
||||
'/intl/icu/source/common/ucnv_cnv.cpp',
|
||||
'/intl/icu/source/common/ucnv_err.cpp',
|
||||
'/intl/icu/source/common/ucnv_io.cpp',
|
||||
'/intl/icu/source/common/ucnv_u16.cpp',
|
||||
'/intl/icu/source/common/ucnv_u32.cpp',
|
||||
'/intl/icu/source/common/ucnv_u7.cpp',
|
||||
'/intl/icu/source/common/ucnv_u8.cpp',
|
||||
'/intl/icu/source/common/ucnvbocu.cpp',
|
||||
'/intl/icu/source/common/ucnvlat1.cpp',
|
||||
'/intl/icu/source/common/ucnvscsu.cpp',
|
||||
'/intl/icu/source/common/ucol_swp.cpp',
|
||||
'/intl/icu/source/common/ucptrie.cpp',
|
||||
'/intl/icu/source/common/ucurr.cpp',
|
||||
'/intl/icu/source/common/udata.cpp',
|
||||
'/intl/icu/source/common/udatamem.cpp',
|
||||
'/intl/icu/source/common/udataswp.cpp',
|
||||
'/intl/icu/source/common/uenum.cpp',
|
||||
'/intl/icu/source/common/uhash.cpp',
|
||||
'/intl/icu/source/common/uhash_us.cpp',
|
||||
'/intl/icu/source/common/uinit.cpp',
|
||||
'/intl/icu/source/common/uinvchar.cpp',
|
||||
'/intl/icu/source/common/uiter.cpp',
|
||||
'/intl/icu/source/common/ulist.cpp',
|
||||
'/intl/icu/source/common/uloc.cpp',
|
||||
'/intl/icu/source/common/uloc_keytype.cpp',
|
||||
'/intl/icu/source/common/uloc_tag.cpp',
|
||||
'/intl/icu/source/common/umapfile.cpp',
|
||||
'/intl/icu/source/common/umath.cpp',
|
||||
'/intl/icu/source/common/umutablecptrie.cpp',
|
||||
'/intl/icu/source/common/umutex.cpp',
|
||||
'/intl/icu/source/common/unames.cpp',
|
||||
'/intl/icu/source/common/unifiedcache.cpp',
|
||||
'/intl/icu/source/common/unifilt.cpp',
|
||||
'/intl/icu/source/common/unifunct.cpp',
|
||||
'/intl/icu/source/common/uniset.cpp',
|
||||
'/intl/icu/source/common/uniset_closure.cpp',
|
||||
'/intl/icu/source/common/uniset_props.cpp',
|
||||
'/intl/icu/source/common/unisetspan.cpp',
|
||||
'/intl/icu/source/common/unistr.cpp',
|
||||
'/intl/icu/source/common/unistr_case.cpp',
|
||||
'/intl/icu/source/common/unistr_case_locale.cpp',
|
||||
'/intl/icu/source/common/unistr_cnv.cpp',
|
||||
'/intl/icu/source/common/unistr_props.cpp',
|
||||
'/intl/icu/source/common/unistr_titlecase_brkiter.cpp',
|
||||
'/intl/icu/source/common/unormcmp.cpp',
|
||||
'/intl/icu/source/common/uobject.cpp',
|
||||
'/intl/icu/source/common/uprops.cpp',
|
||||
'/intl/icu/source/common/uresbund.cpp',
|
||||
'/intl/icu/source/common/uresdata.cpp',
|
||||
'/intl/icu/source/common/uscript.cpp',
|
||||
'/intl/icu/source/common/uscript_props.cpp',
|
||||
'/intl/icu/source/common/uset.cpp',
|
||||
'/intl/icu/source/common/uset_props.cpp',
|
||||
'/intl/icu/source/common/usetiter.cpp',
|
||||
'/intl/icu/source/common/usprep.cpp',
|
||||
'/intl/icu/source/common/ustack.cpp',
|
||||
'/intl/icu/source/common/ustr_cnv.cpp',
|
||||
'/intl/icu/source/common/ustr_titlecase_brkiter.cpp',
|
||||
'/intl/icu/source/common/ustrcase.cpp',
|
||||
'/intl/icu/source/common/ustrcase_locale.cpp',
|
||||
'/intl/icu/source/common/ustrenum.cpp',
|
||||
'/intl/icu/source/common/ustrfmt.cpp',
|
||||
'/intl/icu/source/common/ustring.cpp',
|
||||
'/intl/icu/source/common/ustrtrns.cpp',
|
||||
'/intl/icu/source/common/utext.cpp',
|
||||
'/intl/icu/source/common/utf_impl.cpp',
|
||||
'/intl/icu/source/common/util.cpp',
|
||||
'/intl/icu/source/common/utrace.cpp',
|
||||
'/intl/icu/source/common/utrie.cpp',
|
||||
'/intl/icu/source/common/utrie2.cpp',
|
||||
'/intl/icu/source/common/utrie2_builder.cpp',
|
||||
'/intl/icu/source/common/utrie_swap.cpp',
|
||||
'/intl/icu/source/common/uts46.cpp',
|
||||
'/intl/icu/source/common/utypes.cpp',
|
||||
'/intl/icu/source/common/uvector.cpp',
|
||||
'/intl/icu/source/common/uvectr32.cpp',
|
||||
'/intl/icu/source/common/uvectr64.cpp',
|
||||
'/intl/icu/source/common/wintz.cpp',
|
||||
"/intl/icu/source/common/appendable.cpp",
|
||||
"/intl/icu/source/common/bmpset.cpp",
|
||||
"/intl/icu/source/common/brkeng.cpp",
|
||||
"/intl/icu/source/common/brkiter.cpp",
|
||||
"/intl/icu/source/common/bytesinkutil.cpp",
|
||||
"/intl/icu/source/common/bytestream.cpp",
|
||||
"/intl/icu/source/common/bytestrie.cpp",
|
||||
"/intl/icu/source/common/bytestriebuilder.cpp",
|
||||
"/intl/icu/source/common/caniter.cpp",
|
||||
"/intl/icu/source/common/characterproperties.cpp",
|
||||
"/intl/icu/source/common/chariter.cpp",
|
||||
"/intl/icu/source/common/charstr.cpp",
|
||||
"/intl/icu/source/common/cmemory.cpp",
|
||||
"/intl/icu/source/common/cstring.cpp",
|
||||
"/intl/icu/source/common/dictbe.cpp",
|
||||
"/intl/icu/source/common/dictionarydata.cpp",
|
||||
"/intl/icu/source/common/dtintrv.cpp",
|
||||
"/intl/icu/source/common/edits.cpp",
|
||||
"/intl/icu/source/common/emojiprops.cpp",
|
||||
"/intl/icu/source/common/errorcode.cpp",
|
||||
"/intl/icu/source/common/filteredbrk.cpp",
|
||||
"/intl/icu/source/common/filterednormalizer2.cpp",
|
||||
"/intl/icu/source/common/loadednormalizer2impl.cpp",
|
||||
"/intl/icu/source/common/localebuilder.cpp",
|
||||
"/intl/icu/source/common/localematcher.cpp",
|
||||
"/intl/icu/source/common/localeprioritylist.cpp",
|
||||
"/intl/icu/source/common/locavailable.cpp",
|
||||
"/intl/icu/source/common/locbased.cpp",
|
||||
"/intl/icu/source/common/locdispnames.cpp",
|
||||
"/intl/icu/source/common/locdistance.cpp",
|
||||
"/intl/icu/source/common/locdspnm.cpp",
|
||||
"/intl/icu/source/common/locid.cpp",
|
||||
"/intl/icu/source/common/loclikely.cpp",
|
||||
"/intl/icu/source/common/loclikelysubtags.cpp",
|
||||
"/intl/icu/source/common/locmap.cpp",
|
||||
"/intl/icu/source/common/locresdata.cpp",
|
||||
"/intl/icu/source/common/locutil.cpp",
|
||||
"/intl/icu/source/common/lsr.cpp",
|
||||
"/intl/icu/source/common/lstmbe.cpp",
|
||||
"/intl/icu/source/common/messagepattern.cpp",
|
||||
"/intl/icu/source/common/mlbe.cpp",
|
||||
"/intl/icu/source/common/normalizer2.cpp",
|
||||
"/intl/icu/source/common/normalizer2impl.cpp",
|
||||
"/intl/icu/source/common/normlzr.cpp",
|
||||
"/intl/icu/source/common/parsepos.cpp",
|
||||
"/intl/icu/source/common/patternprops.cpp",
|
||||
"/intl/icu/source/common/propname.cpp",
|
||||
"/intl/icu/source/common/punycode.cpp",
|
||||
"/intl/icu/source/common/putil.cpp",
|
||||
"/intl/icu/source/common/rbbi.cpp",
|
||||
"/intl/icu/source/common/rbbi_cache.cpp",
|
||||
"/intl/icu/source/common/rbbidata.cpp",
|
||||
"/intl/icu/source/common/rbbinode.cpp",
|
||||
"/intl/icu/source/common/rbbirb.cpp",
|
||||
"/intl/icu/source/common/rbbiscan.cpp",
|
||||
"/intl/icu/source/common/rbbisetb.cpp",
|
||||
"/intl/icu/source/common/rbbistbl.cpp",
|
||||
"/intl/icu/source/common/rbbitblb.cpp",
|
||||
"/intl/icu/source/common/resbund.cpp",
|
||||
"/intl/icu/source/common/resource.cpp",
|
||||
"/intl/icu/source/common/restrace.cpp",
|
||||
"/intl/icu/source/common/ruleiter.cpp",
|
||||
"/intl/icu/source/common/schriter.cpp",
|
||||
"/intl/icu/source/common/serv.cpp",
|
||||
"/intl/icu/source/common/servlk.cpp",
|
||||
"/intl/icu/source/common/servlkf.cpp",
|
||||
"/intl/icu/source/common/servls.cpp",
|
||||
"/intl/icu/source/common/servnotf.cpp",
|
||||
"/intl/icu/source/common/servrbf.cpp",
|
||||
"/intl/icu/source/common/servslkf.cpp",
|
||||
"/intl/icu/source/common/sharedobject.cpp",
|
||||
"/intl/icu/source/common/simpleformatter.cpp",
|
||||
"/intl/icu/source/common/static_unicode_sets.cpp",
|
||||
"/intl/icu/source/common/stringpiece.cpp",
|
||||
"/intl/icu/source/common/stringtriebuilder.cpp",
|
||||
"/intl/icu/source/common/uarrsort.cpp",
|
||||
"/intl/icu/source/common/ubidi.cpp",
|
||||
"/intl/icu/source/common/ubidi_props.cpp",
|
||||
"/intl/icu/source/common/ubidiln.cpp",
|
||||
"/intl/icu/source/common/ubidiwrt.cpp",
|
||||
"/intl/icu/source/common/ubrk.cpp",
|
||||
"/intl/icu/source/common/ucase.cpp",
|
||||
"/intl/icu/source/common/ucasemap.cpp",
|
||||
"/intl/icu/source/common/ucasemap_titlecase_brkiter.cpp",
|
||||
"/intl/icu/source/common/uchar.cpp",
|
||||
"/intl/icu/source/common/ucharstrie.cpp",
|
||||
"/intl/icu/source/common/ucharstriebuilder.cpp",
|
||||
"/intl/icu/source/common/ucharstrieiterator.cpp",
|
||||
"/intl/icu/source/common/uchriter.cpp",
|
||||
"/intl/icu/source/common/ucln_cmn.cpp",
|
||||
"/intl/icu/source/common/ucmndata.cpp",
|
||||
"/intl/icu/source/common/ucnv.cpp",
|
||||
"/intl/icu/source/common/ucnv_bld.cpp",
|
||||
"/intl/icu/source/common/ucnv_cb.cpp",
|
||||
"/intl/icu/source/common/ucnv_cnv.cpp",
|
||||
"/intl/icu/source/common/ucnv_err.cpp",
|
||||
"/intl/icu/source/common/ucnv_io.cpp",
|
||||
"/intl/icu/source/common/ucnv_u16.cpp",
|
||||
"/intl/icu/source/common/ucnv_u32.cpp",
|
||||
"/intl/icu/source/common/ucnv_u7.cpp",
|
||||
"/intl/icu/source/common/ucnv_u8.cpp",
|
||||
"/intl/icu/source/common/ucnvbocu.cpp",
|
||||
"/intl/icu/source/common/ucnvlat1.cpp",
|
||||
"/intl/icu/source/common/ucnvscsu.cpp",
|
||||
"/intl/icu/source/common/ucol_swp.cpp",
|
||||
"/intl/icu/source/common/ucptrie.cpp",
|
||||
"/intl/icu/source/common/ucurr.cpp",
|
||||
"/intl/icu/source/common/udata.cpp",
|
||||
"/intl/icu/source/common/udatamem.cpp",
|
||||
"/intl/icu/source/common/udataswp.cpp",
|
||||
"/intl/icu/source/common/uenum.cpp",
|
||||
"/intl/icu/source/common/uhash.cpp",
|
||||
"/intl/icu/source/common/uhash_us.cpp",
|
||||
"/intl/icu/source/common/uinit.cpp",
|
||||
"/intl/icu/source/common/uinvchar.cpp",
|
||||
"/intl/icu/source/common/uiter.cpp",
|
||||
"/intl/icu/source/common/ulist.cpp",
|
||||
"/intl/icu/source/common/uloc.cpp",
|
||||
"/intl/icu/source/common/uloc_keytype.cpp",
|
||||
"/intl/icu/source/common/uloc_tag.cpp",
|
||||
"/intl/icu/source/common/umapfile.cpp",
|
||||
"/intl/icu/source/common/umath.cpp",
|
||||
"/intl/icu/source/common/umutablecptrie.cpp",
|
||||
"/intl/icu/source/common/umutex.cpp",
|
||||
"/intl/icu/source/common/unames.cpp",
|
||||
"/intl/icu/source/common/unifiedcache.cpp",
|
||||
"/intl/icu/source/common/unifilt.cpp",
|
||||
"/intl/icu/source/common/unifunct.cpp",
|
||||
"/intl/icu/source/common/uniset.cpp",
|
||||
"/intl/icu/source/common/uniset_closure.cpp",
|
||||
"/intl/icu/source/common/uniset_props.cpp",
|
||||
"/intl/icu/source/common/unisetspan.cpp",
|
||||
"/intl/icu/source/common/unistr.cpp",
|
||||
"/intl/icu/source/common/unistr_case.cpp",
|
||||
"/intl/icu/source/common/unistr_case_locale.cpp",
|
||||
"/intl/icu/source/common/unistr_cnv.cpp",
|
||||
"/intl/icu/source/common/unistr_props.cpp",
|
||||
"/intl/icu/source/common/unistr_titlecase_brkiter.cpp",
|
||||
"/intl/icu/source/common/unormcmp.cpp",
|
||||
"/intl/icu/source/common/uobject.cpp",
|
||||
"/intl/icu/source/common/uprops.cpp",
|
||||
"/intl/icu/source/common/uresbund.cpp",
|
||||
"/intl/icu/source/common/uresdata.cpp",
|
||||
"/intl/icu/source/common/uscript.cpp",
|
||||
"/intl/icu/source/common/uscript_props.cpp",
|
||||
"/intl/icu/source/common/uset.cpp",
|
||||
"/intl/icu/source/common/uset_props.cpp",
|
||||
"/intl/icu/source/common/usetiter.cpp",
|
||||
"/intl/icu/source/common/usprep.cpp",
|
||||
"/intl/icu/source/common/ustack.cpp",
|
||||
"/intl/icu/source/common/ustr_cnv.cpp",
|
||||
"/intl/icu/source/common/ustr_titlecase_brkiter.cpp",
|
||||
"/intl/icu/source/common/ustrcase.cpp",
|
||||
"/intl/icu/source/common/ustrcase_locale.cpp",
|
||||
"/intl/icu/source/common/ustrenum.cpp",
|
||||
"/intl/icu/source/common/ustrfmt.cpp",
|
||||
"/intl/icu/source/common/ustring.cpp",
|
||||
"/intl/icu/source/common/ustrtrns.cpp",
|
||||
"/intl/icu/source/common/utext.cpp",
|
||||
"/intl/icu/source/common/utf_impl.cpp",
|
||||
"/intl/icu/source/common/util.cpp",
|
||||
"/intl/icu/source/common/utrace.cpp",
|
||||
"/intl/icu/source/common/utrie.cpp",
|
||||
"/intl/icu/source/common/utrie2.cpp",
|
||||
"/intl/icu/source/common/utrie2_builder.cpp",
|
||||
"/intl/icu/source/common/utrie_swap.cpp",
|
||||
"/intl/icu/source/common/uts46.cpp",
|
||||
"/intl/icu/source/common/utypes.cpp",
|
||||
"/intl/icu/source/common/uvector.cpp",
|
||||
"/intl/icu/source/common/uvectr32.cpp",
|
||||
"/intl/icu/source/common/uvectr64.cpp",
|
||||
"/intl/icu/source/common/wintz.cpp",
|
||||
]
|
||||
other_sources = [
|
||||
'/intl/icu/source/common/bytestrieiterator.cpp',
|
||||
'/intl/icu/source/common/cstr.cpp',
|
||||
'/intl/icu/source/common/cwchar.cpp',
|
||||
'/intl/icu/source/common/icudataver.cpp',
|
||||
'/intl/icu/source/common/icuplug.cpp',
|
||||
'/intl/icu/source/common/pluralmap.cpp',
|
||||
'/intl/icu/source/common/propsvec.cpp',
|
||||
'/intl/icu/source/common/resbund_cnv.cpp',
|
||||
'/intl/icu/source/common/ubiditransform.cpp',
|
||||
'/intl/icu/source/common/ucat.cpp',
|
||||
'/intl/icu/source/common/ucnv2022.cpp',
|
||||
'/intl/icu/source/common/ucnv_ct.cpp',
|
||||
'/intl/icu/source/common/ucnv_ext.cpp',
|
||||
'/intl/icu/source/common/ucnv_lmb.cpp',
|
||||
'/intl/icu/source/common/ucnv_set.cpp',
|
||||
'/intl/icu/source/common/ucnvdisp.cpp',
|
||||
'/intl/icu/source/common/ucnvhz.cpp',
|
||||
'/intl/icu/source/common/ucnvisci.cpp',
|
||||
'/intl/icu/source/common/ucnvmbcs.cpp',
|
||||
'/intl/icu/source/common/ucnvsel.cpp',
|
||||
'/intl/icu/source/common/uidna.cpp',
|
||||
'/intl/icu/source/common/unorm.cpp',
|
||||
'/intl/icu/source/common/ures_cnv.cpp',
|
||||
'/intl/icu/source/common/usc_impl.cpp',
|
||||
'/intl/icu/source/common/ushape.cpp',
|
||||
'/intl/icu/source/common/ustr_wcs.cpp',
|
||||
'/intl/icu/source/common/util_props.cpp',
|
||||
"/intl/icu/source/common/bytestrieiterator.cpp",
|
||||
"/intl/icu/source/common/cstr.cpp",
|
||||
"/intl/icu/source/common/cwchar.cpp",
|
||||
"/intl/icu/source/common/icudataver.cpp",
|
||||
"/intl/icu/source/common/icuplug.cpp",
|
||||
"/intl/icu/source/common/pluralmap.cpp",
|
||||
"/intl/icu/source/common/propsvec.cpp",
|
||||
"/intl/icu/source/common/resbund_cnv.cpp",
|
||||
"/intl/icu/source/common/ubiditransform.cpp",
|
||||
"/intl/icu/source/common/ucat.cpp",
|
||||
"/intl/icu/source/common/ucnv2022.cpp",
|
||||
"/intl/icu/source/common/ucnv_ct.cpp",
|
||||
"/intl/icu/source/common/ucnv_ext.cpp",
|
||||
"/intl/icu/source/common/ucnv_lmb.cpp",
|
||||
"/intl/icu/source/common/ucnv_set.cpp",
|
||||
"/intl/icu/source/common/ucnvdisp.cpp",
|
||||
"/intl/icu/source/common/ucnvhz.cpp",
|
||||
"/intl/icu/source/common/ucnvisci.cpp",
|
||||
"/intl/icu/source/common/ucnvmbcs.cpp",
|
||||
"/intl/icu/source/common/ucnvsel.cpp",
|
||||
"/intl/icu/source/common/uidna.cpp",
|
||||
"/intl/icu/source/common/unorm.cpp",
|
||||
"/intl/icu/source/common/ures_cnv.cpp",
|
||||
"/intl/icu/source/common/usc_impl.cpp",
|
||||
"/intl/icu/source/common/ushape.cpp",
|
||||
"/intl/icu/source/common/ustr_wcs.cpp",
|
||||
"/intl/icu/source/common/util_props.cpp",
|
||||
]
|
||||
EXPORTS.unicode += [
|
||||
'/intl/icu/source/common/unicode/appendable.h',
|
||||
'/intl/icu/source/common/unicode/brkiter.h',
|
||||
'/intl/icu/source/common/unicode/bytestream.h',
|
||||
'/intl/icu/source/common/unicode/bytestrie.h',
|
||||
'/intl/icu/source/common/unicode/bytestriebuilder.h',
|
||||
'/intl/icu/source/common/unicode/caniter.h',
|
||||
'/intl/icu/source/common/unicode/casemap.h',
|
||||
'/intl/icu/source/common/unicode/char16ptr.h',
|
||||
'/intl/icu/source/common/unicode/chariter.h',
|
||||
'/intl/icu/source/common/unicode/dbbi.h',
|
||||
'/intl/icu/source/common/unicode/docmain.h',
|
||||
'/intl/icu/source/common/unicode/dtintrv.h',
|
||||
'/intl/icu/source/common/unicode/edits.h',
|
||||
'/intl/icu/source/common/unicode/enumset.h',
|
||||
'/intl/icu/source/common/unicode/errorcode.h',
|
||||
'/intl/icu/source/common/unicode/filteredbrk.h',
|
||||
'/intl/icu/source/common/unicode/icudataver.h',
|
||||
'/intl/icu/source/common/unicode/icuplug.h',
|
||||
'/intl/icu/source/common/unicode/idna.h',
|
||||
'/intl/icu/source/common/unicode/localebuilder.h',
|
||||
'/intl/icu/source/common/unicode/localematcher.h',
|
||||
'/intl/icu/source/common/unicode/localpointer.h',
|
||||
'/intl/icu/source/common/unicode/locdspnm.h',
|
||||
'/intl/icu/source/common/unicode/locid.h',
|
||||
'/intl/icu/source/common/unicode/messagepattern.h',
|
||||
'/intl/icu/source/common/unicode/normalizer2.h',
|
||||
'/intl/icu/source/common/unicode/normlzr.h',
|
||||
'/intl/icu/source/common/unicode/parseerr.h',
|
||||
'/intl/icu/source/common/unicode/parsepos.h',
|
||||
'/intl/icu/source/common/unicode/platform.h',
|
||||
'/intl/icu/source/common/unicode/ptypes.h',
|
||||
'/intl/icu/source/common/unicode/putil.h',
|
||||
'/intl/icu/source/common/unicode/rbbi.h',
|
||||
'/intl/icu/source/common/unicode/rep.h',
|
||||
'/intl/icu/source/common/unicode/resbund.h',
|
||||
'/intl/icu/source/common/unicode/schriter.h',
|
||||
'/intl/icu/source/common/unicode/simpleformatter.h',
|
||||
'/intl/icu/source/common/unicode/std_string.h',
|
||||
'/intl/icu/source/common/unicode/strenum.h',
|
||||
'/intl/icu/source/common/unicode/stringoptions.h',
|
||||
'/intl/icu/source/common/unicode/stringpiece.h',
|
||||
'/intl/icu/source/common/unicode/stringtriebuilder.h',
|
||||
'/intl/icu/source/common/unicode/symtable.h',
|
||||
'/intl/icu/source/common/unicode/ubidi.h',
|
||||
'/intl/icu/source/common/unicode/ubiditransform.h',
|
||||
'/intl/icu/source/common/unicode/ubrk.h',
|
||||
'/intl/icu/source/common/unicode/ucasemap.h',
|
||||
'/intl/icu/source/common/unicode/ucat.h',
|
||||
'/intl/icu/source/common/unicode/uchar.h',
|
||||
'/intl/icu/source/common/unicode/ucharstrie.h',
|
||||
'/intl/icu/source/common/unicode/ucharstriebuilder.h',
|
||||
'/intl/icu/source/common/unicode/uchriter.h',
|
||||
'/intl/icu/source/common/unicode/uclean.h',
|
||||
'/intl/icu/source/common/unicode/ucnv.h',
|
||||
'/intl/icu/source/common/unicode/ucnv_cb.h',
|
||||
'/intl/icu/source/common/unicode/ucnv_err.h',
|
||||
'/intl/icu/source/common/unicode/ucnvsel.h',
|
||||
'/intl/icu/source/common/unicode/uconfig.h',
|
||||
'/intl/icu/source/common/unicode/ucpmap.h',
|
||||
'/intl/icu/source/common/unicode/ucptrie.h',
|
||||
'/intl/icu/source/common/unicode/ucurr.h',
|
||||
'/intl/icu/source/common/unicode/udata.h',
|
||||
'/intl/icu/source/common/unicode/udisplaycontext.h',
|
||||
'/intl/icu/source/common/unicode/uenum.h',
|
||||
'/intl/icu/source/common/unicode/uidna.h',
|
||||
'/intl/icu/source/common/unicode/uiter.h',
|
||||
'/intl/icu/source/common/unicode/uldnames.h',
|
||||
'/intl/icu/source/common/unicode/uloc.h',
|
||||
'/intl/icu/source/common/unicode/umachine.h',
|
||||
'/intl/icu/source/common/unicode/umisc.h',
|
||||
'/intl/icu/source/common/unicode/umutablecptrie.h',
|
||||
'/intl/icu/source/common/unicode/unifilt.h',
|
||||
'/intl/icu/source/common/unicode/unifunct.h',
|
||||
'/intl/icu/source/common/unicode/unimatch.h',
|
||||
'/intl/icu/source/common/unicode/uniset.h',
|
||||
'/intl/icu/source/common/unicode/unistr.h',
|
||||
'/intl/icu/source/common/unicode/unorm.h',
|
||||
'/intl/icu/source/common/unicode/unorm2.h',
|
||||
'/intl/icu/source/common/unicode/uobject.h',
|
||||
'/intl/icu/source/common/unicode/urename.h',
|
||||
'/intl/icu/source/common/unicode/urep.h',
|
||||
'/intl/icu/source/common/unicode/ures.h',
|
||||
'/intl/icu/source/common/unicode/uscript.h',
|
||||
'/intl/icu/source/common/unicode/uset.h',
|
||||
'/intl/icu/source/common/unicode/usetiter.h',
|
||||
'/intl/icu/source/common/unicode/ushape.h',
|
||||
'/intl/icu/source/common/unicode/usprep.h',
|
||||
'/intl/icu/source/common/unicode/ustring.h',
|
||||
'/intl/icu/source/common/unicode/ustringtrie.h',
|
||||
'/intl/icu/source/common/unicode/utext.h',
|
||||
'/intl/icu/source/common/unicode/utf.h',
|
||||
'/intl/icu/source/common/unicode/utf16.h',
|
||||
'/intl/icu/source/common/unicode/utf32.h',
|
||||
'/intl/icu/source/common/unicode/utf8.h',
|
||||
'/intl/icu/source/common/unicode/utf_old.h',
|
||||
'/intl/icu/source/common/unicode/utrace.h',
|
||||
'/intl/icu/source/common/unicode/utypes.h',
|
||||
'/intl/icu/source/common/unicode/uvernum.h',
|
||||
'/intl/icu/source/common/unicode/uversion.h',
|
||||
"/intl/icu/source/common/unicode/appendable.h",
|
||||
"/intl/icu/source/common/unicode/brkiter.h",
|
||||
"/intl/icu/source/common/unicode/bytestream.h",
|
||||
"/intl/icu/source/common/unicode/bytestrie.h",
|
||||
"/intl/icu/source/common/unicode/bytestriebuilder.h",
|
||||
"/intl/icu/source/common/unicode/caniter.h",
|
||||
"/intl/icu/source/common/unicode/casemap.h",
|
||||
"/intl/icu/source/common/unicode/char16ptr.h",
|
||||
"/intl/icu/source/common/unicode/chariter.h",
|
||||
"/intl/icu/source/common/unicode/dbbi.h",
|
||||
"/intl/icu/source/common/unicode/docmain.h",
|
||||
"/intl/icu/source/common/unicode/dtintrv.h",
|
||||
"/intl/icu/source/common/unicode/edits.h",
|
||||
"/intl/icu/source/common/unicode/enumset.h",
|
||||
"/intl/icu/source/common/unicode/errorcode.h",
|
||||
"/intl/icu/source/common/unicode/filteredbrk.h",
|
||||
"/intl/icu/source/common/unicode/icudataver.h",
|
||||
"/intl/icu/source/common/unicode/icuplug.h",
|
||||
"/intl/icu/source/common/unicode/idna.h",
|
||||
"/intl/icu/source/common/unicode/localebuilder.h",
|
||||
"/intl/icu/source/common/unicode/localematcher.h",
|
||||
"/intl/icu/source/common/unicode/localpointer.h",
|
||||
"/intl/icu/source/common/unicode/locdspnm.h",
|
||||
"/intl/icu/source/common/unicode/locid.h",
|
||||
"/intl/icu/source/common/unicode/messagepattern.h",
|
||||
"/intl/icu/source/common/unicode/normalizer2.h",
|
||||
"/intl/icu/source/common/unicode/normlzr.h",
|
||||
"/intl/icu/source/common/unicode/parseerr.h",
|
||||
"/intl/icu/source/common/unicode/parsepos.h",
|
||||
"/intl/icu/source/common/unicode/platform.h",
|
||||
"/intl/icu/source/common/unicode/ptypes.h",
|
||||
"/intl/icu/source/common/unicode/putil.h",
|
||||
"/intl/icu/source/common/unicode/rbbi.h",
|
||||
"/intl/icu/source/common/unicode/rep.h",
|
||||
"/intl/icu/source/common/unicode/resbund.h",
|
||||
"/intl/icu/source/common/unicode/schriter.h",
|
||||
"/intl/icu/source/common/unicode/simpleformatter.h",
|
||||
"/intl/icu/source/common/unicode/std_string.h",
|
||||
"/intl/icu/source/common/unicode/strenum.h",
|
||||
"/intl/icu/source/common/unicode/stringoptions.h",
|
||||
"/intl/icu/source/common/unicode/stringpiece.h",
|
||||
"/intl/icu/source/common/unicode/stringtriebuilder.h",
|
||||
"/intl/icu/source/common/unicode/symtable.h",
|
||||
"/intl/icu/source/common/unicode/ubidi.h",
|
||||
"/intl/icu/source/common/unicode/ubiditransform.h",
|
||||
"/intl/icu/source/common/unicode/ubrk.h",
|
||||
"/intl/icu/source/common/unicode/ucasemap.h",
|
||||
"/intl/icu/source/common/unicode/ucat.h",
|
||||
"/intl/icu/source/common/unicode/uchar.h",
|
||||
"/intl/icu/source/common/unicode/ucharstrie.h",
|
||||
"/intl/icu/source/common/unicode/ucharstriebuilder.h",
|
||||
"/intl/icu/source/common/unicode/uchriter.h",
|
||||
"/intl/icu/source/common/unicode/uclean.h",
|
||||
"/intl/icu/source/common/unicode/ucnv.h",
|
||||
"/intl/icu/source/common/unicode/ucnv_cb.h",
|
||||
"/intl/icu/source/common/unicode/ucnv_err.h",
|
||||
"/intl/icu/source/common/unicode/ucnvsel.h",
|
||||
"/intl/icu/source/common/unicode/uconfig.h",
|
||||
"/intl/icu/source/common/unicode/ucpmap.h",
|
||||
"/intl/icu/source/common/unicode/ucptrie.h",
|
||||
"/intl/icu/source/common/unicode/ucurr.h",
|
||||
"/intl/icu/source/common/unicode/udata.h",
|
||||
"/intl/icu/source/common/unicode/udisplaycontext.h",
|
||||
"/intl/icu/source/common/unicode/uenum.h",
|
||||
"/intl/icu/source/common/unicode/uidna.h",
|
||||
"/intl/icu/source/common/unicode/uiter.h",
|
||||
"/intl/icu/source/common/unicode/uldnames.h",
|
||||
"/intl/icu/source/common/unicode/uloc.h",
|
||||
"/intl/icu/source/common/unicode/umachine.h",
|
||||
"/intl/icu/source/common/unicode/umisc.h",
|
||||
"/intl/icu/source/common/unicode/umutablecptrie.h",
|
||||
"/intl/icu/source/common/unicode/unifilt.h",
|
||||
"/intl/icu/source/common/unicode/unifunct.h",
|
||||
"/intl/icu/source/common/unicode/unimatch.h",
|
||||
"/intl/icu/source/common/unicode/uniset.h",
|
||||
"/intl/icu/source/common/unicode/unistr.h",
|
||||
"/intl/icu/source/common/unicode/unorm.h",
|
||||
"/intl/icu/source/common/unicode/unorm2.h",
|
||||
"/intl/icu/source/common/unicode/uobject.h",
|
||||
"/intl/icu/source/common/unicode/urename.h",
|
||||
"/intl/icu/source/common/unicode/urep.h",
|
||||
"/intl/icu/source/common/unicode/ures.h",
|
||||
"/intl/icu/source/common/unicode/uscript.h",
|
||||
"/intl/icu/source/common/unicode/uset.h",
|
||||
"/intl/icu/source/common/unicode/usetiter.h",
|
||||
"/intl/icu/source/common/unicode/ushape.h",
|
||||
"/intl/icu/source/common/unicode/usprep.h",
|
||||
"/intl/icu/source/common/unicode/ustring.h",
|
||||
"/intl/icu/source/common/unicode/ustringtrie.h",
|
||||
"/intl/icu/source/common/unicode/utext.h",
|
||||
"/intl/icu/source/common/unicode/utf.h",
|
||||
"/intl/icu/source/common/unicode/utf16.h",
|
||||
"/intl/icu/source/common/unicode/utf32.h",
|
||||
"/intl/icu/source/common/unicode/utf8.h",
|
||||
"/intl/icu/source/common/unicode/utf_old.h",
|
||||
"/intl/icu/source/common/unicode/utrace.h",
|
||||
"/intl/icu/source/common/unicode/utypes.h",
|
||||
"/intl/icu/source/common/unicode/uvernum.h",
|
||||
"/intl/icu/source/common/unicode/uversion.h",
|
||||
]
|
||||
|
|
78
config/external/icu/defs.mozbuild
vendored
78
config/external/icu/defs.mozbuild
vendored
|
@ -7,69 +7,69 @@
|
|||
# Also see <http://www.icu-project.org/repos/icu/tags/latest/icu4c/readme.html#RecBuild> for the
|
||||
# recommended build options when compiling ICU.
|
||||
# Don't use icu namespace automatically in client code.
|
||||
DEFINES['U_USING_ICU_NAMESPACE'] = 0
|
||||
DEFINES["U_USING_ICU_NAMESPACE"] = 0
|
||||
# Don't include obsolete header files.
|
||||
DEFINES['U_NO_DEFAULT_INCLUDE_UTF_HEADERS'] = 1
|
||||
DEFINES['U_HIDE_OBSOLETE_UTF_OLD_H'] = 1
|
||||
DEFINES["U_NO_DEFAULT_INCLUDE_UTF_HEADERS"] = 1
|
||||
DEFINES["U_HIDE_OBSOLETE_UTF_OLD_H"] = 1
|
||||
|
||||
# Remove chunks of the library that we don't need (yet).
|
||||
DEFINES['UCONFIG_NO_LEGACY_CONVERSION'] = True
|
||||
DEFINES['UCONFIG_NO_TRANSLITERATION'] = True
|
||||
DEFINES['UCONFIG_NO_REGULAR_EXPRESSIONS'] = True
|
||||
DEFINES['UCONFIG_NO_BREAK_ITERATION'] = True
|
||||
DEFINES["UCONFIG_NO_LEGACY_CONVERSION"] = True
|
||||
DEFINES["UCONFIG_NO_TRANSLITERATION"] = True
|
||||
DEFINES["UCONFIG_NO_REGULAR_EXPRESSIONS"] = True
|
||||
DEFINES["UCONFIG_NO_BREAK_ITERATION"] = True
|
||||
|
||||
# We don't need to pass data to and from legacy char* APIs.
|
||||
DEFINES['U_CHARSET_IS_UTF8'] = True
|
||||
DEFINES["U_CHARSET_IS_UTF8"] = True
|
||||
|
||||
# Add 'explicit' keyword to UnicodeString constructors.
|
||||
DEFINES['UNISTR_FROM_CHAR_EXPLICIT'] = "explicit"
|
||||
DEFINES['UNISTR_FROM_STRING_EXPLICIT'] = "explicit"
|
||||
DEFINES["UNISTR_FROM_CHAR_EXPLICIT"] = "explicit"
|
||||
DEFINES["UNISTR_FROM_STRING_EXPLICIT"] = "explicit"
|
||||
|
||||
# Disable dynamic loading of ICU data as a loadable library.
|
||||
DEFINES['U_ENABLE_DYLOAD'] = 0
|
||||
DEFINES["U_ENABLE_DYLOAD"] = 0
|
||||
|
||||
if not CONFIG['HAVE_LANGINFO_CODESET']:
|
||||
DEFINES['U_HAVE_NL_LANGINFO_CODESET'] = 0
|
||||
if not CONFIG["HAVE_LANGINFO_CODESET"]:
|
||||
DEFINES["U_HAVE_NL_LANGINFO_CODESET"] = 0
|
||||
|
||||
if CONFIG['MOZ_DEBUG']:
|
||||
DEFINES['U_DEBUG'] = 1
|
||||
if CONFIG["MOZ_DEBUG"]:
|
||||
DEFINES["U_DEBUG"] = 1
|
||||
|
||||
# ICU requires RTTI
|
||||
if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
|
||||
CXXFLAGS += ['-frtti']
|
||||
elif CONFIG['OS_TARGET'] == 'WINNT':
|
||||
if CONFIG["CC_TYPE"] in ("clang", "gcc"):
|
||||
CXXFLAGS += ["-frtti"]
|
||||
elif CONFIG["OS_TARGET"] == "WINNT":
|
||||
# Remove the -GR- flag so we don't get a bunch of warning spam.
|
||||
COMPILE_FLAGS['OS_CXXFLAGS'] = [
|
||||
f for f in COMPILE_FLAGS['OS_CXXFLAGS'] if f != '-GR-'
|
||||
] + ['-GR']
|
||||
COMPILE_FLAGS["OS_CXXFLAGS"] = [
|
||||
f for f in COMPILE_FLAGS["OS_CXXFLAGS"] if f != "-GR-"
|
||||
] + ["-GR"]
|
||||
|
||||
DisableStlWrapping()
|
||||
AllowCompilerWarnings()
|
||||
|
||||
# We allow compiler warnings, but we can at least cut down on spammy
|
||||
# warnings that get triggered for every file.
|
||||
if CONFIG['CC_TYPE'] in ('clang', 'clang-cl'):
|
||||
if CONFIG["CC_TYPE"] in ("clang", "clang-cl"):
|
||||
CFLAGS += [
|
||||
'-Wno-c++20-compat',
|
||||
'-Wno-comma',
|
||||
'-Wno-implicit-const-int-float-conversion',
|
||||
'-Wno-macro-redefined',
|
||||
'-Wno-microsoft-include',
|
||||
'-Wno-tautological-unsigned-enum-zero-compare',
|
||||
'-Wno-unreachable-code-loop-increment',
|
||||
'-Wno-unreachable-code-return',
|
||||
"-Wno-c++20-compat",
|
||||
"-Wno-comma",
|
||||
"-Wno-implicit-const-int-float-conversion",
|
||||
"-Wno-macro-redefined",
|
||||
"-Wno-microsoft-include",
|
||||
"-Wno-tautological-unsigned-enum-zero-compare",
|
||||
"-Wno-unreachable-code-loop-increment",
|
||||
"-Wno-unreachable-code-return",
|
||||
]
|
||||
CXXFLAGS += [
|
||||
'-Wno-c++20-compat',
|
||||
'-Wno-comma',
|
||||
'-Wno-implicit-const-int-float-conversion',
|
||||
'-Wno-macro-redefined',
|
||||
'-Wno-microsoft-include',
|
||||
'-Wno-tautological-unsigned-enum-zero-compare',
|
||||
'-Wno-unreachable-code-loop-increment',
|
||||
'-Wno-unreachable-code-return',
|
||||
"-Wno-c++20-compat",
|
||||
"-Wno-comma",
|
||||
"-Wno-implicit-const-int-float-conversion",
|
||||
"-Wno-macro-redefined",
|
||||
"-Wno-microsoft-include",
|
||||
"-Wno-tautological-unsigned-enum-zero-compare",
|
||||
"-Wno-unreachable-code-loop-increment",
|
||||
"-Wno-unreachable-code-return",
|
||||
]
|
||||
|
||||
for k, v in DEFINES.items():
|
||||
if k != 'UCONFIG_NO_LEGACY_CONVERSION':
|
||||
if k != "UCONFIG_NO_LEGACY_CONVERSION":
|
||||
HOST_DEFINES[k] = v
|
||||
|
|
674
config/external/icu/i18n/sources.mozbuild
vendored
674
config/external/icu/i18n/sources.mozbuild
vendored
|
@ -1,344 +1,344 @@
|
|||
# THIS FILE IS GENERATED BY /intl/icu_sources_data.py DO NOT EDIT
|
||||
sources = [
|
||||
'/intl/icu/source/i18n/astro.cpp',
|
||||
'/intl/icu/source/i18n/basictz.cpp',
|
||||
'/intl/icu/source/i18n/bocsu.cpp',
|
||||
'/intl/icu/source/i18n/buddhcal.cpp',
|
||||
'/intl/icu/source/i18n/calendar.cpp',
|
||||
'/intl/icu/source/i18n/cecal.cpp',
|
||||
'/intl/icu/source/i18n/chnsecal.cpp',
|
||||
'/intl/icu/source/i18n/choicfmt.cpp',
|
||||
'/intl/icu/source/i18n/coleitr.cpp',
|
||||
'/intl/icu/source/i18n/coll.cpp',
|
||||
'/intl/icu/source/i18n/collation.cpp',
|
||||
'/intl/icu/source/i18n/collationbuilder.cpp',
|
||||
'/intl/icu/source/i18n/collationcompare.cpp',
|
||||
'/intl/icu/source/i18n/collationdata.cpp',
|
||||
'/intl/icu/source/i18n/collationdatabuilder.cpp',
|
||||
'/intl/icu/source/i18n/collationdatareader.cpp',
|
||||
'/intl/icu/source/i18n/collationdatawriter.cpp',
|
||||
'/intl/icu/source/i18n/collationfastlatin.cpp',
|
||||
'/intl/icu/source/i18n/collationfastlatinbuilder.cpp',
|
||||
'/intl/icu/source/i18n/collationfcd.cpp',
|
||||
'/intl/icu/source/i18n/collationiterator.cpp',
|
||||
'/intl/icu/source/i18n/collationkeys.cpp',
|
||||
'/intl/icu/source/i18n/collationroot.cpp',
|
||||
'/intl/icu/source/i18n/collationrootelements.cpp',
|
||||
'/intl/icu/source/i18n/collationruleparser.cpp',
|
||||
'/intl/icu/source/i18n/collationsets.cpp',
|
||||
'/intl/icu/source/i18n/collationsettings.cpp',
|
||||
'/intl/icu/source/i18n/collationtailoring.cpp',
|
||||
'/intl/icu/source/i18n/collationweights.cpp',
|
||||
'/intl/icu/source/i18n/compactdecimalformat.cpp',
|
||||
'/intl/icu/source/i18n/coptccal.cpp',
|
||||
'/intl/icu/source/i18n/curramt.cpp',
|
||||
'/intl/icu/source/i18n/currfmt.cpp',
|
||||
'/intl/icu/source/i18n/currpinf.cpp',
|
||||
'/intl/icu/source/i18n/currunit.cpp',
|
||||
'/intl/icu/source/i18n/dangical.cpp',
|
||||
'/intl/icu/source/i18n/datefmt.cpp',
|
||||
'/intl/icu/source/i18n/dayperiodrules.cpp',
|
||||
'/intl/icu/source/i18n/dcfmtsym.cpp',
|
||||
'/intl/icu/source/i18n/decContext.cpp',
|
||||
'/intl/icu/source/i18n/decimfmt.cpp',
|
||||
'/intl/icu/source/i18n/decNumber.cpp',
|
||||
'/intl/icu/source/i18n/displayoptions.cpp',
|
||||
'/intl/icu/source/i18n/dtfmtsym.cpp',
|
||||
'/intl/icu/source/i18n/dtitvfmt.cpp',
|
||||
'/intl/icu/source/i18n/dtitvinf.cpp',
|
||||
'/intl/icu/source/i18n/dtptngen.cpp',
|
||||
'/intl/icu/source/i18n/dtrule.cpp',
|
||||
'/intl/icu/source/i18n/erarules.cpp',
|
||||
'/intl/icu/source/i18n/ethpccal.cpp',
|
||||
'/intl/icu/source/i18n/fmtable.cpp',
|
||||
'/intl/icu/source/i18n/format.cpp',
|
||||
'/intl/icu/source/i18n/formatted_string_builder.cpp',
|
||||
'/intl/icu/source/i18n/formattedval_iterimpl.cpp',
|
||||
'/intl/icu/source/i18n/formattedval_sbimpl.cpp',
|
||||
'/intl/icu/source/i18n/formattedvalue.cpp',
|
||||
'/intl/icu/source/i18n/fphdlimp.cpp',
|
||||
'/intl/icu/source/i18n/fpositer.cpp',
|
||||
'/intl/icu/source/i18n/gregocal.cpp',
|
||||
'/intl/icu/source/i18n/gregoimp.cpp',
|
||||
'/intl/icu/source/i18n/hebrwcal.cpp',
|
||||
'/intl/icu/source/i18n/indiancal.cpp',
|
||||
'/intl/icu/source/i18n/islamcal.cpp',
|
||||
'/intl/icu/source/i18n/iso8601cal.cpp',
|
||||
'/intl/icu/source/i18n/japancal.cpp',
|
||||
'/intl/icu/source/i18n/listformatter.cpp',
|
||||
'/intl/icu/source/i18n/measfmt.cpp',
|
||||
'/intl/icu/source/i18n/measunit.cpp',
|
||||
'/intl/icu/source/i18n/measunit_extra.cpp',
|
||||
'/intl/icu/source/i18n/measure.cpp',
|
||||
'/intl/icu/source/i18n/msgfmt.cpp',
|
||||
'/intl/icu/source/i18n/nfrs.cpp',
|
||||
'/intl/icu/source/i18n/nfrule.cpp',
|
||||
'/intl/icu/source/i18n/nfsubs.cpp',
|
||||
'/intl/icu/source/i18n/number_affixutils.cpp',
|
||||
'/intl/icu/source/i18n/number_asformat.cpp',
|
||||
'/intl/icu/source/i18n/number_capi.cpp',
|
||||
'/intl/icu/source/i18n/number_compact.cpp',
|
||||
'/intl/icu/source/i18n/number_currencysymbols.cpp',
|
||||
'/intl/icu/source/i18n/number_decimalquantity.cpp',
|
||||
'/intl/icu/source/i18n/number_decimfmtprops.cpp',
|
||||
'/intl/icu/source/i18n/number_fluent.cpp',
|
||||
'/intl/icu/source/i18n/number_formatimpl.cpp',
|
||||
'/intl/icu/source/i18n/number_grouping.cpp',
|
||||
'/intl/icu/source/i18n/number_integerwidth.cpp',
|
||||
'/intl/icu/source/i18n/number_longnames.cpp',
|
||||
'/intl/icu/source/i18n/number_mapper.cpp',
|
||||
'/intl/icu/source/i18n/number_modifiers.cpp',
|
||||
'/intl/icu/source/i18n/number_multiplier.cpp',
|
||||
'/intl/icu/source/i18n/number_notation.cpp',
|
||||
'/intl/icu/source/i18n/number_output.cpp',
|
||||
'/intl/icu/source/i18n/number_padding.cpp',
|
||||
'/intl/icu/source/i18n/number_patternmodifier.cpp',
|
||||
'/intl/icu/source/i18n/number_patternstring.cpp',
|
||||
'/intl/icu/source/i18n/number_rounding.cpp',
|
||||
'/intl/icu/source/i18n/number_scientific.cpp',
|
||||
'/intl/icu/source/i18n/number_simple.cpp',
|
||||
'/intl/icu/source/i18n/number_skeletons.cpp',
|
||||
'/intl/icu/source/i18n/number_symbolswrapper.cpp',
|
||||
'/intl/icu/source/i18n/number_usageprefs.cpp',
|
||||
'/intl/icu/source/i18n/number_utils.cpp',
|
||||
'/intl/icu/source/i18n/numfmt.cpp',
|
||||
'/intl/icu/source/i18n/numparse_affixes.cpp',
|
||||
'/intl/icu/source/i18n/numparse_compositions.cpp',
|
||||
'/intl/icu/source/i18n/numparse_currency.cpp',
|
||||
'/intl/icu/source/i18n/numparse_decimal.cpp',
|
||||
'/intl/icu/source/i18n/numparse_impl.cpp',
|
||||
'/intl/icu/source/i18n/numparse_parsednumber.cpp',
|
||||
'/intl/icu/source/i18n/numparse_scientific.cpp',
|
||||
'/intl/icu/source/i18n/numparse_symbols.cpp',
|
||||
'/intl/icu/source/i18n/numparse_validators.cpp',
|
||||
'/intl/icu/source/i18n/numrange_capi.cpp',
|
||||
'/intl/icu/source/i18n/numrange_fluent.cpp',
|
||||
'/intl/icu/source/i18n/numrange_impl.cpp',
|
||||
'/intl/icu/source/i18n/numsys.cpp',
|
||||
'/intl/icu/source/i18n/olsontz.cpp',
|
||||
'/intl/icu/source/i18n/persncal.cpp',
|
||||
'/intl/icu/source/i18n/pluralranges.cpp',
|
||||
'/intl/icu/source/i18n/plurfmt.cpp',
|
||||
'/intl/icu/source/i18n/plurrule.cpp',
|
||||
'/intl/icu/source/i18n/quantityformatter.cpp',
|
||||
'/intl/icu/source/i18n/rbnf.cpp',
|
||||
'/intl/icu/source/i18n/rbtz.cpp',
|
||||
'/intl/icu/source/i18n/region.cpp',
|
||||
'/intl/icu/source/i18n/reldatefmt.cpp',
|
||||
'/intl/icu/source/i18n/reldtfmt.cpp',
|
||||
'/intl/icu/source/i18n/rulebasedcollator.cpp',
|
||||
'/intl/icu/source/i18n/scriptset.cpp',
|
||||
'/intl/icu/source/i18n/search.cpp',
|
||||
'/intl/icu/source/i18n/selfmt.cpp',
|
||||
'/intl/icu/source/i18n/sharedbreakiterator.cpp',
|
||||
'/intl/icu/source/i18n/simpletz.cpp',
|
||||
'/intl/icu/source/i18n/smpdtfmt.cpp',
|
||||
'/intl/icu/source/i18n/smpdtfst.cpp',
|
||||
'/intl/icu/source/i18n/sortkey.cpp',
|
||||
'/intl/icu/source/i18n/standardplural.cpp',
|
||||
'/intl/icu/source/i18n/string_segment.cpp',
|
||||
'/intl/icu/source/i18n/stsearch.cpp',
|
||||
'/intl/icu/source/i18n/taiwncal.cpp',
|
||||
'/intl/icu/source/i18n/timezone.cpp',
|
||||
'/intl/icu/source/i18n/tmunit.cpp',
|
||||
'/intl/icu/source/i18n/tmutamt.cpp',
|
||||
'/intl/icu/source/i18n/tmutfmt.cpp',
|
||||
'/intl/icu/source/i18n/tzfmt.cpp',
|
||||
'/intl/icu/source/i18n/tzgnames.cpp',
|
||||
'/intl/icu/source/i18n/tznames.cpp',
|
||||
'/intl/icu/source/i18n/tznames_impl.cpp',
|
||||
'/intl/icu/source/i18n/tzrule.cpp',
|
||||
'/intl/icu/source/i18n/tztrans.cpp',
|
||||
'/intl/icu/source/i18n/ucal.cpp',
|
||||
'/intl/icu/source/i18n/ucln_in.cpp',
|
||||
'/intl/icu/source/i18n/ucol.cpp',
|
||||
'/intl/icu/source/i18n/ucol_res.cpp',
|
||||
'/intl/icu/source/i18n/ucol_sit.cpp',
|
||||
'/intl/icu/source/i18n/ucoleitr.cpp',
|
||||
'/intl/icu/source/i18n/udat.cpp',
|
||||
'/intl/icu/source/i18n/udateintervalformat.cpp',
|
||||
'/intl/icu/source/i18n/udatpg.cpp',
|
||||
'/intl/icu/source/i18n/ufieldpositer.cpp',
|
||||
'/intl/icu/source/i18n/uitercollationiterator.cpp',
|
||||
'/intl/icu/source/i18n/ulistformatter.cpp',
|
||||
'/intl/icu/source/i18n/umsg.cpp',
|
||||
'/intl/icu/source/i18n/units_complexconverter.cpp',
|
||||
'/intl/icu/source/i18n/units_converter.cpp',
|
||||
'/intl/icu/source/i18n/units_data.cpp',
|
||||
'/intl/icu/source/i18n/units_router.cpp',
|
||||
'/intl/icu/source/i18n/unum.cpp',
|
||||
'/intl/icu/source/i18n/unumsys.cpp',
|
||||
'/intl/icu/source/i18n/upluralrules.cpp',
|
||||
'/intl/icu/source/i18n/usearch.cpp',
|
||||
'/intl/icu/source/i18n/uspoof.cpp',
|
||||
'/intl/icu/source/i18n/uspoof_impl.cpp',
|
||||
'/intl/icu/source/i18n/utf16collationiterator.cpp',
|
||||
'/intl/icu/source/i18n/utf8collationiterator.cpp',
|
||||
'/intl/icu/source/i18n/utmscale.cpp',
|
||||
'/intl/icu/source/i18n/vtzone.cpp',
|
||||
'/intl/icu/source/i18n/windtfmt.cpp',
|
||||
'/intl/icu/source/i18n/winnmfmt.cpp',
|
||||
'/intl/icu/source/i18n/wintzimpl.cpp',
|
||||
'/intl/icu/source/i18n/zonemeta.cpp',
|
||||
"/intl/icu/source/i18n/astro.cpp",
|
||||
"/intl/icu/source/i18n/basictz.cpp",
|
||||
"/intl/icu/source/i18n/bocsu.cpp",
|
||||
"/intl/icu/source/i18n/buddhcal.cpp",
|
||||
"/intl/icu/source/i18n/calendar.cpp",
|
||||
"/intl/icu/source/i18n/cecal.cpp",
|
||||
"/intl/icu/source/i18n/chnsecal.cpp",
|
||||
"/intl/icu/source/i18n/choicfmt.cpp",
|
||||
"/intl/icu/source/i18n/coleitr.cpp",
|
||||
"/intl/icu/source/i18n/coll.cpp",
|
||||
"/intl/icu/source/i18n/collation.cpp",
|
||||
"/intl/icu/source/i18n/collationbuilder.cpp",
|
||||
"/intl/icu/source/i18n/collationcompare.cpp",
|
||||
"/intl/icu/source/i18n/collationdata.cpp",
|
||||
"/intl/icu/source/i18n/collationdatabuilder.cpp",
|
||||
"/intl/icu/source/i18n/collationdatareader.cpp",
|
||||
"/intl/icu/source/i18n/collationdatawriter.cpp",
|
||||
"/intl/icu/source/i18n/collationfastlatin.cpp",
|
||||
"/intl/icu/source/i18n/collationfastlatinbuilder.cpp",
|
||||
"/intl/icu/source/i18n/collationfcd.cpp",
|
||||
"/intl/icu/source/i18n/collationiterator.cpp",
|
||||
"/intl/icu/source/i18n/collationkeys.cpp",
|
||||
"/intl/icu/source/i18n/collationroot.cpp",
|
||||
"/intl/icu/source/i18n/collationrootelements.cpp",
|
||||
"/intl/icu/source/i18n/collationruleparser.cpp",
|
||||
"/intl/icu/source/i18n/collationsets.cpp",
|
||||
"/intl/icu/source/i18n/collationsettings.cpp",
|
||||
"/intl/icu/source/i18n/collationtailoring.cpp",
|
||||
"/intl/icu/source/i18n/collationweights.cpp",
|
||||
"/intl/icu/source/i18n/compactdecimalformat.cpp",
|
||||
"/intl/icu/source/i18n/coptccal.cpp",
|
||||
"/intl/icu/source/i18n/curramt.cpp",
|
||||
"/intl/icu/source/i18n/currfmt.cpp",
|
||||
"/intl/icu/source/i18n/currpinf.cpp",
|
||||
"/intl/icu/source/i18n/currunit.cpp",
|
||||
"/intl/icu/source/i18n/dangical.cpp",
|
||||
"/intl/icu/source/i18n/datefmt.cpp",
|
||||
"/intl/icu/source/i18n/dayperiodrules.cpp",
|
||||
"/intl/icu/source/i18n/dcfmtsym.cpp",
|
||||
"/intl/icu/source/i18n/decContext.cpp",
|
||||
"/intl/icu/source/i18n/decimfmt.cpp",
|
||||
"/intl/icu/source/i18n/decNumber.cpp",
|
||||
"/intl/icu/source/i18n/displayoptions.cpp",
|
||||
"/intl/icu/source/i18n/dtfmtsym.cpp",
|
||||
"/intl/icu/source/i18n/dtitvfmt.cpp",
|
||||
"/intl/icu/source/i18n/dtitvinf.cpp",
|
||||
"/intl/icu/source/i18n/dtptngen.cpp",
|
||||
"/intl/icu/source/i18n/dtrule.cpp",
|
||||
"/intl/icu/source/i18n/erarules.cpp",
|
||||
"/intl/icu/source/i18n/ethpccal.cpp",
|
||||
"/intl/icu/source/i18n/fmtable.cpp",
|
||||
"/intl/icu/source/i18n/format.cpp",
|
||||
"/intl/icu/source/i18n/formatted_string_builder.cpp",
|
||||
"/intl/icu/source/i18n/formattedval_iterimpl.cpp",
|
||||
"/intl/icu/source/i18n/formattedval_sbimpl.cpp",
|
||||
"/intl/icu/source/i18n/formattedvalue.cpp",
|
||||
"/intl/icu/source/i18n/fphdlimp.cpp",
|
||||
"/intl/icu/source/i18n/fpositer.cpp",
|
||||
"/intl/icu/source/i18n/gregocal.cpp",
|
||||
"/intl/icu/source/i18n/gregoimp.cpp",
|
||||
"/intl/icu/source/i18n/hebrwcal.cpp",
|
||||
"/intl/icu/source/i18n/indiancal.cpp",
|
||||
"/intl/icu/source/i18n/islamcal.cpp",
|
||||
"/intl/icu/source/i18n/iso8601cal.cpp",
|
||||
"/intl/icu/source/i18n/japancal.cpp",
|
||||
"/intl/icu/source/i18n/listformatter.cpp",
|
||||
"/intl/icu/source/i18n/measfmt.cpp",
|
||||
"/intl/icu/source/i18n/measunit.cpp",
|
||||
"/intl/icu/source/i18n/measunit_extra.cpp",
|
||||
"/intl/icu/source/i18n/measure.cpp",
|
||||
"/intl/icu/source/i18n/msgfmt.cpp",
|
||||
"/intl/icu/source/i18n/nfrs.cpp",
|
||||
"/intl/icu/source/i18n/nfrule.cpp",
|
||||
"/intl/icu/source/i18n/nfsubs.cpp",
|
||||
"/intl/icu/source/i18n/number_affixutils.cpp",
|
||||
"/intl/icu/source/i18n/number_asformat.cpp",
|
||||
"/intl/icu/source/i18n/number_capi.cpp",
|
||||
"/intl/icu/source/i18n/number_compact.cpp",
|
||||
"/intl/icu/source/i18n/number_currencysymbols.cpp",
|
||||
"/intl/icu/source/i18n/number_decimalquantity.cpp",
|
||||
"/intl/icu/source/i18n/number_decimfmtprops.cpp",
|
||||
"/intl/icu/source/i18n/number_fluent.cpp",
|
||||
"/intl/icu/source/i18n/number_formatimpl.cpp",
|
||||
"/intl/icu/source/i18n/number_grouping.cpp",
|
||||
"/intl/icu/source/i18n/number_integerwidth.cpp",
|
||||
"/intl/icu/source/i18n/number_longnames.cpp",
|
||||
"/intl/icu/source/i18n/number_mapper.cpp",
|
||||
"/intl/icu/source/i18n/number_modifiers.cpp",
|
||||
"/intl/icu/source/i18n/number_multiplier.cpp",
|
||||
"/intl/icu/source/i18n/number_notation.cpp",
|
||||
"/intl/icu/source/i18n/number_output.cpp",
|
||||
"/intl/icu/source/i18n/number_padding.cpp",
|
||||
"/intl/icu/source/i18n/number_patternmodifier.cpp",
|
||||
"/intl/icu/source/i18n/number_patternstring.cpp",
|
||||
"/intl/icu/source/i18n/number_rounding.cpp",
|
||||
"/intl/icu/source/i18n/number_scientific.cpp",
|
||||
"/intl/icu/source/i18n/number_simple.cpp",
|
||||
"/intl/icu/source/i18n/number_skeletons.cpp",
|
||||
"/intl/icu/source/i18n/number_symbolswrapper.cpp",
|
||||
"/intl/icu/source/i18n/number_usageprefs.cpp",
|
||||
"/intl/icu/source/i18n/number_utils.cpp",
|
||||
"/intl/icu/source/i18n/numfmt.cpp",
|
||||
"/intl/icu/source/i18n/numparse_affixes.cpp",
|
||||
"/intl/icu/source/i18n/numparse_compositions.cpp",
|
||||
"/intl/icu/source/i18n/numparse_currency.cpp",
|
||||
"/intl/icu/source/i18n/numparse_decimal.cpp",
|
||||
"/intl/icu/source/i18n/numparse_impl.cpp",
|
||||
"/intl/icu/source/i18n/numparse_parsednumber.cpp",
|
||||
"/intl/icu/source/i18n/numparse_scientific.cpp",
|
||||
"/intl/icu/source/i18n/numparse_symbols.cpp",
|
||||
"/intl/icu/source/i18n/numparse_validators.cpp",
|
||||
"/intl/icu/source/i18n/numrange_capi.cpp",
|
||||
"/intl/icu/source/i18n/numrange_fluent.cpp",
|
||||
"/intl/icu/source/i18n/numrange_impl.cpp",
|
||||
"/intl/icu/source/i18n/numsys.cpp",
|
||||
"/intl/icu/source/i18n/olsontz.cpp",
|
||||
"/intl/icu/source/i18n/persncal.cpp",
|
||||
"/intl/icu/source/i18n/pluralranges.cpp",
|
||||
"/intl/icu/source/i18n/plurfmt.cpp",
|
||||
"/intl/icu/source/i18n/plurrule.cpp",
|
||||
"/intl/icu/source/i18n/quantityformatter.cpp",
|
||||
"/intl/icu/source/i18n/rbnf.cpp",
|
||||
"/intl/icu/source/i18n/rbtz.cpp",
|
||||
"/intl/icu/source/i18n/region.cpp",
|
||||
"/intl/icu/source/i18n/reldatefmt.cpp",
|
||||
"/intl/icu/source/i18n/reldtfmt.cpp",
|
||||
"/intl/icu/source/i18n/rulebasedcollator.cpp",
|
||||
"/intl/icu/source/i18n/scriptset.cpp",
|
||||
"/intl/icu/source/i18n/search.cpp",
|
||||
"/intl/icu/source/i18n/selfmt.cpp",
|
||||
"/intl/icu/source/i18n/sharedbreakiterator.cpp",
|
||||
"/intl/icu/source/i18n/simpletz.cpp",
|
||||
"/intl/icu/source/i18n/smpdtfmt.cpp",
|
||||
"/intl/icu/source/i18n/smpdtfst.cpp",
|
||||
"/intl/icu/source/i18n/sortkey.cpp",
|
||||
"/intl/icu/source/i18n/standardplural.cpp",
|
||||
"/intl/icu/source/i18n/string_segment.cpp",
|
||||
"/intl/icu/source/i18n/stsearch.cpp",
|
||||
"/intl/icu/source/i18n/taiwncal.cpp",
|
||||
"/intl/icu/source/i18n/timezone.cpp",
|
||||
"/intl/icu/source/i18n/tmunit.cpp",
|
||||
"/intl/icu/source/i18n/tmutamt.cpp",
|
||||
"/intl/icu/source/i18n/tmutfmt.cpp",
|
||||
"/intl/icu/source/i18n/tzfmt.cpp",
|
||||
"/intl/icu/source/i18n/tzgnames.cpp",
|
||||
"/intl/icu/source/i18n/tznames.cpp",
|
||||
"/intl/icu/source/i18n/tznames_impl.cpp",
|
||||
"/intl/icu/source/i18n/tzrule.cpp",
|
||||
"/intl/icu/source/i18n/tztrans.cpp",
|
||||
"/intl/icu/source/i18n/ucal.cpp",
|
||||
"/intl/icu/source/i18n/ucln_in.cpp",
|
||||
"/intl/icu/source/i18n/ucol.cpp",
|
||||
"/intl/icu/source/i18n/ucol_res.cpp",
|
||||
"/intl/icu/source/i18n/ucol_sit.cpp",
|
||||
"/intl/icu/source/i18n/ucoleitr.cpp",
|
||||
"/intl/icu/source/i18n/udat.cpp",
|
||||
"/intl/icu/source/i18n/udateintervalformat.cpp",
|
||||
"/intl/icu/source/i18n/udatpg.cpp",
|
||||
"/intl/icu/source/i18n/ufieldpositer.cpp",
|
||||
"/intl/icu/source/i18n/uitercollationiterator.cpp",
|
||||
"/intl/icu/source/i18n/ulistformatter.cpp",
|
||||
"/intl/icu/source/i18n/umsg.cpp",
|
||||
"/intl/icu/source/i18n/units_complexconverter.cpp",
|
||||
"/intl/icu/source/i18n/units_converter.cpp",
|
||||
"/intl/icu/source/i18n/units_data.cpp",
|
||||
"/intl/icu/source/i18n/units_router.cpp",
|
||||
"/intl/icu/source/i18n/unum.cpp",
|
||||
"/intl/icu/source/i18n/unumsys.cpp",
|
||||
"/intl/icu/source/i18n/upluralrules.cpp",
|
||||
"/intl/icu/source/i18n/usearch.cpp",
|
||||
"/intl/icu/source/i18n/uspoof.cpp",
|
||||
"/intl/icu/source/i18n/uspoof_impl.cpp",
|
||||
"/intl/icu/source/i18n/utf16collationiterator.cpp",
|
||||
"/intl/icu/source/i18n/utf8collationiterator.cpp",
|
||||
"/intl/icu/source/i18n/utmscale.cpp",
|
||||
"/intl/icu/source/i18n/vtzone.cpp",
|
||||
"/intl/icu/source/i18n/windtfmt.cpp",
|
||||
"/intl/icu/source/i18n/winnmfmt.cpp",
|
||||
"/intl/icu/source/i18n/wintzimpl.cpp",
|
||||
"/intl/icu/source/i18n/zonemeta.cpp",
|
||||
]
|
||||
other_sources = [
|
||||
'/intl/icu/source/i18n/alphaindex.cpp',
|
||||
'/intl/icu/source/i18n/anytrans.cpp',
|
||||
'/intl/icu/source/i18n/brktrans.cpp',
|
||||
'/intl/icu/source/i18n/casetrn.cpp',
|
||||
'/intl/icu/source/i18n/cpdtrans.cpp',
|
||||
'/intl/icu/source/i18n/csdetect.cpp',
|
||||
'/intl/icu/source/i18n/csmatch.cpp',
|
||||
'/intl/icu/source/i18n/csr2022.cpp',
|
||||
'/intl/icu/source/i18n/csrecog.cpp',
|
||||
'/intl/icu/source/i18n/csrmbcs.cpp',
|
||||
'/intl/icu/source/i18n/csrsbcs.cpp',
|
||||
'/intl/icu/source/i18n/csrucode.cpp',
|
||||
'/intl/icu/source/i18n/csrutf8.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-bignum-dtoa.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-bignum.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-cached-powers.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-double-to-string.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-fast-dtoa.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-string-to-double.cpp',
|
||||
'/intl/icu/source/i18n/double-conversion-strtod.cpp',
|
||||
'/intl/icu/source/i18n/esctrn.cpp',
|
||||
'/intl/icu/source/i18n/fmtable_cnv.cpp',
|
||||
'/intl/icu/source/i18n/funcrepl.cpp',
|
||||
'/intl/icu/source/i18n/gender.cpp',
|
||||
'/intl/icu/source/i18n/inputext.cpp',
|
||||
'/intl/icu/source/i18n/name2uni.cpp',
|
||||
'/intl/icu/source/i18n/nortrans.cpp',
|
||||
'/intl/icu/source/i18n/nultrans.cpp',
|
||||
'/intl/icu/source/i18n/quant.cpp',
|
||||
'/intl/icu/source/i18n/rbt.cpp',
|
||||
'/intl/icu/source/i18n/rbt_data.cpp',
|
||||
'/intl/icu/source/i18n/rbt_pars.cpp',
|
||||
'/intl/icu/source/i18n/rbt_rule.cpp',
|
||||
'/intl/icu/source/i18n/rbt_set.cpp',
|
||||
'/intl/icu/source/i18n/regexcmp.cpp',
|
||||
'/intl/icu/source/i18n/regeximp.cpp',
|
||||
'/intl/icu/source/i18n/regexst.cpp',
|
||||
'/intl/icu/source/i18n/regextxt.cpp',
|
||||
'/intl/icu/source/i18n/rematch.cpp',
|
||||
'/intl/icu/source/i18n/remtrans.cpp',
|
||||
'/intl/icu/source/i18n/repattrn.cpp',
|
||||
'/intl/icu/source/i18n/scientificnumberformatter.cpp',
|
||||
'/intl/icu/source/i18n/strmatch.cpp',
|
||||
'/intl/icu/source/i18n/strrepl.cpp',
|
||||
'/intl/icu/source/i18n/titletrn.cpp',
|
||||
'/intl/icu/source/i18n/tolowtrn.cpp',
|
||||
'/intl/icu/source/i18n/toupptrn.cpp',
|
||||
'/intl/icu/source/i18n/translit.cpp',
|
||||
'/intl/icu/source/i18n/transreg.cpp',
|
||||
'/intl/icu/source/i18n/tridpars.cpp',
|
||||
'/intl/icu/source/i18n/ucsdet.cpp',
|
||||
'/intl/icu/source/i18n/ulocdata.cpp',
|
||||
'/intl/icu/source/i18n/unesctrn.cpp',
|
||||
'/intl/icu/source/i18n/uni2name.cpp',
|
||||
'/intl/icu/source/i18n/uregex.cpp',
|
||||
'/intl/icu/source/i18n/uregexc.cpp',
|
||||
'/intl/icu/source/i18n/uregion.cpp',
|
||||
'/intl/icu/source/i18n/uspoof_build.cpp',
|
||||
'/intl/icu/source/i18n/uspoof_conf.cpp',
|
||||
'/intl/icu/source/i18n/utrans.cpp',
|
||||
'/intl/icu/source/i18n/vzone.cpp',
|
||||
'/intl/icu/source/i18n/zrule.cpp',
|
||||
'/intl/icu/source/i18n/ztrans.cpp',
|
||||
"/intl/icu/source/i18n/alphaindex.cpp",
|
||||
"/intl/icu/source/i18n/anytrans.cpp",
|
||||
"/intl/icu/source/i18n/brktrans.cpp",
|
||||
"/intl/icu/source/i18n/casetrn.cpp",
|
||||
"/intl/icu/source/i18n/cpdtrans.cpp",
|
||||
"/intl/icu/source/i18n/csdetect.cpp",
|
||||
"/intl/icu/source/i18n/csmatch.cpp",
|
||||
"/intl/icu/source/i18n/csr2022.cpp",
|
||||
"/intl/icu/source/i18n/csrecog.cpp",
|
||||
"/intl/icu/source/i18n/csrmbcs.cpp",
|
||||
"/intl/icu/source/i18n/csrsbcs.cpp",
|
||||
"/intl/icu/source/i18n/csrucode.cpp",
|
||||
"/intl/icu/source/i18n/csrutf8.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-bignum-dtoa.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-bignum.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-cached-powers.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-double-to-string.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-fast-dtoa.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-string-to-double.cpp",
|
||||
"/intl/icu/source/i18n/double-conversion-strtod.cpp",
|
||||
"/intl/icu/source/i18n/esctrn.cpp",
|
||||
"/intl/icu/source/i18n/fmtable_cnv.cpp",
|
||||
"/intl/icu/source/i18n/funcrepl.cpp",
|
||||
"/intl/icu/source/i18n/gender.cpp",
|
||||
"/intl/icu/source/i18n/inputext.cpp",
|
||||
"/intl/icu/source/i18n/name2uni.cpp",
|
||||
"/intl/icu/source/i18n/nortrans.cpp",
|
||||
"/intl/icu/source/i18n/nultrans.cpp",
|
||||
"/intl/icu/source/i18n/quant.cpp",
|
||||
"/intl/icu/source/i18n/rbt.cpp",
|
||||
"/intl/icu/source/i18n/rbt_data.cpp",
|
||||
"/intl/icu/source/i18n/rbt_pars.cpp",
|
||||
"/intl/icu/source/i18n/rbt_rule.cpp",
|
||||
"/intl/icu/source/i18n/rbt_set.cpp",
|
||||
"/intl/icu/source/i18n/regexcmp.cpp",
|
||||
"/intl/icu/source/i18n/regeximp.cpp",
|
||||
"/intl/icu/source/i18n/regexst.cpp",
|
||||
"/intl/icu/source/i18n/regextxt.cpp",
|
||||
"/intl/icu/source/i18n/rematch.cpp",
|
||||
"/intl/icu/source/i18n/remtrans.cpp",
|
||||
"/intl/icu/source/i18n/repattrn.cpp",
|
||||
"/intl/icu/source/i18n/scientificnumberformatter.cpp",
|
||||
"/intl/icu/source/i18n/strmatch.cpp",
|
||||
"/intl/icu/source/i18n/strrepl.cpp",
|
||||
"/intl/icu/source/i18n/titletrn.cpp",
|
||||
"/intl/icu/source/i18n/tolowtrn.cpp",
|
||||
"/intl/icu/source/i18n/toupptrn.cpp",
|
||||
"/intl/icu/source/i18n/translit.cpp",
|
||||
"/intl/icu/source/i18n/transreg.cpp",
|
||||
"/intl/icu/source/i18n/tridpars.cpp",
|
||||
"/intl/icu/source/i18n/ucsdet.cpp",
|
||||
"/intl/icu/source/i18n/ulocdata.cpp",
|
||||
"/intl/icu/source/i18n/unesctrn.cpp",
|
||||
"/intl/icu/source/i18n/uni2name.cpp",
|
||||
"/intl/icu/source/i18n/uregex.cpp",
|
||||
"/intl/icu/source/i18n/uregexc.cpp",
|
||||
"/intl/icu/source/i18n/uregion.cpp",
|
||||
"/intl/icu/source/i18n/uspoof_build.cpp",
|
||||
"/intl/icu/source/i18n/uspoof_conf.cpp",
|
||||
"/intl/icu/source/i18n/utrans.cpp",
|
||||
"/intl/icu/source/i18n/vzone.cpp",
|
||||
"/intl/icu/source/i18n/zrule.cpp",
|
||||
"/intl/icu/source/i18n/ztrans.cpp",
|
||||
]
|
||||
EXPORTS.unicode += [
|
||||
'/intl/icu/source/i18n/unicode/alphaindex.h',
|
||||
'/intl/icu/source/i18n/unicode/basictz.h',
|
||||
'/intl/icu/source/i18n/unicode/calendar.h',
|
||||
'/intl/icu/source/i18n/unicode/choicfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/coleitr.h',
|
||||
'/intl/icu/source/i18n/unicode/coll.h',
|
||||
'/intl/icu/source/i18n/unicode/compactdecimalformat.h',
|
||||
'/intl/icu/source/i18n/unicode/curramt.h',
|
||||
'/intl/icu/source/i18n/unicode/currpinf.h',
|
||||
'/intl/icu/source/i18n/unicode/currunit.h',
|
||||
'/intl/icu/source/i18n/unicode/datefmt.h',
|
||||
'/intl/icu/source/i18n/unicode/dcfmtsym.h',
|
||||
'/intl/icu/source/i18n/unicode/decimfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/displayoptions.h',
|
||||
'/intl/icu/source/i18n/unicode/dtfmtsym.h',
|
||||
'/intl/icu/source/i18n/unicode/dtitvfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/dtitvinf.h',
|
||||
'/intl/icu/source/i18n/unicode/dtptngen.h',
|
||||
'/intl/icu/source/i18n/unicode/dtrule.h',
|
||||
'/intl/icu/source/i18n/unicode/fieldpos.h',
|
||||
'/intl/icu/source/i18n/unicode/fmtable.h',
|
||||
'/intl/icu/source/i18n/unicode/format.h',
|
||||
'/intl/icu/source/i18n/unicode/formattednumber.h',
|
||||
'/intl/icu/source/i18n/unicode/formattedvalue.h',
|
||||
'/intl/icu/source/i18n/unicode/fpositer.h',
|
||||
'/intl/icu/source/i18n/unicode/gender.h',
|
||||
'/intl/icu/source/i18n/unicode/gregocal.h',
|
||||
'/intl/icu/source/i18n/unicode/listformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/measfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/measunit.h',
|
||||
'/intl/icu/source/i18n/unicode/measure.h',
|
||||
'/intl/icu/source/i18n/unicode/msgfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/nounit.h',
|
||||
'/intl/icu/source/i18n/unicode/numberformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/numberrangeformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/numfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/numsys.h',
|
||||
'/intl/icu/source/i18n/unicode/plurfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/plurrule.h',
|
||||
'/intl/icu/source/i18n/unicode/rbnf.h',
|
||||
'/intl/icu/source/i18n/unicode/rbtz.h',
|
||||
'/intl/icu/source/i18n/unicode/regex.h',
|
||||
'/intl/icu/source/i18n/unicode/region.h',
|
||||
'/intl/icu/source/i18n/unicode/reldatefmt.h',
|
||||
'/intl/icu/source/i18n/unicode/scientificnumberformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/search.h',
|
||||
'/intl/icu/source/i18n/unicode/selfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/simplenumberformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/simpletz.h',
|
||||
'/intl/icu/source/i18n/unicode/smpdtfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/sortkey.h',
|
||||
'/intl/icu/source/i18n/unicode/stsearch.h',
|
||||
'/intl/icu/source/i18n/unicode/tblcoll.h',
|
||||
'/intl/icu/source/i18n/unicode/timezone.h',
|
||||
'/intl/icu/source/i18n/unicode/tmunit.h',
|
||||
'/intl/icu/source/i18n/unicode/tmutamt.h',
|
||||
'/intl/icu/source/i18n/unicode/tmutfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/translit.h',
|
||||
'/intl/icu/source/i18n/unicode/tzfmt.h',
|
||||
'/intl/icu/source/i18n/unicode/tznames.h',
|
||||
'/intl/icu/source/i18n/unicode/tzrule.h',
|
||||
'/intl/icu/source/i18n/unicode/tztrans.h',
|
||||
'/intl/icu/source/i18n/unicode/ucal.h',
|
||||
'/intl/icu/source/i18n/unicode/ucol.h',
|
||||
'/intl/icu/source/i18n/unicode/ucoleitr.h',
|
||||
'/intl/icu/source/i18n/unicode/ucsdet.h',
|
||||
'/intl/icu/source/i18n/unicode/udat.h',
|
||||
'/intl/icu/source/i18n/unicode/udateintervalformat.h',
|
||||
'/intl/icu/source/i18n/unicode/udatpg.h',
|
||||
'/intl/icu/source/i18n/unicode/udisplayoptions.h',
|
||||
'/intl/icu/source/i18n/unicode/ufieldpositer.h',
|
||||
'/intl/icu/source/i18n/unicode/uformattable.h',
|
||||
'/intl/icu/source/i18n/unicode/uformattednumber.h',
|
||||
'/intl/icu/source/i18n/unicode/uformattedvalue.h',
|
||||
'/intl/icu/source/i18n/unicode/ugender.h',
|
||||
'/intl/icu/source/i18n/unicode/ulistformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/ulocdata.h',
|
||||
'/intl/icu/source/i18n/unicode/umsg.h',
|
||||
'/intl/icu/source/i18n/unicode/unirepl.h',
|
||||
'/intl/icu/source/i18n/unicode/unum.h',
|
||||
'/intl/icu/source/i18n/unicode/unumberformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/unumberoptions.h',
|
||||
'/intl/icu/source/i18n/unicode/unumberrangeformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/unumsys.h',
|
||||
'/intl/icu/source/i18n/unicode/upluralrules.h',
|
||||
'/intl/icu/source/i18n/unicode/uregex.h',
|
||||
'/intl/icu/source/i18n/unicode/uregion.h',
|
||||
'/intl/icu/source/i18n/unicode/ureldatefmt.h',
|
||||
'/intl/icu/source/i18n/unicode/usearch.h',
|
||||
'/intl/icu/source/i18n/unicode/usimplenumberformatter.h',
|
||||
'/intl/icu/source/i18n/unicode/uspoof.h',
|
||||
'/intl/icu/source/i18n/unicode/utmscale.h',
|
||||
'/intl/icu/source/i18n/unicode/utrans.h',
|
||||
'/intl/icu/source/i18n/unicode/vtzone.h',
|
||||
"/intl/icu/source/i18n/unicode/alphaindex.h",
|
||||
"/intl/icu/source/i18n/unicode/basictz.h",
|
||||
"/intl/icu/source/i18n/unicode/calendar.h",
|
||||
"/intl/icu/source/i18n/unicode/choicfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/coleitr.h",
|
||||
"/intl/icu/source/i18n/unicode/coll.h",
|
||||
"/intl/icu/source/i18n/unicode/compactdecimalformat.h",
|
||||
"/intl/icu/source/i18n/unicode/curramt.h",
|
||||
"/intl/icu/source/i18n/unicode/currpinf.h",
|
||||
"/intl/icu/source/i18n/unicode/currunit.h",
|
||||
"/intl/icu/source/i18n/unicode/datefmt.h",
|
||||
"/intl/icu/source/i18n/unicode/dcfmtsym.h",
|
||||
"/intl/icu/source/i18n/unicode/decimfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/displayoptions.h",
|
||||
"/intl/icu/source/i18n/unicode/dtfmtsym.h",
|
||||
"/intl/icu/source/i18n/unicode/dtitvfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/dtitvinf.h",
|
||||
"/intl/icu/source/i18n/unicode/dtptngen.h",
|
||||
"/intl/icu/source/i18n/unicode/dtrule.h",
|
||||
"/intl/icu/source/i18n/unicode/fieldpos.h",
|
||||
"/intl/icu/source/i18n/unicode/fmtable.h",
|
||||
"/intl/icu/source/i18n/unicode/format.h",
|
||||
"/intl/icu/source/i18n/unicode/formattednumber.h",
|
||||
"/intl/icu/source/i18n/unicode/formattedvalue.h",
|
||||
"/intl/icu/source/i18n/unicode/fpositer.h",
|
||||
"/intl/icu/source/i18n/unicode/gender.h",
|
||||
"/intl/icu/source/i18n/unicode/gregocal.h",
|
||||
"/intl/icu/source/i18n/unicode/listformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/measfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/measunit.h",
|
||||
"/intl/icu/source/i18n/unicode/measure.h",
|
||||
"/intl/icu/source/i18n/unicode/msgfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/nounit.h",
|
||||
"/intl/icu/source/i18n/unicode/numberformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/numberrangeformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/numfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/numsys.h",
|
||||
"/intl/icu/source/i18n/unicode/plurfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/plurrule.h",
|
||||
"/intl/icu/source/i18n/unicode/rbnf.h",
|
||||
"/intl/icu/source/i18n/unicode/rbtz.h",
|
||||
"/intl/icu/source/i18n/unicode/regex.h",
|
||||
"/intl/icu/source/i18n/unicode/region.h",
|
||||
"/intl/icu/source/i18n/unicode/reldatefmt.h",
|
||||
"/intl/icu/source/i18n/unicode/scientificnumberformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/search.h",
|
||||
"/intl/icu/source/i18n/unicode/selfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/simplenumberformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/simpletz.h",
|
||||
"/intl/icu/source/i18n/unicode/smpdtfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/sortkey.h",
|
||||
"/intl/icu/source/i18n/unicode/stsearch.h",
|
||||
"/intl/icu/source/i18n/unicode/tblcoll.h",
|
||||
"/intl/icu/source/i18n/unicode/timezone.h",
|
||||
"/intl/icu/source/i18n/unicode/tmunit.h",
|
||||
"/intl/icu/source/i18n/unicode/tmutamt.h",
|
||||
"/intl/icu/source/i18n/unicode/tmutfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/translit.h",
|
||||
"/intl/icu/source/i18n/unicode/tzfmt.h",
|
||||
"/intl/icu/source/i18n/unicode/tznames.h",
|
||||
"/intl/icu/source/i18n/unicode/tzrule.h",
|
||||
"/intl/icu/source/i18n/unicode/tztrans.h",
|
||||
"/intl/icu/source/i18n/unicode/ucal.h",
|
||||
"/intl/icu/source/i18n/unicode/ucol.h",
|
||||
"/intl/icu/source/i18n/unicode/ucoleitr.h",
|
||||
"/intl/icu/source/i18n/unicode/ucsdet.h",
|
||||
"/intl/icu/source/i18n/unicode/udat.h",
|
||||
"/intl/icu/source/i18n/unicode/udateintervalformat.h",
|
||||
"/intl/icu/source/i18n/unicode/udatpg.h",
|
||||
"/intl/icu/source/i18n/unicode/udisplayoptions.h",
|
||||
"/intl/icu/source/i18n/unicode/ufieldpositer.h",
|
||||
"/intl/icu/source/i18n/unicode/uformattable.h",
|
||||
"/intl/icu/source/i18n/unicode/uformattednumber.h",
|
||||
"/intl/icu/source/i18n/unicode/uformattedvalue.h",
|
||||
"/intl/icu/source/i18n/unicode/ugender.h",
|
||||
"/intl/icu/source/i18n/unicode/ulistformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/ulocdata.h",
|
||||
"/intl/icu/source/i18n/unicode/umsg.h",
|
||||
"/intl/icu/source/i18n/unicode/unirepl.h",
|
||||
"/intl/icu/source/i18n/unicode/unum.h",
|
||||
"/intl/icu/source/i18n/unicode/unumberformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/unumberoptions.h",
|
||||
"/intl/icu/source/i18n/unicode/unumberrangeformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/unumsys.h",
|
||||
"/intl/icu/source/i18n/unicode/upluralrules.h",
|
||||
"/intl/icu/source/i18n/unicode/uregex.h",
|
||||
"/intl/icu/source/i18n/unicode/uregion.h",
|
||||
"/intl/icu/source/i18n/unicode/ureldatefmt.h",
|
||||
"/intl/icu/source/i18n/unicode/usearch.h",
|
||||
"/intl/icu/source/i18n/unicode/usimplenumberformatter.h",
|
||||
"/intl/icu/source/i18n/unicode/uspoof.h",
|
||||
"/intl/icu/source/i18n/unicode/utmscale.h",
|
||||
"/intl/icu/source/i18n/unicode/utrans.h",
|
||||
"/intl/icu/source/i18n/unicode/vtzone.h",
|
||||
]
|
||||
|
|
2
config/external/icu/icupkg/sources.mozbuild
vendored
2
config/external/icu/icupkg/sources.mozbuild
vendored
|
@ -1,4 +1,4 @@
|
|||
# THIS FILE IS GENERATED BY /intl/icu_sources_data.py DO NOT EDIT
|
||||
sources = [
|
||||
'/intl/icu/source/tools/icupkg/icupkg.cpp',
|
||||
"/intl/icu/source/tools/icupkg/icupkg.cpp",
|
||||
]
|
||||
|
|
48
config/external/icu/toolutil/sources.mozbuild
vendored
48
config/external/icu/toolutil/sources.mozbuild
vendored
|
@ -1,27 +1,27 @@
|
|||
# THIS FILE IS GENERATED BY /intl/icu_sources_data.py DO NOT EDIT
|
||||
sources = [
|
||||
'/intl/icu/source/tools/toolutil/collationinfo.cpp',
|
||||
'/intl/icu/source/tools/toolutil/dbgutil.cpp',
|
||||
'/intl/icu/source/tools/toolutil/denseranges.cpp',
|
||||
'/intl/icu/source/tools/toolutil/filestrm.cpp',
|
||||
'/intl/icu/source/tools/toolutil/filetools.cpp',
|
||||
'/intl/icu/source/tools/toolutil/flagparser.cpp',
|
||||
'/intl/icu/source/tools/toolutil/package.cpp',
|
||||
'/intl/icu/source/tools/toolutil/pkg_genc.cpp',
|
||||
'/intl/icu/source/tools/toolutil/pkg_gencmn.cpp',
|
||||
'/intl/icu/source/tools/toolutil/pkg_icu.cpp',
|
||||
'/intl/icu/source/tools/toolutil/pkgitems.cpp',
|
||||
'/intl/icu/source/tools/toolutil/ppucd.cpp',
|
||||
'/intl/icu/source/tools/toolutil/swapimpl.cpp',
|
||||
'/intl/icu/source/tools/toolutil/toolutil.cpp',
|
||||
'/intl/icu/source/tools/toolutil/ucbuf.cpp',
|
||||
'/intl/icu/source/tools/toolutil/ucln_tu.cpp',
|
||||
'/intl/icu/source/tools/toolutil/ucm.cpp',
|
||||
'/intl/icu/source/tools/toolutil/ucmstate.cpp',
|
||||
'/intl/icu/source/tools/toolutil/udbgutil.cpp',
|
||||
'/intl/icu/source/tools/toolutil/unewdata.cpp',
|
||||
'/intl/icu/source/tools/toolutil/uoptions.cpp',
|
||||
'/intl/icu/source/tools/toolutil/uparse.cpp',
|
||||
'/intl/icu/source/tools/toolutil/writesrc.cpp',
|
||||
'/intl/icu/source/tools/toolutil/xmlparser.cpp',
|
||||
"/intl/icu/source/tools/toolutil/collationinfo.cpp",
|
||||
"/intl/icu/source/tools/toolutil/dbgutil.cpp",
|
||||
"/intl/icu/source/tools/toolutil/denseranges.cpp",
|
||||
"/intl/icu/source/tools/toolutil/filestrm.cpp",
|
||||
"/intl/icu/source/tools/toolutil/filetools.cpp",
|
||||
"/intl/icu/source/tools/toolutil/flagparser.cpp",
|
||||
"/intl/icu/source/tools/toolutil/package.cpp",
|
||||
"/intl/icu/source/tools/toolutil/pkg_genc.cpp",
|
||||
"/intl/icu/source/tools/toolutil/pkg_gencmn.cpp",
|
||||
"/intl/icu/source/tools/toolutil/pkg_icu.cpp",
|
||||
"/intl/icu/source/tools/toolutil/pkgitems.cpp",
|
||||
"/intl/icu/source/tools/toolutil/ppucd.cpp",
|
||||
"/intl/icu/source/tools/toolutil/swapimpl.cpp",
|
||||
"/intl/icu/source/tools/toolutil/toolutil.cpp",
|
||||
"/intl/icu/source/tools/toolutil/ucbuf.cpp",
|
||||
"/intl/icu/source/tools/toolutil/ucln_tu.cpp",
|
||||
"/intl/icu/source/tools/toolutil/ucm.cpp",
|
||||
"/intl/icu/source/tools/toolutil/ucmstate.cpp",
|
||||
"/intl/icu/source/tools/toolutil/udbgutil.cpp",
|
||||
"/intl/icu/source/tools/toolutil/unewdata.cpp",
|
||||
"/intl/icu/source/tools/toolutil/uoptions.cpp",
|
||||
"/intl/icu/source/tools/toolutil/uparse.cpp",
|
||||
"/intl/icu/source/tools/toolutil/writesrc.cpp",
|
||||
"/intl/icu/source/tools/toolutil/xmlparser.cpp",
|
||||
]
|
||||
|
|
|
@ -16,46 +16,45 @@
|
|||
# file a Core:XPCOM bug with a title like "STL: Review exception
|
||||
# safety of <foo> for gcc and MSVC".
|
||||
stl_headers = [
|
||||
'new',
|
||||
|
||||
"new",
|
||||
# FIXME: these headers haven't been reviewed yet, but we use them
|
||||
# unsafely in Gecko, so we might as well prevent them from
|
||||
# throwing exceptions
|
||||
'algorithm',
|
||||
'atomic',
|
||||
'cassert',
|
||||
'climits',
|
||||
'cmath',
|
||||
'condition_variable',
|
||||
'cstdarg',
|
||||
'cstdio',
|
||||
'cstdlib',
|
||||
'cstring',
|
||||
'cwchar',
|
||||
'deque',
|
||||
'functional',
|
||||
'ios',
|
||||
'iosfwd',
|
||||
'iostream',
|
||||
'istream',
|
||||
'iterator',
|
||||
'limits',
|
||||
'list',
|
||||
'map',
|
||||
'memory',
|
||||
'mutex',
|
||||
'ostream',
|
||||
'regex',
|
||||
'set',
|
||||
'shared_mutex',
|
||||
'stack',
|
||||
'string',
|
||||
'thread',
|
||||
'tuple',
|
||||
'type_traits',
|
||||
'unordered_map',
|
||||
'unordered_set',
|
||||
'utility',
|
||||
'vector',
|
||||
'xutility',
|
||||
"algorithm",
|
||||
"atomic",
|
||||
"cassert",
|
||||
"climits",
|
||||
"cmath",
|
||||
"condition_variable",
|
||||
"cstdarg",
|
||||
"cstdio",
|
||||
"cstdlib",
|
||||
"cstring",
|
||||
"cwchar",
|
||||
"deque",
|
||||
"functional",
|
||||
"ios",
|
||||
"iosfwd",
|
||||
"iostream",
|
||||
"istream",
|
||||
"iterator",
|
||||
"limits",
|
||||
"list",
|
||||
"map",
|
||||
"memory",
|
||||
"mutex",
|
||||
"ostream",
|
||||
"regex",
|
||||
"set",
|
||||
"shared_mutex",
|
||||
"stack",
|
||||
"string",
|
||||
"thread",
|
||||
"tuple",
|
||||
"type_traits",
|
||||
"unordered_map",
|
||||
"unordered_set",
|
||||
"utility",
|
||||
"vector",
|
||||
"xutility",
|
||||
]
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -82,6 +82,7 @@ declare namespace MockedExports {
|
|||
// Not all possible options are present, please add more if/when needed.
|
||||
userContextId: number;
|
||||
forceNonPrivate: boolean;
|
||||
relatedToCurrent: boolean;
|
||||
resolveOnContentBrowserCreated: (
|
||||
contentBrowser: ChromeBrowser
|
||||
) => unknown;
|
||||
|
|
|
@ -105,6 +105,7 @@ async function openProfilerTab(profilerViewMode) {
|
|||
forceNonPrivate: true,
|
||||
resolveOnContentBrowserCreated,
|
||||
userContextId: win.gBrowser?.contentPrincipal.userContextId,
|
||||
relatedToCurrent: true,
|
||||
})
|
||||
);
|
||||
return contentBrowser;
|
||||
|
|
|
@ -3,31 +3,34 @@
|
|||
# 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/.
|
||||
|
||||
|
||||
@template
|
||||
def CompiledModules(*modules):
|
||||
compiled_directory_whitelist = (
|
||||
"devtools/client/debugger/src",
|
||||
)
|
||||
compiled_directory_whitelist = ("devtools/client/debugger/src",)
|
||||
|
||||
if not RELATIVEDIR.startswith(compiled_directory_whitelist):
|
||||
error("File in directory provided to CompiledModules not allowed: " + RELATIVEDIR)
|
||||
if not RELATIVEDIR.startswith(compiled_directory_whitelist):
|
||||
error(
|
||||
"File in directory provided to CompiledModules not allowed: " + RELATIVEDIR
|
||||
)
|
||||
|
||||
# HACK. Template export() propagation is janky so we have to re-implement the
|
||||
# logic for computing FINAL_TARGET from scratch. Here we emulate the
|
||||
# DIST_SUBDIR export in devtools/moz.build.
|
||||
if CONFIG['MOZ_BUILD_APP'] == 'browser':
|
||||
final_target = '/dist/bin/browser'
|
||||
else:
|
||||
final_target = '/dist/bin'
|
||||
# HACK. Template export() propagation is janky so we have to re-implement the
|
||||
# logic for computing FINAL_TARGET from scratch. Here we emulate the
|
||||
# DIST_SUBDIR export in devtools/moz.build.
|
||||
if CONFIG["MOZ_BUILD_APP"] == "browser":
|
||||
final_target = "/dist/bin/browser"
|
||||
else:
|
||||
final_target = "/dist/bin"
|
||||
|
||||
final = '/'.join([final_target, 'chrome/devtools/modules', RELATIVEDIR])
|
||||
# For the same reason as https://searchfox.org/mozilla-central/source/mobile/android/base/moz.build#180-184
|
||||
# we have to insert a first entry as recursivemake overrides the first entry and we end up with empty files
|
||||
# for the first file only.
|
||||
GeneratedFile(
|
||||
"node.stub", *[final + '/' + module for module in modules],
|
||||
script='/python/mozbuild/mozbuild/action/node.py',
|
||||
entry_point='generate',
|
||||
inputs=['/devtools/client/shared/build/build.js'] +
|
||||
[module for module in modules],
|
||||
flags=['/'.join([TOPOBJDIR, final])])
|
||||
final = "/".join([final_target, "chrome/devtools/modules", RELATIVEDIR])
|
||||
# For the same reason as https://searchfox.org/mozilla-central/source/mobile/android/base/moz.build#180-184
|
||||
# we have to insert a first entry as recursivemake overrides the first entry and we end up with empty files
|
||||
# for the first file only.
|
||||
GeneratedFile(
|
||||
"node.stub",
|
||||
*[final + "/" + module for module in modules],
|
||||
script="/python/mozbuild/mozbuild/action/node.py",
|
||||
entry_point="generate",
|
||||
inputs=["/devtools/client/shared/build/build.js"]
|
||||
+ [module for module in modules],
|
||||
flags=["/".join([TOPOBJDIR, final])]
|
||||
)
|
||||
|
|
|
@ -4,9 +4,10 @@
|
|||
# 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/.
|
||||
|
||||
|
||||
@template
|
||||
def DevToolsModules(*modules):
|
||||
'''Installs JS modules at a resource:// path that corresponds directly to
|
||||
"""Installs JS modules at a resource:// path that corresponds directly to
|
||||
their source tree location.
|
||||
|
||||
For this to work as intended, a moz.build file should be placed in each
|
||||
|
@ -14,27 +15,30 @@ def DevToolsModules(*modules):
|
|||
its own directory. Subdirectories should use their own moz.build.
|
||||
|
||||
By following this pattern, there's less magic to require() and resource://
|
||||
paths, since they now match the source tree.'''
|
||||
paths, since they now match the source tree."""
|
||||
|
||||
for m in modules:
|
||||
if '/' in m:
|
||||
error('DevToolsModules must be used from the same directory as ' +
|
||||
'the files to be installed.')
|
||||
if "/" in m:
|
||||
error(
|
||||
"DevToolsModules must be used from the same directory as "
|
||||
+ "the files to be installed."
|
||||
)
|
||||
|
||||
# jar.mn manifest files are typically used to install files to chrome
|
||||
# locations. Instead of doing this, use this DevToolsModules syntax via
|
||||
# moz.build files to do the installation so that we can enforce correct
|
||||
# paths based on source tree location.
|
||||
base = FINAL_TARGET_FILES.chrome.devtools.modules
|
||||
for dir in RELATIVEDIR.split('/'):
|
||||
for dir in RELATIVEDIR.split("/"):
|
||||
base = base[dir]
|
||||
base += [m for m in modules]
|
||||
|
||||
|
||||
@template
|
||||
def RenamedDevToolsModules(source, target):
|
||||
''' Helper function to ship a file (source) with a distinct name (target).
|
||||
This will ship the file the same way DevToolsModule does it, to resource://devtools/'''
|
||||
"""Helper function to ship a file (source) with a distinct name (target).
|
||||
This will ship the file the same way DevToolsModule does it, to resource://devtools/
|
||||
"""
|
||||
|
||||
base = FINAL_TARGET_FILES.chrome.devtools.modules
|
||||
for dir in RELATIVEDIR.split("/"):
|
||||
|
|
|
@ -1394,6 +1394,7 @@ Document::Document(const char* aContentType)
|
|||
mHasUserInteractionTimerScheduled(false),
|
||||
mShouldResistFingerprinting(false),
|
||||
mCloningForSVGUse(false),
|
||||
mAllowDeclarativeShadowRoots(false),
|
||||
mXMLDeclarationBits(0),
|
||||
mOnloadBlockCount(0),
|
||||
mWriteLevel(0),
|
||||
|
@ -2428,6 +2429,8 @@ Document::~Document() {
|
|||
UnregisterFromMemoryReportingForDataDocument();
|
||||
}
|
||||
|
||||
void Document::DropStyleSet() { mStyleSet = nullptr; }
|
||||
|
||||
NS_INTERFACE_TABLE_HEAD(Document)
|
||||
NS_WRAPPERCACHE_INTERFACE_TABLE_ENTRY
|
||||
NS_INTERFACE_TABLE_BEGIN
|
||||
|
@ -11517,6 +11520,9 @@ void Document::Destroy() {
|
|||
if (mDocumentL10n) {
|
||||
mDocumentL10n->Destroy();
|
||||
}
|
||||
|
||||
MOZ_DIAGNOSTIC_ASSERT(!mPresShell);
|
||||
DropStyleSet();
|
||||
}
|
||||
|
||||
void Document::RemovedFromDocShell() {
|
||||
|
@ -14158,9 +14164,7 @@ class FullscreenRoots {
|
|||
MOZ_COUNTED_DEFAULT_CTOR(FullscreenRoots)
|
||||
MOZ_COUNTED_DTOR(FullscreenRoots)
|
||||
|
||||
enum : uint32_t { NotFound = uint32_t(-1) };
|
||||
// Looks in mRoots for aRoot. Returns the index if found, otherwise NotFound.
|
||||
static uint32_t Find(Document* aRoot);
|
||||
using RootsArray = nsTArray<WeakPtr<Document>>;
|
||||
|
||||
// Returns true if aRoot is in the list of fullscreen roots.
|
||||
static bool Contains(Document* aRoot);
|
||||
|
@ -14170,7 +14174,7 @@ class FullscreenRoots {
|
|||
static FullscreenRoots* sInstance;
|
||||
|
||||
// List of weak pointers to roots.
|
||||
nsTArray<nsWeakPtr> mRoots;
|
||||
RootsArray mRoots;
|
||||
};
|
||||
|
||||
FullscreenRoots* FullscreenRoots::sInstance = nullptr;
|
||||
|
@ -14182,10 +14186,10 @@ void FullscreenRoots::ForEach(void (*aFunction)(Document* aDoc)) {
|
|||
}
|
||||
// Create a copy of the roots array, and iterate over the copy. This is so
|
||||
// that if an element is removed from mRoots we don't mess up our iteration.
|
||||
nsTArray<nsWeakPtr> roots(sInstance->mRoots.Clone());
|
||||
RootsArray roots(sInstance->mRoots.Clone());
|
||||
// Call aFunction on all entries.
|
||||
for (uint32_t i = 0; i < roots.Length(); i++) {
|
||||
nsCOMPtr<Document> root = do_QueryReferent(roots[i]);
|
||||
nsCOMPtr<Document> root(roots[i]);
|
||||
// Check that the root isn't in the manager. This is so that new additions
|
||||
// while we were running don't get traversed.
|
||||
if (root && FullscreenRoots::Contains(root)) {
|
||||
|
@ -14196,7 +14200,7 @@ void FullscreenRoots::ForEach(void (*aFunction)(Document* aDoc)) {
|
|||
|
||||
/* static */
|
||||
bool FullscreenRoots::Contains(Document* aRoot) {
|
||||
return FullscreenRoots::Find(aRoot) != NotFound;
|
||||
return sInstance && sInstance->mRoots.Contains(aRoot);
|
||||
}
|
||||
|
||||
/* static */
|
||||
|
@ -14207,36 +14211,18 @@ void FullscreenRoots::Add(Document* aDoc) {
|
|||
if (!sInstance) {
|
||||
sInstance = new FullscreenRoots();
|
||||
}
|
||||
sInstance->mRoots.AppendElement(do_GetWeakReference(root));
|
||||
sInstance->mRoots.AppendElement(root);
|
||||
}
|
||||
}
|
||||
|
||||
/* static */
|
||||
uint32_t FullscreenRoots::Find(Document* aRoot) {
|
||||
if (!sInstance) {
|
||||
return NotFound;
|
||||
}
|
||||
nsTArray<nsWeakPtr>& roots = sInstance->mRoots;
|
||||
for (uint32_t i = 0; i < roots.Length(); i++) {
|
||||
nsCOMPtr<Document> otherRoot(do_QueryReferent(roots[i]));
|
||||
if (otherRoot == aRoot) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
return NotFound;
|
||||
}
|
||||
|
||||
/* static */
|
||||
void FullscreenRoots::Remove(Document* aDoc) {
|
||||
nsCOMPtr<Document> root =
|
||||
nsContentUtils::GetInProcessSubtreeRootDocument(aDoc);
|
||||
uint32_t index = Find(root);
|
||||
NS_ASSERTION(index != NotFound,
|
||||
"Should only try to remove roots which are still added!");
|
||||
if (index == NotFound || !sInstance) {
|
||||
if (!sInstance || !sInstance->mRoots.RemoveElement(root)) {
|
||||
NS_ERROR("Should only try to remove roots which are still added!");
|
||||
return;
|
||||
}
|
||||
sInstance->mRoots.RemoveElementAt(index);
|
||||
if (sInstance->mRoots.IsEmpty()) {
|
||||
delete sInstance;
|
||||
sInstance = nullptr;
|
||||
|
@ -14354,11 +14340,6 @@ class PendingFullscreenChangeList {
|
|||
/* static */
|
||||
LinkedList<FullscreenChange> PendingFullscreenChangeList::sList;
|
||||
|
||||
Document* Document::GetFullscreenRoot() {
|
||||
nsCOMPtr<Document> root = do_QueryReferent(mFullscreenRoot);
|
||||
return root;
|
||||
}
|
||||
|
||||
size_t Document::CountFullscreenElements() const {
|
||||
size_t count = 0;
|
||||
for (const nsWeakPtr& ptr : mTopLayer) {
|
||||
|
@ -14371,10 +14352,6 @@ size_t Document::CountFullscreenElements() const {
|
|||
return count;
|
||||
}
|
||||
|
||||
void Document::SetFullscreenRoot(Document* aRoot) {
|
||||
mFullscreenRoot = do_GetWeakReference(aRoot);
|
||||
}
|
||||
|
||||
// https://github.com/whatwg/html/issues/9143
|
||||
// We need to consider the precedence between active modal dialog, topmost auto
|
||||
// popover and fullscreen element once it's specified.
|
||||
|
@ -16962,7 +16939,7 @@ class UserInteractionTimer final : public Runnable,
|
|||
explicit UserInteractionTimer(Document* aDocument)
|
||||
: Runnable("UserInteractionTimer"),
|
||||
mPrincipal(aDocument->NodePrincipal()),
|
||||
mDocument(do_GetWeakReference(aDocument)) {
|
||||
mDocument(aDocument) {
|
||||
static int32_t userInteractionTimerId = 0;
|
||||
// Blocker names must be unique. Let's create it now because when needed,
|
||||
// the document could be already gone.
|
||||
|
@ -17039,7 +17016,7 @@ class UserInteractionTimer final : public Runnable,
|
|||
}
|
||||
|
||||
// If the document is not gone, let's reset its timer flag.
|
||||
nsCOMPtr<Document> document = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> document(mDocument);
|
||||
if (document) {
|
||||
ContentBlockingUserInteraction::Observe(mPrincipal);
|
||||
document->ResetUserInteractionTimer();
|
||||
|
@ -17067,7 +17044,7 @@ class UserInteractionTimer final : public Runnable,
|
|||
}
|
||||
|
||||
nsCOMPtr<nsIPrincipal> mPrincipal;
|
||||
nsWeakPtr mDocument;
|
||||
WeakPtr<Document> mDocument;
|
||||
|
||||
nsCOMPtr<nsITimer> mTimer;
|
||||
|
||||
|
@ -18988,4 +18965,41 @@ void Document::UpdateHiddenByContentVisibilityForAnimations() {
|
|||
timeline->UpdateHiddenByContentVisibility();
|
||||
}
|
||||
}
|
||||
|
||||
void Document::SetAllowDeclarativeShadowRoots(
|
||||
bool aAllowDeclarativeShadowRoots) {
|
||||
mAllowDeclarativeShadowRoots = aAllowDeclarativeShadowRoots;
|
||||
}
|
||||
|
||||
bool Document::AllowsDeclarativeShadowRoots() const {
|
||||
return mAllowDeclarativeShadowRoots;
|
||||
}
|
||||
|
||||
/* static */
|
||||
already_AddRefed<Document> Document::ParseHTMLUnsafe(GlobalObject& aGlobal,
|
||||
const nsAString& aHTML) {
|
||||
nsCOMPtr<nsIURI> uri;
|
||||
NS_NewURI(getter_AddRefs(uri), "about:blank");
|
||||
if (!uri) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
nsCOMPtr<Document> doc;
|
||||
nsresult rv =
|
||||
NS_NewHTMLDocument(getter_AddRefs(doc), aGlobal.GetSubjectPrincipal(),
|
||||
aGlobal.GetSubjectPrincipal());
|
||||
if (NS_WARN_IF(NS_FAILED(rv))) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
doc->SetAllowDeclarativeShadowRoots(true);
|
||||
doc->SetDocumentURI(uri);
|
||||
rv = nsContentUtils::ParseDocumentHTML(aHTML, doc, false);
|
||||
if (NS_WARN_IF(NS_FAILED(rv))) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return doc.forget();
|
||||
}
|
||||
|
||||
} // namespace mozilla::dom
|
||||
|
|
|
@ -1901,7 +1901,7 @@ class Document : public nsINode,
|
|||
* in the in-process document tree. Returns nullptr if the document isn't
|
||||
* fullscreen.
|
||||
*/
|
||||
Document* GetFullscreenRoot();
|
||||
Document* GetFullscreenRoot() const { return mFullscreenRoot; }
|
||||
|
||||
size_t CountFullscreenElements() const;
|
||||
|
||||
|
@ -1909,7 +1909,7 @@ class Document : public nsINode,
|
|||
* Sets the fullscreen root to aRoot. This stores a weak reference to aRoot
|
||||
* in this document.
|
||||
*/
|
||||
void SetFullscreenRoot(Document* aRoot);
|
||||
void SetFullscreenRoot(Document* aRoot) { mFullscreenRoot = aRoot; }
|
||||
|
||||
/**
|
||||
* Synchronously cleans up the fullscreen state on the given document.
|
||||
|
@ -3866,6 +3866,9 @@ class Document : public nsINode,
|
|||
*/
|
||||
bool AllowsL10n() const;
|
||||
|
||||
void SetAllowDeclarativeShadowRoots(bool aAllowDeclarativeShadowRoots);
|
||||
bool AllowsDeclarativeShadowRoots() const;
|
||||
|
||||
protected:
|
||||
RefPtr<DocumentL10n> mDocumentL10n;
|
||||
|
||||
|
@ -4094,6 +4097,8 @@ class Document : public nsINode,
|
|||
|
||||
bool MayHaveDOMActivateListeners() const;
|
||||
|
||||
void DropStyleSet();
|
||||
|
||||
protected:
|
||||
// Returns the WindowContext for the document that we will contribute
|
||||
// page use counters to.
|
||||
|
@ -4828,6 +4833,8 @@ class Document : public nsINode,
|
|||
// Whether we're cloning the contents of an SVG use element.
|
||||
bool mCloningForSVGUse : 1;
|
||||
|
||||
bool mAllowDeclarativeShadowRoots : 1;
|
||||
|
||||
// The fingerprinting protections overrides for this document. The value will
|
||||
// override the default enabled fingerprinting protections for this document.
|
||||
// This will only get populated if these is one that comes from the local
|
||||
|
@ -5133,7 +5140,7 @@ class Document : public nsINode,
|
|||
|
||||
// The root of the doc tree in which this document is in. This is only
|
||||
// non-null when this document is in fullscreen mode.
|
||||
nsWeakPtr mFullscreenRoot;
|
||||
WeakPtr<Document> mFullscreenRoot;
|
||||
|
||||
RefPtr<DOMImplementation> mDOMImplementation;
|
||||
|
||||
|
@ -5342,6 +5349,9 @@ class Document : public nsINode,
|
|||
void LoadEventFired();
|
||||
|
||||
RadioGroupContainer& OwnedRadioGroupContainer();
|
||||
|
||||
static already_AddRefed<Document> ParseHTMLUnsafe(GlobalObject& aGlobal,
|
||||
const nsAString& aHTML);
|
||||
};
|
||||
|
||||
NS_DEFINE_STATIC_IID_ACCESSOR(Document, NS_IDOCUMENT_IID)
|
||||
|
|
|
@ -1252,8 +1252,9 @@ bool Element::CanAttachShadowDOM() const {
|
|||
}
|
||||
|
||||
// https://dom.spec.whatwg.org/commit-snapshots/1eadf0a4a271acc92013d1c0de8c730ac96204f9/#dom-element-attachshadow
|
||||
already_AddRefed<ShadowRoot> Element::AttachShadow(const ShadowRootInit& aInit,
|
||||
ErrorResult& aError) {
|
||||
already_AddRefed<ShadowRoot> Element::AttachShadow(
|
||||
const ShadowRootInit& aInit, ErrorResult& aError,
|
||||
ShadowRootDeclarative aNewShadowIsDeclarative) {
|
||||
/**
|
||||
* Step 1, 2, and 3.
|
||||
*/
|
||||
|
@ -1263,25 +1264,41 @@ already_AddRefed<ShadowRoot> Element::AttachShadow(const ShadowRootInit& aInit,
|
|||
}
|
||||
|
||||
/**
|
||||
* 4. If this is a shadow host, then throw a "NotSupportedError" DOMException.
|
||||
* 4. If element is a shadow host, then:
|
||||
*/
|
||||
if (GetShadowRoot()) {
|
||||
aError.Throw(NS_ERROR_DOM_NOT_SUPPORTED_ERR);
|
||||
return nullptr;
|
||||
if (RefPtr<ShadowRoot> root = GetShadowRoot()) {
|
||||
/*
|
||||
* 1. If element’s shadow root’s declarative is false, then throw an
|
||||
* "NotSupportedError" DOMException.
|
||||
*/
|
||||
if (!root->IsDeclarative()) {
|
||||
aError.Throw(NS_ERROR_DOM_NOT_SUPPORTED_ERR);
|
||||
return nullptr;
|
||||
}
|
||||
// https://github.com/whatwg/dom/issues/1235
|
||||
root->SetIsDeclarative(aNewShadowIsDeclarative);
|
||||
/*
|
||||
* 2. Otherwise, remove all of element’s shadow root’s children, in tree
|
||||
* order, and return.
|
||||
*/
|
||||
root->ReplaceChildren(nullptr, aError);
|
||||
return root.forget();
|
||||
}
|
||||
|
||||
if (StaticPrefs::dom_webcomponents_shadowdom_report_usage()) {
|
||||
OwnerDoc()->ReportShadowDOMUsage();
|
||||
}
|
||||
|
||||
return AttachShadowWithoutNameChecks(aInit.mMode,
|
||||
DelegatesFocus(aInit.mDelegatesFocus),
|
||||
aInit.mSlotAssignment);
|
||||
return AttachShadowWithoutNameChecks(
|
||||
aInit.mMode, DelegatesFocus(aInit.mDelegatesFocus), aInit.mSlotAssignment,
|
||||
ShadowRootClonable(aInit.mClonable),
|
||||
ShadowRootDeclarative(aNewShadowIsDeclarative));
|
||||
}
|
||||
|
||||
already_AddRefed<ShadowRoot> Element::AttachShadowWithoutNameChecks(
|
||||
ShadowRootMode aMode, DelegatesFocus aDelegatesFocus,
|
||||
SlotAssignmentMode aSlotAssignment) {
|
||||
SlotAssignmentMode aSlotAssignment, ShadowRootClonable aClonable,
|
||||
ShadowRootDeclarative aDeclarative) {
|
||||
nsAutoScriptBlocker scriptBlocker;
|
||||
|
||||
auto* nim = mNodeInfo->NodeInfoManager();
|
||||
|
@ -1305,8 +1322,9 @@ already_AddRefed<ShadowRoot> Element::AttachShadowWithoutNameChecks(
|
|||
* context object's node document, host is context object,
|
||||
* and mode is init's mode.
|
||||
*/
|
||||
RefPtr<ShadowRoot> shadowRoot = new (nim) ShadowRoot(
|
||||
this, aMode, aDelegatesFocus, aSlotAssignment, nodeInfo.forget());
|
||||
RefPtr<ShadowRoot> shadowRoot =
|
||||
new (nim) ShadowRoot(this, aMode, aDelegatesFocus, aSlotAssignment,
|
||||
aClonable, aDeclarative, nodeInfo.forget());
|
||||
|
||||
if (NodeOrAncestorHasDirAuto()) {
|
||||
shadowRoot->SetAncestorHasDirAuto();
|
||||
|
@ -5027,4 +5045,8 @@ EditorBase* Element::GetEditorWithoutCreation() const {
|
|||
return docShell ? docShell->GetHTMLEditorInternal() : nullptr;
|
||||
}
|
||||
|
||||
void Element::SetHTMLUnsafe(const nsAString& aHTML) {
|
||||
nsContentUtils::SetHTMLUnsafe(this, this, aHTML);
|
||||
}
|
||||
|
||||
} // namespace mozilla::dom
|
||||
|
|
|
@ -1320,15 +1320,23 @@ class Element : public FragmentOrElement {
|
|||
bool ParseLoadingAttribute(const nsAString& aValue, nsAttrValue& aResult);
|
||||
|
||||
// Shadow DOM v1
|
||||
already_AddRefed<ShadowRoot> AttachShadow(const ShadowRootInit& aInit,
|
||||
ErrorResult& aError);
|
||||
enum class ShadowRootDeclarative : bool { No, Yes };
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT_BOUNDARY
|
||||
already_AddRefed<ShadowRoot> AttachShadow(
|
||||
const ShadowRootInit& aInit, ErrorResult& aError,
|
||||
ShadowRootDeclarative aNewShadowIsDeclarative =
|
||||
ShadowRootDeclarative::No);
|
||||
bool CanAttachShadowDOM() const;
|
||||
|
||||
enum class DelegatesFocus : bool { No, Yes };
|
||||
enum class ShadowRootClonable : bool { No, Yes };
|
||||
|
||||
already_AddRefed<ShadowRoot> AttachShadowWithoutNameChecks(
|
||||
ShadowRootMode aMode, DelegatesFocus = DelegatesFocus::No,
|
||||
SlotAssignmentMode aSlotAssignmentMode = SlotAssignmentMode::Named);
|
||||
SlotAssignmentMode aSlotAssignmentMode = SlotAssignmentMode::Named,
|
||||
ShadowRootClonable aClonable = ShadowRootClonable::No,
|
||||
ShadowRootDeclarative aDeclarative = ShadowRootDeclarative::No);
|
||||
|
||||
// Attach UA Shadow Root if it is not attached.
|
||||
enum class NotifyUAWidgetSetup : bool { No, Yes };
|
||||
|
@ -2079,6 +2087,9 @@ class Element : public FragmentOrElement {
|
|||
|
||||
virtual bool Translate() const;
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT
|
||||
virtual void SetHTMLUnsafe(const nsAString& aHTML);
|
||||
|
||||
protected:
|
||||
enum class ReparseAttributes { No, Yes };
|
||||
/**
|
||||
|
|
|
@ -680,10 +680,8 @@ namespace {
|
|||
|
||||
class VibrateWindowListener : public nsIDOMEventListener {
|
||||
public:
|
||||
VibrateWindowListener(nsPIDOMWindowInner* aWindow, Document* aDocument) {
|
||||
mWindow = do_GetWeakReference(aWindow);
|
||||
mDocument = do_GetWeakReference(aDocument);
|
||||
|
||||
VibrateWindowListener(nsPIDOMWindowInner* aWindow, Document* aDocument)
|
||||
: mWindow(do_GetWeakReference(aWindow)), mDocument(aDocument) {
|
||||
constexpr auto visibilitychange = u"visibilitychange"_ns;
|
||||
aDocument->AddSystemEventListener(visibilitychange, this, /* listener */
|
||||
true, /* use capture */
|
||||
|
@ -699,7 +697,7 @@ class VibrateWindowListener : public nsIDOMEventListener {
|
|||
virtual ~VibrateWindowListener() = default;
|
||||
|
||||
nsWeakPtr mWindow;
|
||||
nsWeakPtr mDocument;
|
||||
WeakPtr<Document> mDocument;
|
||||
};
|
||||
|
||||
NS_IMPL_ISUPPORTS(VibrateWindowListener, nsIDOMEventListener)
|
||||
|
@ -731,7 +729,7 @@ VibrateWindowListener::HandleEvent(Event* aEvent) {
|
|||
}
|
||||
|
||||
void VibrateWindowListener::RemoveListener() {
|
||||
nsCOMPtr<EventTarget> target = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> target(mDocument);
|
||||
if (!target) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -51,7 +51,8 @@ NS_IMPL_RELEASE_INHERITED(ShadowRoot, DocumentFragment)
|
|||
|
||||
ShadowRoot::ShadowRoot(Element* aElement, ShadowRootMode aMode,
|
||||
Element::DelegatesFocus aDelegatesFocus,
|
||||
SlotAssignmentMode aSlotAssignment,
|
||||
SlotAssignmentMode aSlotAssignment, Clonable aIsClonable,
|
||||
Declarative aDeclarative,
|
||||
already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
|
||||
: DocumentFragment(std::move(aNodeInfo)),
|
||||
DocumentOrShadowRoot(this),
|
||||
|
@ -59,7 +60,9 @@ ShadowRoot::ShadowRoot(Element* aElement, ShadowRootMode aMode,
|
|||
mDelegatesFocus(aDelegatesFocus),
|
||||
mSlotAssignment(aSlotAssignment),
|
||||
mIsDetailsShadowTree(aElement->IsHTMLElement(nsGkAtoms::details)),
|
||||
mIsAvailableToElementInternals(false) {
|
||||
mIsAvailableToElementInternals(false),
|
||||
mIsDeclarative(aDeclarative),
|
||||
mIsClonable(aIsClonable) {
|
||||
// nsINode.h relies on this.
|
||||
MOZ_ASSERT(static_cast<nsINode*>(this) == reinterpret_cast<nsINode*>(this));
|
||||
MOZ_ASSERT(static_cast<nsIContent*>(this) ==
|
||||
|
@ -874,3 +877,8 @@ nsresult ShadowRoot::Clone(dom::NodeInfo* aNodeInfo, nsINode** aResult) const {
|
|||
*aResult = nullptr;
|
||||
return NS_ERROR_DOM_NOT_SUPPORTED_ERR;
|
||||
}
|
||||
|
||||
void ShadowRoot::SetHTMLUnsafe(const nsAString& aHTML) {
|
||||
RefPtr<Element> host = GetHost();
|
||||
nsContentUtils::SetHTMLUnsafe(this, host, aHTML);
|
||||
}
|
||||
|
|
|
@ -42,6 +42,9 @@ class HTMLInputElement;
|
|||
class ShadowRoot final : public DocumentFragment, public DocumentOrShadowRoot {
|
||||
friend class DocumentOrShadowRoot;
|
||||
|
||||
using Declarative = Element::ShadowRootDeclarative;
|
||||
using Clonable = Element::ShadowRootClonable;
|
||||
|
||||
public:
|
||||
NS_IMPL_FROMNODE_HELPER(ShadowRoot, IsShadowRoot());
|
||||
|
||||
|
@ -50,7 +53,8 @@ class ShadowRoot final : public DocumentFragment, public DocumentOrShadowRoot {
|
|||
|
||||
ShadowRoot(Element* aElement, ShadowRootMode aMode,
|
||||
Element::DelegatesFocus aDelegatesFocus,
|
||||
SlotAssignmentMode aSlotAssignment,
|
||||
SlotAssignmentMode aSlotAssignment, Clonable aClonable,
|
||||
Declarative aDeclarative,
|
||||
already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
|
||||
|
||||
void AddSizeOfExcludingThis(nsWindowSizes&, size_t* aNodeSize) const final;
|
||||
|
@ -231,6 +235,19 @@ class ShadowRoot final : public DocumentFragment, public DocumentOrShadowRoot {
|
|||
|
||||
void GetEventTargetParent(EventChainPreVisitor& aVisitor) override;
|
||||
|
||||
bool IsDeclarative() const { return mIsDeclarative == Declarative::Yes; }
|
||||
void SetIsDeclarative(Declarative aIsDeclarative) {
|
||||
mIsDeclarative = aIsDeclarative;
|
||||
}
|
||||
void SetIsDeclarative(bool aIsDeclarative) {
|
||||
mIsDeclarative = aIsDeclarative ? Declarative::Yes : Declarative::No;
|
||||
}
|
||||
|
||||
bool IsClonable() const { return mIsClonable == Clonable::Yes; }
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT
|
||||
void SetHTMLUnsafe(const nsAString& aHTML);
|
||||
|
||||
protected:
|
||||
// FIXME(emilio): This will need to become more fine-grained.
|
||||
void ApplicableRulesChanged();
|
||||
|
@ -268,6 +285,12 @@ class ShadowRoot final : public DocumentFragment, public DocumentOrShadowRoot {
|
|||
// https://dom.spec.whatwg.org/#shadowroot-available-to-element-internals
|
||||
bool mIsAvailableToElementInternals : 1;
|
||||
|
||||
// https://dom.spec.whatwg.org/#shadowroot-declarative
|
||||
Declarative mIsDeclarative;
|
||||
|
||||
// https://dom.spec.whatwg.org/#shadowroot-clonable
|
||||
Clonable mIsClonable;
|
||||
|
||||
nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
|
||||
};
|
||||
|
||||
|
|
|
@ -5436,14 +5436,31 @@ uint32_t computeSanitizationFlags(nsIPrincipal* aPrincipal, int32_t aFlags) {
|
|||
}
|
||||
|
||||
/* static */
|
||||
bool AllowsUnsanitizedContentForAboutNewTab(nsIPrincipal* aPrincipal) {
|
||||
if (StaticPrefs::dom_about_newtab_sanitization_enabled() ||
|
||||
!aPrincipal->SchemeIs("about")) {
|
||||
return false;
|
||||
void nsContentUtils::SetHTMLUnsafe(FragmentOrElement* aTarget,
|
||||
Element* aContext,
|
||||
const nsAString& aSource) {
|
||||
MOZ_ASSERT(!sFragmentParsingActive, "Re-entrant fragment parsing attempted.");
|
||||
mozilla::AutoRestore<bool> guard(sFragmentParsingActive);
|
||||
sFragmentParsingActive = true;
|
||||
if (!sHTMLFragmentParser) {
|
||||
NS_ADDREF(sHTMLFragmentParser = new nsHtml5StringParser());
|
||||
// Now sHTMLFragmentParser owns the object
|
||||
}
|
||||
uint32_t aboutModuleFlags = 0;
|
||||
aPrincipal->GetAboutModuleFlags(&aboutModuleFlags);
|
||||
return aboutModuleFlags & nsIAboutModule::ALLOW_UNSANITIZED_CONTENT;
|
||||
|
||||
nsAtom* contextLocalName = aContext->NodeInfo()->NameAtom();
|
||||
int32_t contextNameSpaceID = aContext->GetNameSpaceID();
|
||||
|
||||
RefPtr<Document> doc = aTarget->OwnerDoc();
|
||||
RefPtr<DocumentFragment> fragment = doc->CreateDocumentFragment();
|
||||
nsresult rv = sHTMLFragmentParser->ParseFragment(
|
||||
aSource, fragment, contextLocalName, contextNameSpaceID,
|
||||
fragment->OwnerDoc()->GetCompatibilityMode() == eCompatibility_NavQuirks,
|
||||
true, true);
|
||||
if (NS_FAILED(rv)) {
|
||||
NS_WARNING("Failed to parse fragment for SetHTMLUnsafe");
|
||||
}
|
||||
|
||||
aTarget->ReplaceChildren(fragment, IgnoreErrors());
|
||||
}
|
||||
|
||||
/* static */
|
||||
|
@ -5486,8 +5503,7 @@ nsresult nsContentUtils::ParseFragmentHTML(
|
|||
// an about: scheme principal.
|
||||
bool shouldSanitize = nodePrincipal->IsSystemPrincipal() ||
|
||||
nodePrincipal->SchemeIs("about") || aFlags >= 0;
|
||||
if (shouldSanitize &&
|
||||
!AllowsUnsanitizedContentForAboutNewTab(nodePrincipal)) {
|
||||
if (shouldSanitize) {
|
||||
if (!doc->IsLoadedAsData()) {
|
||||
doc = nsContentUtils::CreateInertHTMLDocument(doc);
|
||||
if (!doc) {
|
||||
|
@ -5501,7 +5517,7 @@ nsresult nsContentUtils::ParseFragmentHTML(
|
|||
|
||||
nsresult rv = sHTMLFragmentParser->ParseFragment(
|
||||
aSourceBuffer, target, aContextLocalName, aContextNamespace, aQuirks,
|
||||
aPreventScriptExecution);
|
||||
aPreventScriptExecution, false);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
if (fragment) {
|
||||
|
@ -11339,6 +11355,25 @@ template bool nsContentUtils::AddElementToListByTreeOrder(
|
|||
nsTArray<RefPtr<HTMLInputElement>>& aList, HTMLInputElement* aChild,
|
||||
nsIContent* aAncestor);
|
||||
|
||||
nsIContent* nsContentUtils::AttachDeclarativeShadowRoot(nsIContent* aHost,
|
||||
ShadowRootMode aMode,
|
||||
bool aDelegatesFocus) {
|
||||
RefPtr<Element> host = mozilla::dom::Element::FromNodeOrNull(aHost);
|
||||
if (!host) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
ShadowRootInit init;
|
||||
init.mMode = aMode;
|
||||
init.mDelegatesFocus = aDelegatesFocus;
|
||||
init.mSlotAssignment = SlotAssignmentMode::Named;
|
||||
init.mClonable = true;
|
||||
|
||||
RefPtr shadowRoot = host->AttachShadow(init, IgnoreErrors(),
|
||||
Element::ShadowRootDeclarative::Yes);
|
||||
return shadowRoot;
|
||||
}
|
||||
|
||||
namespace mozilla {
|
||||
std::ostream& operator<<(std::ostream& aOut,
|
||||
const PreventDefaultResult aPreventDefaultResult) {
|
||||
|
|
|
@ -176,6 +176,7 @@ class DOMArena;
|
|||
class Element;
|
||||
class Event;
|
||||
class EventTarget;
|
||||
class FragmentOrElement;
|
||||
class HTMLElement;
|
||||
class HTMLInputElement;
|
||||
class IPCTransferable;
|
||||
|
@ -187,6 +188,7 @@ class MessageBroadcaster;
|
|||
class NodeInfo;
|
||||
class OwningFileOrUSVStringOrFormData;
|
||||
class Selection;
|
||||
enum class ShadowRootMode : uint8_t;
|
||||
struct StructuredSerializeOptions;
|
||||
class WorkerPrivate;
|
||||
enum class ElementCallbackType;
|
||||
|
@ -1802,6 +1804,9 @@ class nsContentUtils {
|
|||
bool aPreventScriptExecution,
|
||||
mozilla::ErrorResult& aRv);
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT
|
||||
static void SetHTMLUnsafe(mozilla::dom::FragmentOrElement* aTarget,
|
||||
Element* aContext, const nsAString& aSource);
|
||||
/**
|
||||
* Invoke the fragment parsing algorithm (innerHTML) using the HTML parser.
|
||||
*
|
||||
|
@ -3457,6 +3462,11 @@ class nsContentUtils {
|
|||
nsIContent* aContent2,
|
||||
const nsIContent* aCommonAncestor);
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT_BOUNDARY
|
||||
static nsIContent* AttachDeclarativeShadowRoot(
|
||||
nsIContent* aHost, mozilla::dom::ShadowRootMode aMode,
|
||||
bool aDelegatesFocus);
|
||||
|
||||
private:
|
||||
static bool InitializeEventTable();
|
||||
|
||||
|
|
|
@ -6721,21 +6721,20 @@ void nsGlobalWindowInner::AddSizeOfIncludingThis(
|
|||
void nsGlobalWindowInner::RegisterDataDocumentForMemoryReporting(
|
||||
Document* aDocument) {
|
||||
aDocument->SetAddedToMemoryReportAsDataDocument();
|
||||
mDataDocumentsForMemoryReporting.AppendElement(
|
||||
do_GetWeakReference(aDocument));
|
||||
mDataDocumentsForMemoryReporting.AppendElement(aDocument);
|
||||
}
|
||||
|
||||
void nsGlobalWindowInner::UnregisterDataDocumentForMemoryReporting(
|
||||
Document* aDocument) {
|
||||
nsWeakPtr doc = do_GetWeakReference(aDocument);
|
||||
MOZ_ASSERT(mDataDocumentsForMemoryReporting.Contains(doc));
|
||||
mDataDocumentsForMemoryReporting.RemoveElement(doc);
|
||||
DebugOnly<bool> found =
|
||||
mDataDocumentsForMemoryReporting.RemoveElement(aDocument);
|
||||
MOZ_ASSERT(found);
|
||||
}
|
||||
|
||||
void nsGlobalWindowInner::CollectDOMSizesForDataDocuments(
|
||||
nsWindowSizes& aSize) const {
|
||||
for (const nsWeakPtr& ptr : mDataDocumentsForMemoryReporting) {
|
||||
if (nsCOMPtr<Document> doc = do_QueryReferent(ptr)) {
|
||||
for (Document* doc : mDataDocumentsForMemoryReporting) {
|
||||
if (doc) {
|
||||
doc->DocAddSizeOfIncludingThis(aSize);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
|
||||
// Local Includes
|
||||
// Helper Classes
|
||||
#include "mozilla/WeakPtr.h"
|
||||
#include "nsCOMPtr.h"
|
||||
#include "nsWeakReference.h"
|
||||
#include "nsTHashMap.h"
|
||||
|
@ -1446,7 +1447,7 @@ class nsGlobalWindowInner final : public mozilla::dom::EventTarget,
|
|||
|
||||
nsTArray<uint32_t> mScrollMarks;
|
||||
|
||||
nsTArray<nsWeakPtr> mDataDocumentsForMemoryReporting;
|
||||
nsTArray<mozilla::WeakPtr<Document>> mDataDocumentsForMemoryReporting;
|
||||
|
||||
static InnerWindowByIdTable* sInnerWindowsById;
|
||||
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
#include "mozilla/dom/DebuggerNotificationBinding.h"
|
||||
#include "mozilla/dom/DocumentType.h"
|
||||
#include "mozilla/dom/Element.h"
|
||||
#include "mozilla/dom/ElementBinding.h"
|
||||
#include "mozilla/dom/Event.h"
|
||||
#include "mozilla/dom/Exceptions.h"
|
||||
#include "mozilla/dom/Link.h"
|
||||
|
@ -714,6 +715,8 @@ void nsINode::LastRelease() {
|
|||
// properties are bound to nsINode objects and the destructor functions of
|
||||
// the properties may want to use the owner document of the nsINode.
|
||||
AsDocument()->RemoveAllProperties();
|
||||
|
||||
AsDocument()->DropStyleSet();
|
||||
} else {
|
||||
if (HasProperties()) {
|
||||
// Strong reference to the document so that deleting properties can't
|
||||
|
@ -3618,6 +3621,38 @@ already_AddRefed<nsINode> nsINode::CloneAndAdopt(
|
|||
}
|
||||
}
|
||||
|
||||
if (aClone && aNode->IsElement() &&
|
||||
!nodeInfo->GetDocument()->IsStaticDocument()) {
|
||||
// Clone the Shadow DOM
|
||||
ShadowRoot* originalShadowRoot = aNode->AsElement()->GetShadowRoot();
|
||||
if (originalShadowRoot && originalShadowRoot->IsClonable()) {
|
||||
ShadowRootInit init;
|
||||
init.mMode = originalShadowRoot->Mode();
|
||||
init.mDelegatesFocus = originalShadowRoot->DelegatesFocus();
|
||||
init.mSlotAssignment = originalShadowRoot->SlotAssignment();
|
||||
init.mClonable = true;
|
||||
|
||||
RefPtr<ShadowRoot> newShadowRoot =
|
||||
clone->AsElement()->AttachShadow(init, aError);
|
||||
if (NS_WARN_IF(aError.Failed())) {
|
||||
return nullptr;
|
||||
}
|
||||
newShadowRoot->SetIsDeclarative(originalShadowRoot->IsDeclarative());
|
||||
|
||||
if (aDeep) {
|
||||
for (nsIContent* origChild = originalShadowRoot->GetFirstChild();
|
||||
origChild; origChild = origChild->GetNextSibling()) {
|
||||
nsCOMPtr<nsINode> child =
|
||||
CloneAndAdopt(origChild, aClone, aDeep, nodeInfoManager,
|
||||
aReparentScope, newShadowRoot, aError);
|
||||
if (NS_WARN_IF(aError.Failed())) {
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Cloning template element.
|
||||
if (aDeep && aClone && aNode->IsTemplateElement()) {
|
||||
DocumentFragment* origContent =
|
||||
|
|
|
@ -93,11 +93,6 @@ class nsJSUtils {
|
|||
mozilla::UniquePtr<uint8_t[], JS::FreePolicy> aBuffer);
|
||||
};
|
||||
|
||||
inline void AssignFromStringBuffer(nsStringBuffer* buffer, size_t len,
|
||||
nsAString& dest) {
|
||||
buffer->ToString(len, dest);
|
||||
}
|
||||
|
||||
template <typename T, typename std::enable_if_t<std::is_same<
|
||||
typename T::char_type, char16_t>::value>* = nullptr>
|
||||
inline bool AssignJSString(JSContext* cx, T& dest, JSString* s) {
|
||||
|
@ -105,20 +100,7 @@ inline bool AssignJSString(JSContext* cx, T& dest, JSString* s) {
|
|||
static_assert(JS::MaxStringLength < (1 << 30),
|
||||
"Shouldn't overflow here or in SetCapacity");
|
||||
|
||||
const char16_t* chars;
|
||||
if (XPCStringConvert::MaybeGetDOMStringChars(s, &chars)) {
|
||||
// The characters represent an existing string buffer that we shared with
|
||||
// JS. We can share that buffer ourselves if the string corresponds to the
|
||||
// whole buffer; otherwise we have to copy.
|
||||
if (chars[len] == '\0') {
|
||||
AssignFromStringBuffer(
|
||||
nsStringBuffer::FromData(const_cast<char16_t*>(chars)), len, dest);
|
||||
return true;
|
||||
}
|
||||
} else if (XPCStringConvert::MaybeGetLiteralStringChars(s, &chars)) {
|
||||
// The characters represent a literal char16_t string constant
|
||||
// compiled into libxul; we can just use it as-is.
|
||||
dest.AssignLiteral(chars, len);
|
||||
if (XPCStringConvert::MaybeAssignUCStringChars(s, len, dest)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -2702,17 +2702,6 @@ void ConstructJSImplementation(const char* aContractId,
|
|||
}
|
||||
}
|
||||
|
||||
bool NonVoidByteStringToJsval(JSContext* cx, const nsACString& str,
|
||||
JS::MutableHandle<JS::Value> rval) {
|
||||
// ByteStrings are not UTF-8 encoded.
|
||||
JSString* jsStr = JS_NewStringCopyN(cx, str.Data(), str.Length());
|
||||
if (!jsStr) {
|
||||
return false;
|
||||
}
|
||||
rval.setString(jsStr);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool NormalizeUSVString(nsAString& aString) {
|
||||
return EnsureUTF16Validity(aString);
|
||||
}
|
||||
|
@ -2745,6 +2734,11 @@ bool ConvertJSValueToByteString(BindingCallContext& cx, JS::Handle<JS::Value> v,
|
|||
JS::Rooted<JSString*> s(cx);
|
||||
if (v.isString()) {
|
||||
s = v.toString();
|
||||
|
||||
size_t length = JS::GetStringLength(s);
|
||||
if (XPCStringConvert::MaybeAssignLatin1StringChars(s, length, result)) {
|
||||
return true;
|
||||
}
|
||||
} else {
|
||||
if (nullable && v.isNullOrUndefined()) {
|
||||
result.SetIsVoid(true);
|
||||
|
|
|
@ -2568,8 +2568,10 @@ already_AddRefed<T> ConstructJSImplementation(const char* aContractId,
|
|||
* As such, the string is not UTF-8 encoded. Any UTF8 strings passed to these
|
||||
* methods will be mangled.
|
||||
*/
|
||||
bool NonVoidByteStringToJsval(JSContext* cx, const nsACString& str,
|
||||
JS::MutableHandle<JS::Value> rval);
|
||||
inline bool NonVoidByteStringToJsval(JSContext* cx, const nsACString& str,
|
||||
JS::MutableHandle<JS::Value> rval) {
|
||||
return xpc::NonVoidLatin1StringToJsval(cx, str, rval);
|
||||
}
|
||||
inline bool ByteStringToJsval(JSContext* cx, const nsACString& str,
|
||||
JS::MutableHandle<JS::Value> rval) {
|
||||
if (str.IsVoid()) {
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include "js/RootingAPI.h" // JS::Rooted
|
||||
#include "js/ScalarType.h" // JS::Scalar::Type
|
||||
#include "js/SharedArrayBuffer.h"
|
||||
#include "js/friend/ErrorMessages.h"
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/Buffer.h"
|
||||
#include "mozilla/ErrorResult.h"
|
||||
|
@ -673,15 +674,36 @@ struct TypedArray_base : public SpiderMonkeyInterfaceObjectStorage,
|
|||
if (!JS::IsArrayBufferViewShared(view)) {
|
||||
JSAutoRealm ar(jsapi.cx(), view);
|
||||
bool unused;
|
||||
JSObject* buffer =
|
||||
JS_GetArrayBufferViewBuffer(jsapi.cx(), view, &unused);
|
||||
if (!buffer) {
|
||||
bool noBuffer;
|
||||
{
|
||||
JSObject* buffer =
|
||||
JS_GetArrayBufferViewBuffer(jsapi.cx(), view, &unused);
|
||||
noBuffer = !buffer;
|
||||
}
|
||||
if (noBuffer) {
|
||||
if (JS_IsTypedArrayObject(view)) {
|
||||
JS::Value bufferSlot =
|
||||
JS::GetReservedSlot(view, /* BUFFER_SLOT */ 0);
|
||||
if (bufferSlot.isNull()) {
|
||||
MOZ_CRASH("TypedArrayObject with bufferSlot containing null");
|
||||
} else if (bufferSlot.isBoolean()) {
|
||||
// If we're here then TypedArrayObject::ensureHasBuffer must have
|
||||
// failed in the call to JS_GetArrayBufferViewBuffer.
|
||||
if (JS_IsThrowingOutOfMemory(jsapi.cx())) {
|
||||
MOZ_CRASH("We did run out of memory!");
|
||||
} else if (JS_IsExceptionPending(jsapi.cx())) {
|
||||
JS::Rooted<JS::Value> exn(jsapi.cx());
|
||||
if (JS_GetPendingException(jsapi.cx(), &exn) &&
|
||||
exn.isObject()) {
|
||||
JS::Rooted<JSObject*> exnObj(jsapi.cx(), &exn.toObject());
|
||||
JSErrorReport* err =
|
||||
JS_ErrorFromException(jsapi.cx(), exnObj);
|
||||
if (err && err->errorNumber == JSMSG_BAD_ARRAY_LENGTH) {
|
||||
MOZ_CRASH("Length was too big");
|
||||
}
|
||||
}
|
||||
}
|
||||
// Did ArrayBufferObject::createBufferAndData fail without OOM?
|
||||
MOZ_CRASH("TypedArrayObject with bufferSlot containing boolean");
|
||||
} else if (bufferSlot.isObject()) {
|
||||
if (!bufferSlot.toObjectOrNull()) {
|
||||
|
@ -700,13 +722,6 @@ struct TypedArray_base : public SpiderMonkeyInterfaceObjectStorage,
|
|||
MOZ_CRASH("JS_GetArrayBufferViewBuffer failed for DataViewObject");
|
||||
}
|
||||
}
|
||||
|
||||
if (!JS::IsDetachedArrayBufferObject(buffer)) {
|
||||
if (!JS::PinArrayBufferOrViewLength(buffer, true)) {
|
||||
MOZ_CRASH("Length was pinned already!");
|
||||
}
|
||||
JS::PinArrayBufferOrViewLength(buffer, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -8,6 +8,9 @@
|
|||
#include "mozilla/dom/HTMLTemplateElementBinding.h"
|
||||
|
||||
#include "mozilla/dom/Document.h"
|
||||
#include "mozilla/dom/NameSpaceConstants.h"
|
||||
#include "mozilla/dom/ShadowRootBinding.h"
|
||||
#include "nsGenericHTMLElement.h"
|
||||
#include "nsGkAtoms.h"
|
||||
#include "nsStyleConsts.h"
|
||||
#include "nsAtom.h"
|
||||
|
@ -16,6 +19,13 @@ NS_IMPL_NS_NEW_HTML_ELEMENT(Template)
|
|||
|
||||
namespace mozilla::dom {
|
||||
|
||||
static constexpr nsAttrValue::EnumTable kShadowRootModeTable[] = {
|
||||
{"open", ShadowRootMode::Open},
|
||||
{"closed", ShadowRootMode::Closed},
|
||||
{nullptr, {}}};
|
||||
|
||||
const nsAttrValue::EnumTable* kShadowRootModeDefault = &kShadowRootModeTable[2];
|
||||
|
||||
HTMLTemplateElement::HTMLTemplateElement(
|
||||
already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
|
||||
: nsGenericHTMLElement(std::move(aNodeInfo)) {
|
||||
|
@ -31,7 +41,7 @@ HTMLTemplateElement::HTMLTemplateElement(
|
|||
}
|
||||
|
||||
HTMLTemplateElement::~HTMLTemplateElement() {
|
||||
if (mContent) {
|
||||
if (mContent && mContent->GetHost() == this) {
|
||||
mContent->SetHost(nullptr);
|
||||
}
|
||||
}
|
||||
|
@ -44,7 +54,9 @@ NS_IMPL_CYCLE_COLLECTION_CLASS(HTMLTemplateElement)
|
|||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(HTMLTemplateElement,
|
||||
nsGenericHTMLElement)
|
||||
if (tmp->mContent) {
|
||||
tmp->mContent->SetHost(nullptr);
|
||||
if (tmp->mContent->GetHost() == tmp) {
|
||||
tmp->mContent->SetHost(nullptr);
|
||||
}
|
||||
tmp->mContent = nullptr;
|
||||
}
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
|
||||
|
@ -61,4 +73,38 @@ JSObject* HTMLTemplateElement::WrapNode(JSContext* aCx,
|
|||
return HTMLTemplateElement_Binding::Wrap(aCx, this, aGivenProto);
|
||||
}
|
||||
|
||||
void HTMLTemplateElement::AfterSetAttr(int32_t aNamespaceID, nsAtom* aName,
|
||||
const nsAttrValue* aValue,
|
||||
const nsAttrValue* aOldValue,
|
||||
nsIPrincipal* aMaybeScriptedPrincipal,
|
||||
bool aNotify) {
|
||||
if (aNamespaceID == kNameSpaceID_None && aName == nsGkAtoms::shadowrootmode &&
|
||||
aValue && aValue->Type() == nsAttrValue::ValueType::eEnum &&
|
||||
!mShadowRootMode.isSome()) {
|
||||
mShadowRootMode.emplace(
|
||||
static_cast<ShadowRootMode>(aValue->GetEnumValue()));
|
||||
}
|
||||
|
||||
nsGenericHTMLElement::AfterSetAttr(aNamespaceID, aName, aValue, aOldValue,
|
||||
aMaybeScriptedPrincipal, aNotify);
|
||||
}
|
||||
|
||||
bool HTMLTemplateElement::ParseAttribute(int32_t aNamespaceID,
|
||||
nsAtom* aAttribute,
|
||||
const nsAString& aValue,
|
||||
nsIPrincipal* aMaybeScriptedPrincipal,
|
||||
nsAttrValue& aResult) {
|
||||
if (aNamespaceID == kNameSpaceID_None &&
|
||||
aAttribute == nsGkAtoms::shadowrootmode) {
|
||||
return aResult.ParseEnumValue(aValue, kShadowRootModeTable, false, nullptr);
|
||||
}
|
||||
return nsGenericHTMLElement::ParseAttribute(aNamespaceID, aAttribute, aValue,
|
||||
aMaybeScriptedPrincipal, aResult);
|
||||
}
|
||||
|
||||
void HTMLTemplateElement::SetHTMLUnsafe(const nsAString& aHTML) {
|
||||
RefPtr<DocumentFragment> content = mContent;
|
||||
nsContentUtils::SetHTMLUnsafe(content, this, aHTML);
|
||||
}
|
||||
|
||||
} // namespace mozilla::dom
|
||||
|
|
|
@ -8,8 +8,11 @@
|
|||
#define mozilla_dom_HTMLTemplateElement_h
|
||||
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/ErrorResult.h"
|
||||
#include "nsGenericHTMLElement.h"
|
||||
#include "mozilla/dom/DocumentFragment.h"
|
||||
#include "mozilla/dom/ShadowRootBinding.h"
|
||||
#include "nsGkAtoms.h"
|
||||
|
||||
namespace mozilla::dom {
|
||||
|
||||
|
@ -26,9 +29,38 @@ class HTMLTemplateElement final : public nsGenericHTMLElement {
|
|||
NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED(HTMLTemplateElement,
|
||||
nsGenericHTMLElement)
|
||||
|
||||
void AfterSetAttr(int32_t aNamespaceID, nsAtom* aName,
|
||||
const nsAttrValue* aValue, const nsAttrValue* aOldValue,
|
||||
nsIPrincipal* aMaybeScriptedPrincipal,
|
||||
bool aNotify) override;
|
||||
|
||||
bool ParseAttribute(int32_t aNamespaceID, nsAtom* aAttribute,
|
||||
const nsAString& aValue,
|
||||
nsIPrincipal* aMaybeScriptedPrincipal,
|
||||
nsAttrValue& aResult) override;
|
||||
|
||||
virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
|
||||
|
||||
DocumentFragment* Content() { return mContent; }
|
||||
void SetContent(DocumentFragment* aContent) { mContent = aContent; }
|
||||
|
||||
void GetShadowRootMode(nsAString& aResult) const {
|
||||
GetEnumAttr(nsGkAtoms::shadowrootmode, nullptr, aResult);
|
||||
}
|
||||
void SetShadowRootMode(const nsAString& aValue) {
|
||||
SetHTMLAttr(nsGkAtoms::shadowrootmode, aValue);
|
||||
}
|
||||
|
||||
bool ShadowRootDelegatesFocus() {
|
||||
return GetBoolAttr(nsGkAtoms::shadowrootdelegatesfocus);
|
||||
}
|
||||
void SetShadowRootDelegatesFocus(bool aValue) {
|
||||
SetHTMLBoolAttr(nsGkAtoms::shadowrootdelegatesfocus, aValue,
|
||||
IgnoredErrorResult());
|
||||
}
|
||||
|
||||
MOZ_CAN_RUN_SCRIPT
|
||||
void SetHTMLUnsafe(const nsAString& aHTML) final;
|
||||
|
||||
protected:
|
||||
virtual ~HTMLTemplateElement();
|
||||
|
@ -37,6 +69,7 @@ class HTMLTemplateElement final : public nsGenericHTMLElement {
|
|||
JS::Handle<JSObject*> aGivenProto) override;
|
||||
|
||||
RefPtr<DocumentFragment> mContent;
|
||||
Maybe<ShadowRootMode> mShadowRootMode;
|
||||
};
|
||||
|
||||
} // namespace mozilla::dom
|
||||
|
|
|
@ -10,33 +10,39 @@
|
|||
# start:
|
||||
# https://source.chromium.org/search?q=usage:%23if.*def.*%5B%5E_%5D$%20AND%20path:%5C.h%20AND%20path:%5Ethird_party%2Fwebrtc&ss=chromium
|
||||
|
||||
if CONFIG['MOZ_WEBRTC']:
|
||||
DEFINES['HAVE_UINT64_T'] = True
|
||||
DEFINES['WEBRTC_MOZILLA_BUILD'] = True
|
||||
DEFINES['RTC_ENABLE_VP9'] = True
|
||||
if CONFIG["MOZ_WEBRTC"]:
|
||||
DEFINES["HAVE_UINT64_T"] = True
|
||||
DEFINES["WEBRTC_MOZILLA_BUILD"] = True
|
||||
DEFINES["RTC_ENABLE_VP9"] = True
|
||||
|
||||
if CONFIG['OS_TARGET'] != 'WINNT':
|
||||
DEFINES['WEBRTC_POSIX'] = True
|
||||
DEFINES['WEBRTC_BUILD_LIBEVENT'] = True
|
||||
if CONFIG["OS_TARGET"] != "WINNT":
|
||||
DEFINES["WEBRTC_POSIX"] = True
|
||||
DEFINES["WEBRTC_BUILD_LIBEVENT"] = True
|
||||
|
||||
if CONFIG['OS_TARGET'] == 'Linux':
|
||||
DEFINES['WEBRTC_LINUX'] = True
|
||||
if CONFIG['CPU_ARCH'] == 'x86' or CONFIG['CPU_ARCH'] == 'x86_64' or \
|
||||
CONFIG['CPU_ARCH'] == 'arm' or CONFIG['CPU_ARCH'] == 'aarch64' or \
|
||||
(CONFIG['TARGET_ENDIANNESS'] == 'little' and CONFIG['CPU_ARCH'].startswith('mips')):
|
||||
DEFINES['WEBRTC_USE_PIPEWIRE'] = True
|
||||
elif CONFIG['OS_TARGET'] == 'Darwin':
|
||||
DEFINES['WEBRTC_MAC'] = True
|
||||
elif CONFIG['OS_TARGET'] == 'WINNT':
|
||||
DEFINES['WEBRTC_WIN'] = True
|
||||
DEFINES['RTC_ENABLE_WIN_WGC'] = True
|
||||
DEFINES['HAVE_WINSOCK2_H'] = True
|
||||
elif CONFIG['OS_TARGET'] in ('DragonFly', 'FreeBSD', 'NetBSD', 'OpenBSD'):
|
||||
DEFINES['WEBRTC_BSD'] = True
|
||||
elif CONFIG['OS_TARGET'] == 'Android':
|
||||
DEFINES['WEBRTC_LINUX'] = True
|
||||
DEFINES['WEBRTC_ANDROID'] = True
|
||||
|
||||
if CONFIG['MOZ_X11']:
|
||||
DEFINES['WEBRTC_USE_X11'] = True
|
||||
if CONFIG["OS_TARGET"] == "Linux":
|
||||
DEFINES["WEBRTC_LINUX"] = True
|
||||
if (
|
||||
CONFIG["CPU_ARCH"] == "x86"
|
||||
or CONFIG["CPU_ARCH"] == "x86_64"
|
||||
or CONFIG["CPU_ARCH"] == "arm"
|
||||
or CONFIG["CPU_ARCH"] == "aarch64"
|
||||
or (
|
||||
CONFIG["TARGET_ENDIANNESS"] == "little"
|
||||
and CONFIG["CPU_ARCH"].startswith("mips")
|
||||
)
|
||||
):
|
||||
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
|
||||
elif CONFIG["OS_TARGET"] == "Darwin":
|
||||
DEFINES["WEBRTC_MAC"] = True
|
||||
elif CONFIG["OS_TARGET"] == "WINNT":
|
||||
DEFINES["WEBRTC_WIN"] = True
|
||||
DEFINES["RTC_ENABLE_WIN_WGC"] = True
|
||||
DEFINES["HAVE_WINSOCK2_H"] = True
|
||||
elif CONFIG["OS_TARGET"] in ("DragonFly", "FreeBSD", "NetBSD", "OpenBSD"):
|
||||
DEFINES["WEBRTC_BSD"] = True
|
||||
elif CONFIG["OS_TARGET"] == "Android":
|
||||
DEFINES["WEBRTC_LINUX"] = True
|
||||
DEFINES["WEBRTC_ANDROID"] = True
|
||||
|
||||
if CONFIG["MOZ_X11"]:
|
||||
DEFINES["WEBRTC_USE_X11"] = True
|
||||
|
|
|
@ -59,8 +59,8 @@ void RtpLogger::LogPacket(const MediaPacket& packet, bool input,
|
|||
ss << " " << std::setw(2) << (int)packet.data()[i];
|
||||
}
|
||||
MOZ_LOG(gRtpLoggerLog, LogLevel::Debug,
|
||||
("%s%s%s", desc.c_str(), (isRtp ? " RTP_PACKET " : " RTCP_PACKET "),
|
||||
ss.str().c_str()));
|
||||
("%s %s|>> %s", desc.c_str(),
|
||||
(isRtp ? "RTP_PACKET" : "RTCP_PACKET"), ss.str().c_str()));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -12,6 +12,7 @@ prefs = [
|
|||
"security.webauth.webauthn_enable_usbtoken=false",
|
||||
"security.webauthn.ctap2=true",
|
||||
"security.webauthn.enable_conditional_mediation=true",
|
||||
"security.webauthn.enable_macos_passkeys=false",
|
||||
]
|
||||
|
||||
["browser_abort_visibility.js"]
|
||||
|
|
|
@ -14,6 +14,7 @@ prefs = [
|
|||
"security.webauth.webauthn_enable_usbtoken=false",
|
||||
"security.webauthn.ctap2=true",
|
||||
"security.webauthn.enable_conditional_mediation=true",
|
||||
"security.webauthn.enable_macos_passkeys=false",
|
||||
]
|
||||
|
||||
["test_webauthn_abort_signal.html"]
|
||||
|
|
|
@ -151,6 +151,9 @@ interface Document : Node {
|
|||
|
||||
// https://html.spec.whatwg.org/multipage/dom.html#the-document-object
|
||||
partial interface Document {
|
||||
[Pref="dom.webcomponents.shadowdom.declarative.enabled"]
|
||||
static Document parseHTMLUnsafe(DOMString html);
|
||||
|
||||
[PutForwards=href, LegacyUnforgeable] readonly attribute Location? location;
|
||||
[SetterThrows] attribute DOMString domain;
|
||||
readonly attribute DOMString referrer;
|
||||
|
|
|
@ -276,6 +276,8 @@ dictionary ShadowRootInit {
|
|||
required ShadowRootMode mode;
|
||||
boolean delegatesFocus = false;
|
||||
SlotAssignmentMode slotAssignment = "named";
|
||||
[Pref="dom.webcomponents.shadowdom.declarative.enabled"]
|
||||
boolean clonable = false;
|
||||
};
|
||||
|
||||
// https://dom.spec.whatwg.org/#element
|
||||
|
@ -403,3 +405,9 @@ partial interface Element {
|
|||
[SecureContext, UseCounter, Throws, Pref="dom.security.setHTML.enabled"]
|
||||
undefined setHTML(DOMString aInnerHTML, optional SetHTMLOptions options = {});
|
||||
};
|
||||
|
||||
partial interface Element {
|
||||
// https://html.spec.whatwg.org/#dom-element-sethtmlunsafe
|
||||
[Pref="dom.webcomponents.shadowdom.declarative.enabled"]
|
||||
undefined setHTMLUnsafe(DOMString html);
|
||||
};
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* The origin of this IDL file is
|
||||
* https://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/templates/index.html
|
||||
* https://html.spec.whatwg.org/multipage/scripting.html#the-template-element
|
||||
*
|
||||
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
||||
* liability, trademark and document use rules apply.
|
||||
|
@ -13,5 +13,9 @@
|
|||
interface HTMLTemplateElement : HTMLElement {
|
||||
[HTMLConstructor] constructor();
|
||||
|
||||
readonly attribute DocumentFragment content;
|
||||
readonly attribute DocumentFragment content;
|
||||
[CEReactions, Pref="dom.webcomponents.shadowdom.declarative.enabled"]
|
||||
attribute DOMString shadowRootMode;
|
||||
[CEReactions, Pref="dom.webcomponents.shadowdom.declarative.enabled"]
|
||||
attribute boolean shadowRootDelegatesFocus;
|
||||
};
|
||||
|
|
|
@ -56,4 +56,10 @@ interface ShadowRoot : DocumentFragment
|
|||
boolean isUAWidget();
|
||||
};
|
||||
|
||||
partial interface ShadowRoot {
|
||||
// https://html.spec.whatwg.org/#dom-shadowroot-sethtmlunsafe
|
||||
[Pref="dom.webcomponents.shadowdom.declarative.enabled"]
|
||||
undefined setHTMLUnsafe(DOMString html);
|
||||
};
|
||||
|
||||
ShadowRoot includes DocumentOrShadowRoot;
|
||||
|
|
|
@ -168,11 +168,13 @@ class WebSocketImpl final : public nsIInterfaceRequestor,
|
|||
nsICookieJarSettings* aCookieJarSettings);
|
||||
|
||||
// These methods when called can release the WebSocket object
|
||||
void FailConnection(uint16_t reasonCode,
|
||||
void FailConnection(const RefPtr<WebSocketImpl>& aProofOfRef,
|
||||
uint16_t reasonCode,
|
||||
const nsACString& aReasonString = ""_ns);
|
||||
nsresult CloseConnection(uint16_t reasonCode,
|
||||
nsresult CloseConnection(const RefPtr<WebSocketImpl>& aProofOfRef,
|
||||
uint16_t reasonCode,
|
||||
const nsACString& aReasonString = ""_ns);
|
||||
void Disconnect();
|
||||
void Disconnect(const RefPtr<WebSocketImpl>& aProofOfRef);
|
||||
void DisconnectInternal();
|
||||
|
||||
nsresult ConsoleError();
|
||||
|
@ -185,7 +187,7 @@ class WebSocketImpl final : public nsIInterfaceRequestor,
|
|||
nsresult ScheduleConnectionCloseEvents(nsISupports* aContext,
|
||||
nsresult aStatusCode);
|
||||
// 2nd half of ScheduleConnectionCloseEvents, run in its own event.
|
||||
void DispatchConnectionCloseEvents();
|
||||
void DispatchConnectionCloseEvents(const RefPtr<WebSocketImpl>& aProofOfRef);
|
||||
|
||||
nsresult UpdateURI();
|
||||
|
||||
|
@ -226,7 +228,7 @@ class WebSocketImpl final : public nsIInterfaceRequestor,
|
|||
nsCString mURI;
|
||||
nsCString mRequestedProtocolList;
|
||||
|
||||
nsWeakPtr mOriginDocument;
|
||||
WeakPtr<Document> mOriginDocument;
|
||||
|
||||
// Web Socket owner information:
|
||||
// - the script file name, UTF8 encoded.
|
||||
|
@ -265,7 +267,8 @@ class WebSocketImpl final : public nsIInterfaceRequestor,
|
|||
|
||||
// If we threw during Init we never called disconnect
|
||||
if (!mDisconnectingOrDisconnected) {
|
||||
Disconnect();
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
Disconnect(self);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -306,7 +309,7 @@ class CallDispatchConnectionCloseEvents final : public DiscardableRunnable {
|
|||
|
||||
NS_IMETHOD Run() override {
|
||||
mWebSocketImpl->AssertIsOnTargetThread();
|
||||
mWebSocketImpl->DispatchConnectionCloseEvents();
|
||||
mWebSocketImpl->DispatchConnectionCloseEvents(mWebSocketImpl);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
@ -452,12 +455,12 @@ class MOZ_STACK_CLASS MaybeDisconnect {
|
|||
}
|
||||
|
||||
if (toDisconnect) {
|
||||
mImpl->Disconnect();
|
||||
mImpl->Disconnect(mImpl);
|
||||
}
|
||||
}
|
||||
|
||||
private:
|
||||
WebSocketImpl* mImpl;
|
||||
RefPtr<WebSocketImpl> mImpl;
|
||||
};
|
||||
|
||||
class CloseConnectionRunnable final : public Runnable {
|
||||
|
@ -470,7 +473,7 @@ class CloseConnectionRunnable final : public Runnable {
|
|||
mReasonString(aReasonString) {}
|
||||
|
||||
NS_IMETHOD Run() override {
|
||||
return mImpl->CloseConnection(mReasonCode, mReasonString);
|
||||
return mImpl->CloseConnection(mImpl, mReasonCode, mReasonString);
|
||||
}
|
||||
|
||||
private:
|
||||
|
@ -481,8 +484,9 @@ class CloseConnectionRunnable final : public Runnable {
|
|||
|
||||
} // namespace
|
||||
|
||||
nsresult WebSocketImpl::CloseConnection(uint16_t aReasonCode,
|
||||
const nsACString& aReasonString) {
|
||||
nsresult WebSocketImpl::CloseConnection(
|
||||
const RefPtr<WebSocketImpl>& aProofOfRef, uint16_t aReasonCode,
|
||||
const nsACString& aReasonString) {
|
||||
if (!IsTargetThread()) {
|
||||
nsCOMPtr<nsIRunnable> runnable =
|
||||
new CloseConnectionRunnable(this, aReasonCode, aReasonString);
|
||||
|
@ -564,7 +568,8 @@ nsresult WebSocketImpl::ConsoleError() {
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
void WebSocketImpl::FailConnection(uint16_t aReasonCode,
|
||||
void WebSocketImpl::FailConnection(const RefPtr<WebSocketImpl>& aProofOfRef,
|
||||
uint16_t aReasonCode,
|
||||
const nsACString& aReasonString) {
|
||||
AssertIsOnTargetThread();
|
||||
|
||||
|
@ -574,7 +579,7 @@ void WebSocketImpl::FailConnection(uint16_t aReasonCode,
|
|||
|
||||
ConsoleError();
|
||||
mFailed = true;
|
||||
CloseConnection(aReasonCode, aReasonString);
|
||||
CloseConnection(aProofOfRef, aReasonCode, aReasonString);
|
||||
|
||||
if (NS_IsMainThread() && mImplProxy) {
|
||||
mImplProxy->Disconnect();
|
||||
|
@ -597,25 +602,28 @@ class DisconnectInternalRunnable final : public WorkerMainThreadRunnable {
|
|||
}
|
||||
|
||||
private:
|
||||
// A raw pointer because this runnable is sync.
|
||||
// NOTE: WebSocketImpl may be it the middle of being destroyed.
|
||||
// We can't just hold this as a RefPtr, since after the runnable ends
|
||||
// the sync caller will be released, and can finish destroying WebSocketImpl
|
||||
// before a ref here could be dropped.
|
||||
WebSocketImpl* mImpl;
|
||||
};
|
||||
|
||||
} // namespace
|
||||
|
||||
void WebSocketImpl::Disconnect() {
|
||||
void WebSocketImpl::Disconnect(const RefPtr<WebSocketImpl>& aProofOfRef) {
|
||||
MOZ_RELEASE_ASSERT(NS_IsMainThread() == mIsMainThread);
|
||||
|
||||
if (mDisconnectingOrDisconnected) {
|
||||
return;
|
||||
}
|
||||
|
||||
// DontKeepAliveAnyMore() and DisconnectInternal() can release the object. So
|
||||
// hold a reference to this until the end of the method.
|
||||
RefPtr<WebSocketImpl> kungfuDeathGrip = this;
|
||||
// DontKeepAliveAnyMore() and DisconnectInternal() can release the
|
||||
// object. aProofOfRef ensures we're holding a reference to this until
|
||||
// the end of the method.
|
||||
|
||||
// Disconnect can be called from some control event (such as a callback from
|
||||
// StrongWorkerRef). This will be schedulated before any other sync/async
|
||||
// StrongWorkerRef). This will be scheduled before any other sync/async
|
||||
// runnable. In order to prevent some double Disconnect() calls, we use this
|
||||
// boolean.
|
||||
mDisconnectingOrDisconnected = true;
|
||||
|
@ -661,7 +669,7 @@ void WebSocketImpl::DisconnectInternal() {
|
|||
nsCOMPtr<nsILoadGroup> loadGroup = do_QueryReferent(mWeakLoadGroup);
|
||||
if (loadGroup) {
|
||||
loadGroup->RemoveRequest(this, nullptr, NS_OK);
|
||||
// mWeakLoadGroup has to be release on main-thread because WeakReferences
|
||||
// mWeakLoadGroup has to be released on main-thread because WeakReferences
|
||||
// are not thread-safe.
|
||||
mWeakLoadGroup = nullptr;
|
||||
}
|
||||
|
@ -777,7 +785,8 @@ WebSocketImpl::OnStart(nsISupports* aContext) {
|
|||
// Attempt to kill "ghost" websocket: but usually too early for check to fail
|
||||
nsresult rv = mWebSocket->CheckCurrentGlobalCorrectness();
|
||||
if (NS_FAILED(rv)) {
|
||||
CloseConnection(nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
CloseConnection(self, nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
return rv;
|
||||
}
|
||||
|
||||
|
@ -798,7 +807,7 @@ WebSocketImpl::OnStart(nsISupports* aContext) {
|
|||
mChannel->HttpChannelId());
|
||||
|
||||
// Let's keep the object alive because the webSocket can be CCed in the
|
||||
// onopen callback.
|
||||
// onopen callback
|
||||
RefPtr<WebSocket> webSocket = mWebSocket;
|
||||
|
||||
// Call 'onopen'
|
||||
|
@ -909,10 +918,11 @@ WebSocketImpl::OnServerClose(nsISupports* aContext, uint16_t aCode,
|
|||
// RFC 6455, 5.5.1: "When sending a Close frame in response, the endpoint
|
||||
// typically echos the status code it received".
|
||||
// But never send certain codes, per section 7.4.1
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
if (aCode == 1005 || aCode == 1006 || aCode == 1015) {
|
||||
CloseConnection(0, ""_ns);
|
||||
CloseConnection(self, 0, ""_ns);
|
||||
} else {
|
||||
CloseConnection(aCode, aReason);
|
||||
CloseConnection(self, aCode, aReason);
|
||||
}
|
||||
} else {
|
||||
// We initiated close, and server has replied: OnStop does rest of the work.
|
||||
|
@ -929,13 +939,14 @@ WebSocketImpl::OnError() {
|
|||
NS_NewRunnableFunction("dom::FailConnectionRunnable",
|
||||
[self = RefPtr{this}]() {
|
||||
self->FailConnection(
|
||||
nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
self, nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
}),
|
||||
NS_DISPATCH_NORMAL);
|
||||
}
|
||||
|
||||
AssertIsOnTargetThread();
|
||||
FailConnection(nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
FailConnection(self, nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
@ -1420,7 +1431,8 @@ already_AddRefed<WebSocket> WebSocket::ConstructorCommon(
|
|||
// We don't return an error if the connection just failed. Instead we dispatch
|
||||
// an event.
|
||||
if (connectionFailed) {
|
||||
webSocket->mImpl->FailConnection(nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
webSocketImpl->FailConnection(webSocketImpl,
|
||||
nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
}
|
||||
|
||||
// If we don't have a channel, the connection is failed and onerror() will be
|
||||
|
@ -1439,11 +1451,12 @@ already_AddRefed<WebSocket> WebSocket::ConstructorCommon(
|
|||
~ClearWebSocket() {
|
||||
if (!mDone) {
|
||||
mWebSocketImpl->mChannel = nullptr;
|
||||
mWebSocketImpl->FailConnection(nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
mWebSocketImpl->FailConnection(mWebSocketImpl,
|
||||
nsIWebSocketChannel::CLOSE_ABNORMAL);
|
||||
}
|
||||
}
|
||||
|
||||
WebSocketImpl* mWebSocketImpl;
|
||||
RefPtr<WebSocketImpl> mWebSocketImpl;
|
||||
bool mDone;
|
||||
};
|
||||
|
||||
|
@ -1531,7 +1544,8 @@ NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
|
|||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(WebSocket, DOMEventTargetHelper)
|
||||
if (tmp->mImpl) {
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK(mImpl->mChannel)
|
||||
tmp->mImpl->Disconnect();
|
||||
RefPtr<WebSocketImpl> pin(tmp->mImpl);
|
||||
pin->Disconnect(pin);
|
||||
MOZ_ASSERT(!tmp->mImpl);
|
||||
}
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
|
||||
|
@ -1555,7 +1569,8 @@ void WebSocket::DisconnectFromOwner() {
|
|||
DOMEventTargetHelper::DisconnectFromOwner();
|
||||
|
||||
if (mImpl) {
|
||||
mImpl->CloseConnection(nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
RefPtr<WebSocketImpl> pin(mImpl);
|
||||
pin->CloseConnection(pin, nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
}
|
||||
|
||||
DontKeepAliveAnyMore();
|
||||
|
@ -1643,7 +1658,7 @@ nsresult WebSocketImpl::Init(JSContext* aCx, bool aIsSecure,
|
|||
rv = mWebSocket->CheckCurrentGlobalCorrectness();
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
}
|
||||
mOriginDocument = do_GetWeakReference(originDoc);
|
||||
mOriginDocument = originDoc;
|
||||
|
||||
if (!mIsServerSide) {
|
||||
nsCOMPtr<nsIURI> uri;
|
||||
|
@ -1842,7 +1857,7 @@ class nsAutoCloseWS final {
|
|||
~nsAutoCloseWS() {
|
||||
if (!mWebSocketImpl->mChannel) {
|
||||
mWebSocketImpl->CloseConnection(
|
||||
nsIWebSocketChannel::CLOSE_INTERNAL_ERROR);
|
||||
mWebSocketImpl, nsIWebSocketChannel::CLOSE_INTERNAL_ERROR);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1883,7 +1898,7 @@ nsresult WebSocketImpl::InitializeConnection(
|
|||
|
||||
// manually adding loadinfo to the channel since it
|
||||
// was not set during channel creation.
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mOriginDocument);
|
||||
nsCOMPtr<Document> doc(mOriginDocument);
|
||||
|
||||
// mOriginDocument has to be release on main-thread because WeakReferences
|
||||
// are not thread-safe.
|
||||
|
@ -1923,7 +1938,8 @@ nsresult WebSocketImpl::InitializeConnection(
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
void WebSocketImpl::DispatchConnectionCloseEvents() {
|
||||
void WebSocketImpl::DispatchConnectionCloseEvents(
|
||||
const RefPtr<WebSocketImpl>& aProofOfRef) {
|
||||
AssertIsOnTargetThread();
|
||||
|
||||
if (mDisconnectingOrDisconnected) {
|
||||
|
@ -1933,7 +1949,7 @@ void WebSocketImpl::DispatchConnectionCloseEvents() {
|
|||
mWebSocket->SetReadyState(WebSocket::CLOSED);
|
||||
|
||||
// Let's keep the object alive because the webSocket can be CCed in the
|
||||
// onerror or in the onclose callback.
|
||||
// onerror or in the onclose callback
|
||||
RefPtr<WebSocket> webSocket = mWebSocket;
|
||||
|
||||
// Call 'onerror' if needed
|
||||
|
@ -1951,7 +1967,7 @@ void WebSocketImpl::DispatchConnectionCloseEvents() {
|
|||
}
|
||||
|
||||
webSocket->UpdateMustKeepAlive();
|
||||
Disconnect();
|
||||
Disconnect(aProofOfRef);
|
||||
}
|
||||
|
||||
nsresult WebSocket::CreateAndDispatchSimpleEvent(const nsAString& aName) {
|
||||
|
@ -2216,6 +2232,8 @@ void WebSocket::UpdateMustKeepAlive() {
|
|||
if (mKeepingAlive && !shouldKeepAlive) {
|
||||
mKeepingAlive = false;
|
||||
mImpl->ReleaseObject();
|
||||
// Note that this could be made 'alive' again if another listener is
|
||||
// added.
|
||||
} else if (!mKeepingAlive && shouldKeepAlive) {
|
||||
mKeepingAlive = true;
|
||||
mImpl->AddRefObject();
|
||||
|
@ -2249,7 +2267,7 @@ void WebSocketImpl::ReleaseObject() {
|
|||
bool WebSocketImpl::RegisterWorkerRef(WorkerPrivate* aWorkerPrivate) {
|
||||
MOZ_ASSERT(aWorkerPrivate);
|
||||
|
||||
RefPtr<WebSocketImpl> self = this;
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
|
||||
// In workers we have to keep the worker alive using a strong reference in
|
||||
// order to dispatch messages correctly.
|
||||
|
@ -2260,7 +2278,8 @@ bool WebSocketImpl::RegisterWorkerRef(WorkerPrivate* aWorkerPrivate) {
|
|||
self->mWorkerShuttingDown = true;
|
||||
}
|
||||
|
||||
self->CloseConnection(nsIWebSocketChannel::CLOSE_GOING_AWAY, ""_ns);
|
||||
self->CloseConnection(self, nsIWebSocketChannel::CLOSE_GOING_AWAY,
|
||||
""_ns);
|
||||
});
|
||||
if (NS_WARN_IF(!workerRef)) {
|
||||
return false;
|
||||
|
@ -2519,14 +2538,17 @@ void WebSocket::Close(const Optional<uint16_t>& aCode,
|
|||
return;
|
||||
}
|
||||
|
||||
RefPtr<WebSocketImpl> impl = mImpl;
|
||||
// These could cause the mImpl to be released (and so this to be
|
||||
// released); make sure it stays valid through the call
|
||||
RefPtr<WebSocketImpl> pin(mImpl);
|
||||
|
||||
if (readyState == CONNECTING) {
|
||||
impl->FailConnection(closeCode, closeReason);
|
||||
pin->FailConnection(pin, closeCode, closeReason);
|
||||
return;
|
||||
}
|
||||
|
||||
MOZ_ASSERT(readyState == OPEN);
|
||||
impl->CloseConnection(closeCode, closeReason);
|
||||
pin->CloseConnection(pin, closeCode, closeReason);
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
|
@ -2550,7 +2572,8 @@ WebSocketImpl::Observe(nsISupports* aSubject, const char* aTopic,
|
|||
|
||||
if ((strcmp(aTopic, DOM_WINDOW_FROZEN_TOPIC) == 0) ||
|
||||
(strcmp(aTopic, DOM_WINDOW_DESTROYED_TOPIC) == 0)) {
|
||||
CloseConnection(nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
CloseConnection(self, nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
}
|
||||
|
||||
return NS_OK;
|
||||
|
@ -2649,7 +2672,8 @@ nsresult WebSocketImpl::CancelInternal() {
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
return CloseConnection(nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
RefPtr<WebSocketImpl> self(this);
|
||||
return CloseConnection(self, nsIWebSocketChannel::CLOSE_GOING_AWAY);
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
|
|
|
@ -57,15 +57,14 @@ class XPathEvaluatorParseContext : public txIParseContext {
|
|||
bool mIsCaseSensitive;
|
||||
};
|
||||
|
||||
XPathEvaluator::XPathEvaluator(Document* aDocument)
|
||||
: mDocument(do_GetWeakReference(aDocument)) {}
|
||||
XPathEvaluator::XPathEvaluator(Document* aDocument) : mDocument(aDocument) {}
|
||||
|
||||
XPathEvaluator::~XPathEvaluator() = default;
|
||||
|
||||
UniquePtr<XPathExpression> XPathEvaluator::CreateExpression(
|
||||
const nsAString& aExpression, XPathNSResolver* aResolver,
|
||||
ErrorResult& aRv) {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> doc(mDocument);
|
||||
XPathEvaluatorParseContext pContext(aResolver,
|
||||
!(doc && doc->IsHTMLDocument()));
|
||||
return CreateExpression(aExpression, &pContext, doc, aRv);
|
||||
|
@ -73,7 +72,7 @@ UniquePtr<XPathExpression> XPathEvaluator::CreateExpression(
|
|||
|
||||
UniquePtr<XPathExpression> XPathEvaluator::CreateExpression(
|
||||
const nsAString& aExpression, nsINode* aResolver, ErrorResult& aRv) {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> doc(mDocument);
|
||||
XPathEvaluatorParseContext pContext(aResolver,
|
||||
!(doc && doc->IsHTMLDocument()));
|
||||
return CreateExpression(aExpression, &pContext, doc, aRv);
|
||||
|
|
|
@ -36,10 +36,7 @@ class XPathEvaluator final : public NonRefcountedDOMObject {
|
|||
// WebIDL API
|
||||
bool WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto,
|
||||
JS::MutableHandle<JSObject*> aReflector);
|
||||
Document* GetParentObject() {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
return doc;
|
||||
}
|
||||
Document* GetParentObject() { return mDocument; }
|
||||
static UniquePtr<XPathEvaluator> Constructor(const GlobalObject& aGlobal);
|
||||
UniquePtr<XPathExpression> CreateExpression(const nsAString& aExpression,
|
||||
XPathNSResolver* aResolver,
|
||||
|
@ -58,7 +55,7 @@ class XPathEvaluator final : public NonRefcountedDOMObject {
|
|||
ErrorResult& rv);
|
||||
|
||||
private:
|
||||
nsWeakPtr mDocument;
|
||||
WeakPtr<Document> mDocument;
|
||||
RefPtr<txResultRecycler> mRecycler;
|
||||
};
|
||||
|
||||
|
|
|
@ -170,7 +170,7 @@ NS_IMPL_CYCLE_COLLECTING_RELEASE(XULContentSinkImpl)
|
|||
|
||||
NS_IMETHODIMP
|
||||
XULContentSinkImpl::DidBuildModel(bool aTerminated) {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> doc(mDocument);
|
||||
if (doc) {
|
||||
mPrototype->NotifyLoadDone();
|
||||
mDocument = nullptr;
|
||||
|
@ -200,16 +200,13 @@ XULContentSinkImpl::SetParser(nsParserBase* aParser) {
|
|||
|
||||
void XULContentSinkImpl::SetDocumentCharset(
|
||||
NotNull<const Encoding*> aEncoding) {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> doc(mDocument);
|
||||
if (doc) {
|
||||
doc->SetDocumentCharacterSet(aEncoding);
|
||||
}
|
||||
}
|
||||
|
||||
nsISupports* XULContentSinkImpl::GetTarget() {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
return ToSupports(doc);
|
||||
}
|
||||
nsISupports* XULContentSinkImpl::GetTarget() { return ToSupports(mDocument); }
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
|
||||
|
@ -218,7 +215,7 @@ nsresult XULContentSinkImpl::Init(Document* aDocument,
|
|||
MOZ_ASSERT(aDocument != nullptr, "null ptr");
|
||||
if (!aDocument) return NS_ERROR_NULL_POINTER;
|
||||
|
||||
mDocument = do_GetWeakReference(aDocument);
|
||||
mDocument = aDocument;
|
||||
mPrototype = aPrototype;
|
||||
|
||||
mDocumentURL = mPrototype->GetURI();
|
||||
|
@ -412,7 +409,7 @@ XULContentSinkImpl::HandleEndElement(const char16_t* aName) {
|
|||
|
||||
// If given a src= attribute, we must ignore script tag content.
|
||||
if (!script->mSrcURI && !script->HasStencil()) {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> doc(mDocument);
|
||||
|
||||
script->mOutOfLine = false;
|
||||
if (doc) {
|
||||
|
@ -548,7 +545,7 @@ XULContentSinkImpl::ReportError(const char16_t* aErrorText,
|
|||
|
||||
// return leaving the document empty if we're asked to not add a <parsererror>
|
||||
// root node
|
||||
nsCOMPtr<Document> idoc = do_QueryReferent(mDocument);
|
||||
nsCOMPtr<Document> idoc(mDocument);
|
||||
if (idoc && idoc->SuppressParserErrorElement()) {
|
||||
return NS_OK;
|
||||
};
|
||||
|
@ -725,7 +722,7 @@ nsresult XULContentSinkImpl::OpenScript(const char16_t** aAttributes,
|
|||
return NS_OK;
|
||||
}
|
||||
|
||||
nsCOMPtr<Document> doc(do_QueryReferent(mDocument));
|
||||
nsCOMPtr<Document> doc(mDocument);
|
||||
nsCOMPtr<nsIScriptGlobalObject> globalObject;
|
||||
if (doc) globalObject = do_QueryInterface(doc->GetWindow());
|
||||
RefPtr<nsXULPrototypeScript> script = new nsXULPrototypeScript(aLineNumber);
|
||||
|
@ -741,14 +738,10 @@ nsresult XULContentSinkImpl::OpenScript(const char16_t** aAttributes,
|
|||
if (NS_SUCCEEDED(rv)) {
|
||||
if (!mSecMan)
|
||||
mSecMan = do_GetService(NS_SCRIPTSECURITYMANAGER_CONTRACTID, &rv);
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
nsCOMPtr<Document> doc = do_QueryReferent(mDocument, &rv);
|
||||
|
||||
if (NS_SUCCEEDED(rv)) {
|
||||
rv = mSecMan->CheckLoadURIWithPrincipal(
|
||||
doc->NodePrincipal(), script->mSrcURI,
|
||||
nsIScriptSecurityManager::ALLOW_CHROME, doc->InnerWindowID());
|
||||
}
|
||||
if (NS_SUCCEEDED(rv) && doc) {
|
||||
rv = mSecMan->CheckLoadURIWithPrincipal(
|
||||
doc->NodePrincipal(), script->mSrcURI,
|
||||
nsIScriptSecurityManager::ALLOW_CHROME, doc->InnerWindowID());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
#define nsXULContentSink_h__
|
||||
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/WeakPtr.h"
|
||||
#include "nsIExpatSink.h"
|
||||
#include "nsIWeakReferenceUtils.h"
|
||||
#include "nsIXMLContentSink.h"
|
||||
|
@ -131,7 +132,7 @@ class XULContentSinkImpl final : public nsIXMLContentSink, public nsIExpatSink {
|
|||
friend class ContextStack;
|
||||
ContextStack mContextStack;
|
||||
|
||||
nsWeakPtr mDocument; // [OWNER]
|
||||
mozilla::WeakPtr<mozilla::dom::Document> mDocument;
|
||||
nsCOMPtr<nsIURI> mDocumentURL; // [OWNER]
|
||||
|
||||
RefPtr<nsXULPrototypeDocument> mPrototype; // [OWNER]
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
# 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/.
|
||||
|
||||
|
||||
@template
|
||||
def HunspellIncludes():
|
||||
ForceInclude('hunspell_alloc_hooks.h')
|
||||
ForceInclude("hunspell_alloc_hooks.h")
|
||||
|
|
|
@ -6,6 +6,7 @@
|
|||
<script src="/tests/SimpleTest/SimpleTest.js"></script>
|
||||
<script src="/tests/SimpleTest/paint_listener.js"></script>
|
||||
<script src="helper_fission_utils.js"></script>
|
||||
<script src="apz_test_native_event_utils.js"></script>
|
||||
<script src="apz_test_utils.js"></script>
|
||||
<script>
|
||||
|
||||
|
@ -85,6 +86,12 @@ async function promiseScrollInfoArrivalInOOPIF() {
|
|||
await Promise.all([scrollPromise, transformReceivedPromise]);
|
||||
}
|
||||
|
||||
function isWindows11() {
|
||||
return getPlatform() == "windows" &&
|
||||
SpecialPowers.Services.sysinfo.getProperty("version", null) == "10.0" &&
|
||||
SpecialPowers.Services.sysinfo.getProperty("build", null) == "22621";
|
||||
}
|
||||
|
||||
// The actual test
|
||||
|
||||
async function test() {
|
||||
|
@ -93,9 +100,17 @@ async function test() {
|
|||
await setup_in_oopif();
|
||||
|
||||
let restyleCount = await observe_styling_in_oopif(5);
|
||||
is(restyleCount, 0,
|
||||
"Animation in an out-of-process iframe which is initially clipped out " +
|
||||
"due to 'overflow: hidden' should be throttled");
|
||||
// Allow 1 restyle count on Windows 11 since on our CIs there's something
|
||||
// causing force flushing.
|
||||
if (isWindows11()) {
|
||||
ok(restyleCount <= 1,
|
||||
"Animation in an out-of-process iframe which is initially clipped out " +
|
||||
"due to 'overflow: hidden' should be throttled");
|
||||
} else {
|
||||
is(restyleCount, 0,
|
||||
"Animation in an out-of-process iframe which is initially clipped out " +
|
||||
"due to 'overflow: hidden' should be throttled");
|
||||
}
|
||||
|
||||
// Scroll synchronously to a position where the iframe gets visible.
|
||||
scroller.scrollTo(0, 1000);
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
#include "cairo.h"
|
||||
#include "cairo-quartz.h"
|
||||
#include "mozilla/gfx/HelpersCairo.h"
|
||||
#include "mozilla/StaticPrefs_layout.h"
|
||||
#include "mozilla/StaticPrefs_print.h"
|
||||
#include "nsObjCExceptions.h"
|
||||
#include "nsString.h"
|
||||
#include "nsIOutputStream.h"
|
||||
|
@ -229,7 +229,8 @@ nsresult PrintTargetCG::BeginPage(const IntSize& aSizeInPoints) {
|
|||
|
||||
unsigned int width;
|
||||
unsigned int height;
|
||||
if (StaticPrefs::layout_css_page_orientation_enabled()) {
|
||||
if (StaticPrefs::
|
||||
print_save_as_pdf_use_page_rule_size_as_paper_size_enabled()) {
|
||||
width = static_cast<unsigned int>(aSizeInPoints.width);
|
||||
height = static_cast<unsigned int>(aSizeInPoints.height);
|
||||
} else {
|
||||
|
@ -260,7 +261,8 @@ nsresult PrintTargetCG::BeginPage(const IntSize& aSizeInPoints) {
|
|||
// anyway. But Core Graphics output is better than Cairo's in some cases.
|
||||
//
|
||||
// For now, we support switching sheet orientation only:
|
||||
if (StaticPrefs::layout_css_page_orientation_enabled()) {
|
||||
if (StaticPrefs::
|
||||
print_save_as_pdf_use_page_rule_size_as_paper_size_enabled()) {
|
||||
::PMOrientation pageOrientation =
|
||||
width < height ? kPMPortrait : kPMLandscape;
|
||||
::PMSetOrientation(mPageFormat, pageOrientation, kPMUnlocked);
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
#include "cairo.h"
|
||||
#include "cairo-pdf.h"
|
||||
#include "mozilla/AppShutdown.h"
|
||||
#include "mozilla/StaticPrefs_layout.h"
|
||||
#include "mozilla/StaticPrefs_print.h"
|
||||
#include "nsContentUtils.h"
|
||||
#include "nsString.h"
|
||||
|
||||
|
@ -76,7 +76,8 @@ already_AddRefed<PrintTargetPDF> PrintTargetPDF::CreateOrNull(
|
|||
}
|
||||
|
||||
nsresult PrintTargetPDF::BeginPage(const IntSize& aSizeInPoints) {
|
||||
if (StaticPrefs::layout_css_page_orientation_enabled()) {
|
||||
if (StaticPrefs::
|
||||
print_save_as_pdf_use_page_rule_size_as_paper_size_enabled()) {
|
||||
cairo_pdf_surface_set_size(mCairoSurface, aSizeInPoints.width,
|
||||
aSizeInPoints.height);
|
||||
if (cairo_surface_status(mCairoSurface)) {
|
||||
|
|
|
@ -82,13 +82,15 @@ ICU’s locale data covers *all* ICU internationalization features, including on
|
|||
.. [#why-icudt-not-rebuilt-every-time]
|
||||
``icudtNNE.dat`` isn’t compiled during a SpiderMonkey/Gecko build because it would require ICU command-line tools. And it’s a pain to either compile and run them during the build, or to require them as build dependencies.
|
||||
|
||||
Local patching of ICU
|
||||
---------------------
|
||||
Local patching of ICU and CLDR
|
||||
------------------------------
|
||||
|
||||
We generally don’t patch our copy of ICU except for compelling need. When we do patch, we usually only apply reasonably small patches that have been reviewed and landed upstream (so that our patch will be obsolete when we next update ICU).
|
||||
|
||||
Local patches are stored in the ``intl/icu-patches`` directory. They’re applied when ICU is updated, so merely updating ICU files in place won’t persist changes across an ICU update.
|
||||
|
||||
Patching ICU also allows for patching some parts and uses of CLDR, the data backing ICU operations. Note that this does not include character data, which is `updated separately <https://wiki.mozilla.org/I18n:Updating_Unicode_version>`__, and that any such patching does not affect any other CLDR uses. In particular, Fluent localization depends on Rust crates which themselves depend on CLDR data directly and separately from ICU. Any CLDR patches should remain reasonably small; larger changes such as adding support for a new locale should be done upstream.
|
||||
|
||||
Updating imported code
|
||||
----------------------
|
||||
|
||||
|
|
|
@ -175,7 +175,7 @@ def write_sources(mozbuild, sources, headers):
|
|||
def write_list(name, content):
|
||||
if content:
|
||||
f.write("%s %s [\n" % (name, "=" if name.islower() else "+="))
|
||||
f.write("".join(" '/%s',\n" % s for s in content))
|
||||
f.write("".join(' "/%s",\n' % s for s in content))
|
||||
f.write("]\n")
|
||||
|
||||
write_list("sources", [s for s in sources if s not in UNUSED_SOURCES])
|
||||
|
|
|
@ -1093,6 +1093,15 @@ void LineBreaker::ComputeBreakPositions(
|
|||
LineBreakRule aLevel, bool aIsChineseOrJapanese, uint8_t* aBreakBefore) {
|
||||
#if defined(MOZ_ICU4X) && defined(JS_HAS_INTL_API)
|
||||
if (StaticPrefs::intl_icu4x_segmenter_enabled()) {
|
||||
if (aLength == 1) {
|
||||
// Although UAX#14 LB2 rule requires never breaking at the start of text
|
||||
// (SOT), ICU4X line segmenter API is designed to match other segmenter in
|
||||
// UAX#29 to always break at the start of text. Hence the optimization
|
||||
// here to avoid calling into ICU4X line segmenter.
|
||||
aBreakBefore[0] = 1;
|
||||
return;
|
||||
}
|
||||
|
||||
memset(aBreakBefore, 0, aLength);
|
||||
|
||||
CheckedInt<int32_t> length = aLength;
|
||||
|
@ -1253,6 +1262,15 @@ void LineBreaker::ComputeBreakPositions(const uint8_t* aChars, uint32_t aLength,
|
|||
uint8_t* aBreakBefore) {
|
||||
#if defined(MOZ_ICU4X) && defined(JS_HAS_INTL_API)
|
||||
if (StaticPrefs::intl_icu4x_segmenter_enabled()) {
|
||||
if (aLength == 1) {
|
||||
// Although UAX#14 LB2 rule requires never breaking at the start of text
|
||||
// (SOT), ICU4X line segmenter API is designed to match other segmenter in
|
||||
// UAX#29 to always break at the start of text. Hence the optimization
|
||||
// here to avoid calling into ICU4X line segmenter.
|
||||
aBreakBefore[0] = 1;
|
||||
return;
|
||||
}
|
||||
|
||||
memset(aBreakBefore, 0, aLength);
|
||||
|
||||
CheckedInt<int32_t> length = aLength;
|
||||
|
|
|
@ -5,24 +5,24 @@
|
|||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
LOCAL_INCLUDES += [
|
||||
'!/ipc/ipdl/_ipdlheaders',
|
||||
'/ipc/chromium/src',
|
||||
"!/ipc/ipdl/_ipdlheaders",
|
||||
"/ipc/chromium/src",
|
||||
]
|
||||
|
||||
if CONFIG['OS_ARCH'] == 'WINNT':
|
||||
if CONFIG["OS_ARCH"] == "WINNT":
|
||||
OS_LIBS += [
|
||||
'shell32',
|
||||
'dbghelp',
|
||||
"shell32",
|
||||
"dbghelp",
|
||||
]
|
||||
|
||||
DEFINES['UNICODE'] = True
|
||||
DEFINES['_UNICODE'] = True
|
||||
DEFINES['_CRT_RAND_S'] = True
|
||||
DEFINES['CERT_CHAIN_PARA_HAS_EXTRA_FIELDS'] = True
|
||||
DEFINES['_SECURE_ATL'] = True
|
||||
DEFINES['CHROMIUM_BUILD'] = True
|
||||
DEFINES['U_STATIC_IMPLEMENTATION'] = True
|
||||
DEFINES['WIN32'] = True
|
||||
DEFINES['_WIN32'] = True
|
||||
DEFINES['_WINDOWS'] = True
|
||||
DEFINES['WIN32_LEAN_AND_MEAN'] = True
|
||||
DEFINES["UNICODE"] = True
|
||||
DEFINES["_UNICODE"] = True
|
||||
DEFINES["_CRT_RAND_S"] = True
|
||||
DEFINES["CERT_CHAIN_PARA_HAS_EXTRA_FIELDS"] = True
|
||||
DEFINES["_SECURE_ATL"] = True
|
||||
DEFINES["CHROMIUM_BUILD"] = True
|
||||
DEFINES["U_STATIC_IMPLEMENTATION"] = True
|
||||
DEFINES["WIN32"] = True
|
||||
DEFINES["_WIN32"] = True
|
||||
DEFINES["_WINDOWS"] = True
|
||||
DEFINES["WIN32_LEAN_AND_MEAN"] = True
|
||||
|
|
|
@ -4,41 +4,40 @@
|
|||
# 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/.
|
||||
|
||||
if CONFIG['COMPILE_ENVIRONMENT']:
|
||||
if CONFIG["COMPILE_ENVIRONMENT"]:
|
||||
DIRS += [
|
||||
'/js/src',
|
||||
"/js/src",
|
||||
]
|
||||
else:
|
||||
TEST_DIRS += [
|
||||
'/js/src/tests',
|
||||
"/js/src/tests",
|
||||
]
|
||||
|
||||
if CONFIG['JS_STANDALONE'] and CONFIG['OS_ARCH'] != 'WINNT':
|
||||
if CONFIG["JS_STANDALONE"] and CONFIG["OS_ARCH"] != "WINNT":
|
||||
DIRS += [
|
||||
'/build/unix',
|
||||
"/build/unix",
|
||||
]
|
||||
|
||||
DIRS += [
|
||||
'/config/external/fdlibm',
|
||||
'/config/external/nspr',
|
||||
'/config/external/zlib',
|
||||
'/memory',
|
||||
'/mfbt',
|
||||
'/mozglue',
|
||||
"/config/external/fdlibm",
|
||||
"/config/external/nspr",
|
||||
"/config/external/zlib",
|
||||
"/memory",
|
||||
"/mfbt",
|
||||
"/mozglue",
|
||||
]
|
||||
|
||||
if CONFIG['JS_HAS_INTL_API']:
|
||||
if CONFIG["JS_HAS_INTL_API"]:
|
||||
DIRS += [
|
||||
'/config/external/icu',
|
||||
"/config/external/icu",
|
||||
]
|
||||
|
||||
if CONFIG['COMPILE_ENVIRONMENT'] and CONFIG['BUILD_CTYPES']:
|
||||
if CONFIG["COMPILE_ENVIRONMENT"] and CONFIG["BUILD_CTYPES"]:
|
||||
DIRS += [
|
||||
'/config/external/ffi',
|
||||
"/config/external/ffi",
|
||||
]
|
||||
|
||||
if CONFIG['JS_STANDALONE'] and CONFIG['FUZZING']:
|
||||
if CONFIG["JS_STANDALONE"] and CONFIG["FUZZING"]:
|
||||
DIRS += [
|
||||
'/tools/fuzzing/',
|
||||
"/tools/fuzzing/",
|
||||
]
|
||||
|
||||
|
|
|
@ -556,9 +556,11 @@ using JSHostCleanupFinalizationRegistryCallback =
|
|||
*/
|
||||
struct JSExternalStringCallbacks {
|
||||
/**
|
||||
* Finalizes external strings created by JS_NewExternalString. The finalizer
|
||||
* can be called off the main thread.
|
||||
* Finalizes external strings created by JS_NewExternalStringLatin1 or
|
||||
* JS_NewExternalUCString. The finalizer can be called off the main
|
||||
* thread.
|
||||
*/
|
||||
virtual void finalize(JS::Latin1Char* chars) const = 0;
|
||||
virtual void finalize(char16_t* chars) const = 0;
|
||||
|
||||
/**
|
||||
|
@ -569,6 +571,8 @@ struct JSExternalStringCallbacks {
|
|||
*
|
||||
* Implementations of this callback MUST NOT do anything that can cause GC.
|
||||
*/
|
||||
virtual size_t sizeOfBuffer(const JS::Latin1Char* chars,
|
||||
mozilla::MallocSizeOf mallocSizeOf) const = 0;
|
||||
virtual size_t sizeOfBuffer(const char16_t* chars,
|
||||
mozilla::MallocSizeOf mallocSizeOf) const = 0;
|
||||
};
|
||||
|
@ -1269,7 +1273,10 @@ extern JS_PUBLIC_API void JS_SetGCParametersBasedOnAvailableMemory(
|
|||
* Create a new JSString whose chars member refers to external memory, i.e.,
|
||||
* memory requiring application-specific finalization.
|
||||
*/
|
||||
extern JS_PUBLIC_API JSString* JS_NewExternalString(
|
||||
extern JS_PUBLIC_API JSString* JS_NewExternalStringLatin1(
|
||||
JSContext* cx, const JS::Latin1Char* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks);
|
||||
extern JS_PUBLIC_API JSString* JS_NewExternalUCString(
|
||||
JSContext* cx, const char16_t* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks);
|
||||
|
||||
|
@ -1280,13 +1287,17 @@ extern JS_PUBLIC_API JSString* JS_NewExternalString(
|
|||
* external string allocated by a previous call and |*allocatedExternal| is set
|
||||
* to false. If |*allocatedExternal| is false, |fin| won't be called.
|
||||
*/
|
||||
extern JS_PUBLIC_API JSString* JS_NewMaybeExternalString(
|
||||
extern JS_PUBLIC_API JSString* JS_NewMaybeExternalStringLatin1(
|
||||
JSContext* cx, const JS::Latin1Char* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks, bool* allocatedExternal);
|
||||
extern JS_PUBLIC_API JSString* JS_NewMaybeExternalUCString(
|
||||
JSContext* cx, const char16_t* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks, bool* allocatedExternal);
|
||||
|
||||
/**
|
||||
* Return the 'callbacks' arg passed to JS_NewExternalString or
|
||||
* JS_NewMaybeExternalString.
|
||||
* Return the 'callbacks' arg passed to JS_NewExternalStringLatin1,
|
||||
* JS_NewExternalUCString, JS_NewMaybeExternalStringLatin1,
|
||||
* or JS_NewMaybeExternalUCString.
|
||||
*/
|
||||
extern JS_PUBLIC_API const JSExternalStringCallbacks*
|
||||
JS_GetExternalStringCallbacks(JSString* str);
|
||||
|
|
|
@ -392,17 +392,37 @@ MOZ_ALWAYS_INLINE JSLinearString* AtomToLinearString(JSAtom* atom) {
|
|||
}
|
||||
|
||||
/**
|
||||
* If the provided string uses externally-managed storage, return true and set
|
||||
* |*callbacks| to the external-string callbacks used to create it and |*chars|
|
||||
* to a pointer to its two-byte storage. (These pointers remain valid as long
|
||||
* as the provided string is kept alive.)
|
||||
* If the provided string uses externally-managed latin-1 storage, return true
|
||||
* and set |*callbacks| to the external-string callbacks used to create it and
|
||||
* |*chars| to a pointer to its latin1 storage. (These pointers remain valid
|
||||
* as long as the provided string is kept alive.)
|
||||
*/
|
||||
MOZ_ALWAYS_INLINE bool IsExternalString(
|
||||
MOZ_ALWAYS_INLINE bool IsExternalStringLatin1(
|
||||
JSString* str, const JSExternalStringCallbacks** callbacks,
|
||||
const JS::Latin1Char** chars) {
|
||||
shadow::String* s = shadow::AsShadowString(str);
|
||||
|
||||
if (!s->isExternal() || !s->hasLatin1Chars()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
*callbacks = s->externalCallbacks;
|
||||
*chars = s->nonInlineCharsLatin1;
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* If the provided string uses externally-managed two-byte storage, return true
|
||||
* and set |*callbacks| to the external-string callbacks used to create it and
|
||||
* |*chars| to a pointer to its two-byte storage. (These pointers remain valid
|
||||
* as long as the provided string is kept alive.)
|
||||
*/
|
||||
MOZ_ALWAYS_INLINE bool IsExternalUCString(
|
||||
JSString* str, const JSExternalStringCallbacks** callbacks,
|
||||
const char16_t** chars) {
|
||||
shadow::String* s = shadow::AsShadowString(str);
|
||||
|
||||
if (!s->isExternal()) {
|
||||
if (!s->isExternal() || s->hasLatin1Chars()) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -3419,7 +3419,12 @@ static bool AddWatchtowerTarget(JSContext* cx, unsigned argc, Value* vp) {
|
|||
}
|
||||
|
||||
struct TestExternalString : public JSExternalStringCallbacks {
|
||||
void finalize(JS::Latin1Char* chars) const override { js_free(chars); }
|
||||
void finalize(char16_t* chars) const override { js_free(chars); }
|
||||
size_t sizeOfBuffer(const JS::Latin1Char* chars,
|
||||
mozilla::MallocSizeOf mallocSizeOf) const override {
|
||||
return mallocSizeOf(chars);
|
||||
}
|
||||
size_t sizeOfBuffer(const char16_t* chars,
|
||||
mozilla::MallocSizeOf mallocSizeOf) const override {
|
||||
return mallocSizeOf(chars);
|
||||
|
|
|
@ -92,13 +92,25 @@ class MOZ_NON_TEMPORARY_CLASS ExternalStringCache {
|
|||
inlineEntries_ = {};
|
||||
}
|
||||
|
||||
MOZ_ALWAYS_INLINE JSExternalString* lookupExternal(
|
||||
const JS::Latin1Char* chars, size_t len) const;
|
||||
MOZ_ALWAYS_INLINE JSExternalString* lookupExternal(const char16_t* chars,
|
||||
size_t len) const;
|
||||
MOZ_ALWAYS_INLINE void putExternal(JSExternalString* s);
|
||||
|
||||
MOZ_ALWAYS_INLINE JSInlineString* lookupInline(const JS::Latin1Char* chars,
|
||||
size_t len) const;
|
||||
MOZ_ALWAYS_INLINE JSInlineString* lookupInline(const char16_t* chars,
|
||||
size_t len) const;
|
||||
MOZ_ALWAYS_INLINE void putInline(JSInlineString* s);
|
||||
|
||||
private:
|
||||
template <typename CharT>
|
||||
MOZ_ALWAYS_INLINE JSExternalString* lookupExternalImpl(const CharT* chars,
|
||||
size_t len) const;
|
||||
template <typename CharT>
|
||||
MOZ_ALWAYS_INLINE JSInlineString* lookupInlineImpl(const CharT* chars,
|
||||
size_t len) const;
|
||||
};
|
||||
|
||||
class MOZ_NON_TEMPORARY_CLASS FunctionToStringCache {
|
||||
|
|
|
@ -161,3 +161,73 @@
|
|||
assertErrorMessage(() => importGlobalIntoType(mut_any, `(mut eqref)`), WebAssembly.LinkError, /global type mismatch/);
|
||||
importGlobalIntoType(mut_any, `(mut anyref)`);
|
||||
}
|
||||
|
||||
// Importing globals with ref types
|
||||
{
|
||||
const { struct, array, func } = wasmEvalText(`(module
|
||||
(type (struct))
|
||||
(type (array i32))
|
||||
(func $f)
|
||||
(global (export "struct") structref (struct.new 0))
|
||||
(global (export "array") arrayref (array.new_fixed 1 0))
|
||||
(global (export "func") funcref (ref.func $f))
|
||||
)`).exports;
|
||||
|
||||
function importValueIntoType(v, t) {
|
||||
wasmEvalText(`(module
|
||||
(global (import "test" "v") ${t})
|
||||
)`, { "test": { "v": v } });
|
||||
}
|
||||
|
||||
assertErrorMessage(() => importValueIntoType(struct.value, `(mut structref)`), WebAssembly.LinkError, /global mutability mismatch/);
|
||||
|
||||
importValueIntoType(null, `structref`);
|
||||
assertErrorMessage(() => importValueIntoType(null, `(ref struct)`), TypeError, /cannot pass null/);
|
||||
assertErrorMessage(() => importValueIntoType(0, `structref`), TypeError, /can only pass/);
|
||||
importValueIntoType(struct.value, `structref`);
|
||||
assertErrorMessage(() => importValueIntoType(array.value, `structref`), TypeError, /can only pass/);
|
||||
|
||||
importValueIntoType(null, `i31ref`);
|
||||
assertErrorMessage(() => importValueIntoType(null, `(ref i31)`), TypeError, /cannot pass null/);
|
||||
importValueIntoType(0, `i31ref`);
|
||||
assertErrorMessage(() => importValueIntoType(0.1, `i31ref`), TypeError, /can only pass/);
|
||||
assertErrorMessage(() => importValueIntoType("test", `i31ref`), TypeError, /can only pass/);
|
||||
assertErrorMessage(() => importValueIntoType(struct.value, `i31ref`), TypeError, /can only pass/);
|
||||
|
||||
importValueIntoType(null, `eqref`);
|
||||
assertErrorMessage(() => importValueIntoType(null, `(ref eq)`), TypeError, /cannot pass null/);
|
||||
assertErrorMessage(() => importValueIntoType(undefined, `(ref eq)`), TypeError, /can only pass/);
|
||||
importValueIntoType(0, `eqref`);
|
||||
assertErrorMessage(() => importValueIntoType(0.1, `eqref`), TypeError, /can only pass/);
|
||||
assertErrorMessage(() => importValueIntoType((x)=>x, `eqref`), TypeError, /can only pass/);
|
||||
assertErrorMessage(() => importValueIntoType("test", `eqref`), TypeError, /can only pass/);
|
||||
importValueIntoType(struct.value, `eqref`);
|
||||
assertErrorMessage(() => importValueIntoType(func.value, `eqref`), TypeError, /can only pass/);
|
||||
|
||||
importValueIntoType(null, `anyref`);
|
||||
assertErrorMessage(() => importValueIntoType(null, `(ref any)`), TypeError, /cannot pass null/);
|
||||
importValueIntoType(undefined, `(ref any)`);
|
||||
importValueIntoType(0, `anyref`);
|
||||
importValueIntoType(0.1, `anyref`);
|
||||
importValueIntoType((x)=>x, `anyref`)
|
||||
importValueIntoType("test", `anyref`);
|
||||
importValueIntoType(struct.value, `anyref`);
|
||||
importValueIntoType(func.value, `anyref`);
|
||||
|
||||
importValueIntoType(null, `externref`);
|
||||
assertErrorMessage(() => importValueIntoType(null, `(ref extern)`), TypeError, /cannot pass null/);
|
||||
importValueIntoType(undefined, `(ref extern)`);
|
||||
importValueIntoType(0, `externref`);
|
||||
importValueIntoType(0.1, `externref`);
|
||||
importValueIntoType((x)=>x, `externref`)
|
||||
importValueIntoType("test", `externref`);
|
||||
importValueIntoType(struct.value, `externref`);
|
||||
importValueIntoType(func.value, `externref`);
|
||||
|
||||
importValueIntoType(null, `funcref`);
|
||||
assertErrorMessage(() => importValueIntoType(null, `(ref func)`), TypeError, /cannot pass null/);
|
||||
assertErrorMessage(() => importValueIntoType(0, `funcref`), TypeError, /can only pass/);
|
||||
assertErrorMessage(() => importValueIntoType((x)=>x, `funcref`), TypeError, /can only pass/);
|
||||
importValueIntoType(func.value, `funcref`)
|
||||
importValueIntoType(func.value, `(ref func)`)
|
||||
}
|
||||
|
|
|
@ -305,6 +305,157 @@ def arm64_simulator_dispatch(func_types):
|
|||
return contents
|
||||
|
||||
|
||||
# Generate the LoongArch64 argument loading for a func type
|
||||
def loongarch64_args(func_type):
|
||||
# This must match ABIArgGenerator::next() in Assembler-loong64.cpp
|
||||
contents = ""
|
||||
numIntArgRegs = 8
|
||||
numFloatArgRegs = 8
|
||||
intRegIndex = 0
|
||||
floatRegIndex = 0
|
||||
stackOffset = 0
|
||||
for i, arg in enumerate(func_type["args"]):
|
||||
if i != 0:
|
||||
contents += ", "
|
||||
|
||||
if arg == "General":
|
||||
if intRegIndex == numIntArgRegs:
|
||||
contents += f"sp_[{stackOffset}]"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"a{intRegIndex}_"
|
||||
intRegIndex += 1
|
||||
elif arg == "Int32":
|
||||
if intRegIndex == numIntArgRegs:
|
||||
contents += f"I32(sp_[{stackOffset}])"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"I32(a{intRegIndex}_)"
|
||||
intRegIndex += 1
|
||||
elif arg == "Int64":
|
||||
if intRegIndex == numIntArgRegs:
|
||||
contents += f"sp_[{stackOffset}]"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"a{intRegIndex}_"
|
||||
intRegIndex += 1
|
||||
elif arg == "Float32":
|
||||
if floatRegIndex == numFloatArgRegs:
|
||||
contents += f"*mozilla::BitwiseCast<float*>(sp_[{stackOffset}])"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"f{floatRegIndex}_s"
|
||||
floatRegIndex += 1
|
||||
elif arg == "Float64":
|
||||
if floatRegIndex == numFloatArgRegs:
|
||||
contents += f"mozilla::BitwiseCast<double>(sp_[{stackOffset}])"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"f{floatRegIndex}_d"
|
||||
floatRegIndex += 1
|
||||
assert intRegIndex <= numIntArgRegs
|
||||
assert floatRegIndex <= numFloatArgRegs
|
||||
return contents
|
||||
|
||||
|
||||
def loongarch64_simulator_dispatch(func_types):
|
||||
contents = ""
|
||||
for func_type in func_types:
|
||||
args = loongarch64_args(func_type)
|
||||
contents += f"case js::jit::Args_{func_type_name(func_type)}: {{\\\n"
|
||||
contents += f" auto target = reinterpret_cast<Prototype_{func_type_name(func_type)}>(nativeFn);\\\n"
|
||||
contents += f" auto ret = target({args});\\\n"
|
||||
ret = func_type["ret"]
|
||||
if ret == "General":
|
||||
contents += " setCallResult(ret);\\\n"
|
||||
elif ret == "Int32":
|
||||
contents += " setCallResult(I64(ret));\\\n"
|
||||
elif ret == "Int64":
|
||||
contents += " setCallResult(ret);\\\n"
|
||||
elif ret == "Float32":
|
||||
contents += " setCallResultFloat(ret);\\\n"
|
||||
elif ret == "Float64":
|
||||
contents += " setCallResultDouble(ret);\\\n"
|
||||
contents += " break;\\\n"
|
||||
contents += "}\\\n"
|
||||
return contents
|
||||
|
||||
|
||||
# Generate the MIPS64 argument loading for a func type
|
||||
def mips64_args(func_type):
|
||||
# This must match ABIArgGenerator::next() in Assembler-mips64.cpp
|
||||
contents = ""
|
||||
numIntArgRegs = 8
|
||||
numFloatArgRegs = 8
|
||||
regIndex = 0
|
||||
stackOffset = 0
|
||||
for i, arg in enumerate(func_type["args"]):
|
||||
if i != 0:
|
||||
contents += ", "
|
||||
|
||||
if arg == "General":
|
||||
if regIndex == numIntArgRegs:
|
||||
contents += f"sp_[{stackOffset}]"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"a{regIndex}_"
|
||||
regIndex += 1
|
||||
elif arg == "Int32":
|
||||
if regIndex == numIntArgRegs:
|
||||
contents += f"I32(sp_[{stackOffset}])"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"I32(a{regIndex}_)"
|
||||
regIndex += 1
|
||||
elif arg == "Int64":
|
||||
if regIndex == numIntArgRegs:
|
||||
contents += f"sp_[{stackOffset}]"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"a{regIndex}_"
|
||||
regIndex += 1
|
||||
elif arg == "Float32":
|
||||
if regIndex == numFloatArgRegs:
|
||||
contents += f"*mozilla::BitwiseCast<float*>(sp_[{stackOffset}])"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"f{regIndex + 12}_s"
|
||||
regIndex += 1
|
||||
elif arg == "Float64":
|
||||
if regIndex == numFloatArgRegs:
|
||||
contents += f"mozilla::BitwiseCast<double>(sp_[{stackOffset}])"
|
||||
stackOffset += 1
|
||||
else:
|
||||
contents += f"f{regIndex + 12}_d"
|
||||
regIndex += 1
|
||||
assert regIndex <= numIntArgRegs
|
||||
assert numIntArgRegs == numFloatArgRegs
|
||||
return contents
|
||||
|
||||
|
||||
def mips64_simulator_dispatch(func_types):
|
||||
contents = ""
|
||||
for func_type in func_types:
|
||||
args = mips64_args(func_type)
|
||||
contents += f"case js::jit::Args_{func_type_name(func_type)}: {{\\\n"
|
||||
contents += f" auto target = reinterpret_cast<Prototype_{func_type_name(func_type)}>(nativeFn);\\\n"
|
||||
contents += f" auto ret = target({args});\\\n"
|
||||
ret = func_type["ret"]
|
||||
if ret == "General":
|
||||
contents += " setCallResult(ret);\\\n"
|
||||
elif ret == "Int32":
|
||||
contents += " setCallResult(I64(ret));\\\n"
|
||||
elif ret == "Int64":
|
||||
contents += " setCallResult(ret);\\\n"
|
||||
elif ret == "Float32":
|
||||
contents += " setCallResultFloat(ret);\\\n"
|
||||
elif ret == "Float64":
|
||||
contents += " setCallResultDouble(ret);\\\n"
|
||||
contents += " break;\\\n"
|
||||
contents += "}\\\n"
|
||||
return contents
|
||||
|
||||
|
||||
def main(c_out, yaml_path):
|
||||
func_types = load_yaml(yaml_path)
|
||||
|
||||
|
@ -336,4 +487,12 @@ def main(c_out, yaml_path):
|
|||
contents += arm32_simulator_dispatch(func_types)
|
||||
contents += "\n"
|
||||
|
||||
contents += "#define ABI_FUNCTION_TYPE_LOONGARCH64_SIM_DISPATCH \\\n"
|
||||
contents += loongarch64_simulator_dispatch(func_types)
|
||||
contents += "\n"
|
||||
|
||||
contents += "#define ABI_FUNCTION_TYPE_MIPS64_SIM_DISPATCH \\\n"
|
||||
contents += mips64_simulator_dispatch(func_types)
|
||||
contents += "\n"
|
||||
|
||||
generate_header(c_out, "jit_ABIFunctionTypeGenerated_h", contents)
|
||||
|
|
|
@ -139,14 +139,15 @@ DefaultJitOptions::DefaultJitOptions() {
|
|||
SET_DEFAULT(portableBaselineInterpreterWarmUpThreshold, 0);
|
||||
#endif
|
||||
|
||||
// Emit baseline interpreter and interpreter entry frames to distinguish which
|
||||
// JSScript is being interpreted by external profilers.
|
||||
// Enabled by default under --enable-perf, otherwise disabled.
|
||||
#if defined(JS_ION_PERF)
|
||||
SET_DEFAULT(emitInterpreterEntryTrampoline, true);
|
||||
#else
|
||||
SET_DEFAULT(emitInterpreterEntryTrampoline, false);
|
||||
#endif
|
||||
// emitInterpreterEntryTrampoline and enableICFramePointers are used in
|
||||
// combination with perf jitdump profiling. The first will enable
|
||||
// trampolines for interpreter and baseline interpreter frames to
|
||||
// identify which function is being executed, and the latter enables
|
||||
// frame pointers for IC stubs. They are both enabled by default
|
||||
// when the |IONPERF| environment variable is set.
|
||||
bool perfEnabled = !!getenv("IONPERF");
|
||||
SET_DEFAULT(emitInterpreterEntryTrampoline, perfEnabled);
|
||||
SET_DEFAULT(enableICFramePointers, perfEnabled);
|
||||
|
||||
// Whether the Baseline JIT is enabled.
|
||||
SET_DEFAULT(baselineJit, true);
|
||||
|
@ -350,7 +351,6 @@ DefaultJitOptions::DefaultJitOptions() {
|
|||
SET_DEFAULT(enableWatchtowerMegamorphic, true);
|
||||
|
||||
SET_DEFAULT(onlyInlineSelfHosted, false);
|
||||
SET_DEFAULT(enableICFramePointers, false);
|
||||
|
||||
SET_DEFAULT(enableWasmJitExit, true);
|
||||
SET_DEFAULT(enableWasmJitEntry, true);
|
||||
|
|
|
@ -2145,127 +2145,6 @@ void Simulator::format(SimInstruction* instr, const char* format) {
|
|||
MOZ_CRASH();
|
||||
}
|
||||
|
||||
// Note: With the code below we assume that all runtime calls return a 64 bits
|
||||
// result. If they don't, the a1 result register contains a bogus value, which
|
||||
// is fine because it is caller-saved.
|
||||
typedef int64_t (*Prototype_General0)();
|
||||
typedef int64_t (*Prototype_General1)(int64_t arg0);
|
||||
typedef int64_t (*Prototype_General2)(int64_t arg0, int64_t arg1);
|
||||
typedef int64_t (*Prototype_General3)(int64_t arg0, int64_t arg1, int64_t arg2);
|
||||
typedef int64_t (*Prototype_General4)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3);
|
||||
typedef int64_t (*Prototype_General5)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4);
|
||||
typedef int64_t (*Prototype_General6)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4, int64_t arg5);
|
||||
typedef int64_t (*Prototype_General7)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4, int64_t arg5,
|
||||
int64_t arg6);
|
||||
typedef int64_t (*Prototype_General8)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4, int64_t arg5,
|
||||
int64_t arg6, int64_t arg7);
|
||||
typedef int64_t (*Prototype_GeneralGeneralGeneralInt64)(int64_t arg0,
|
||||
int64_t arg1,
|
||||
int64_t arg2,
|
||||
int64_t arg3);
|
||||
typedef int64_t (*Prototype_GeneralGeneralInt64Int64)(int64_t arg0,
|
||||
int64_t arg1,
|
||||
int64_t arg2,
|
||||
int64_t arg3);
|
||||
typedef int64_t (*Prototype_Int_Float32)(float arg0);
|
||||
typedef int64_t (*Prototype_Int_Double)(double arg0);
|
||||
typedef int64_t (*Prototype_Int_IntDouble)(int64_t arg0, double arg1);
|
||||
typedef int64_t (*Prototype_Int_DoubleInt)(double arg0, int64_t arg1);
|
||||
typedef int64_t (*Prototype_Int_DoubleIntInt)(double arg0, int64_t arg1,
|
||||
int64_t arg2);
|
||||
typedef int64_t (*Prototype_Int_IntDoubleIntInt)(int64_t arg0, double arg1,
|
||||
int64_t arg2, int64_t arg3);
|
||||
|
||||
typedef float (*Prototype_Float32_Float32)(float arg0);
|
||||
typedef float (*Prototype_Float32_Float32Float32)(float arg0, float arg1);
|
||||
|
||||
typedef double (*Prototype_Double_None)();
|
||||
typedef double (*Prototype_Double_Double)(double arg0);
|
||||
typedef double (*Prototype_Double_Int)(int64_t arg0);
|
||||
typedef double (*Prototype_Double_DoubleInt)(double arg0, int64_t arg1);
|
||||
typedef double (*Prototype_Double_IntDouble)(int64_t arg0, double arg1);
|
||||
typedef double (*Prototype_Double_DoubleDouble)(double arg0, double arg1);
|
||||
typedef double (*Prototype_Double_DoubleDoubleDouble)(double arg0, double arg1,
|
||||
double arg2);
|
||||
typedef double (*Prototype_Double_DoubleDoubleDoubleDouble)(double arg0,
|
||||
double arg1,
|
||||
double arg2,
|
||||
double arg3);
|
||||
|
||||
typedef int32_t (*Prototype_Int32_General)(int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32)(int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32)(int64_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32)(int64_t, int32_t,
|
||||
int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32Int32)(int64_t, int32_t,
|
||||
int32_t, int32_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32Int32Int32)(
|
||||
int64_t, int32_t, int32_t, int32_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32Int32General)(
|
||||
int64_t, int32_t, int32_t, int32_t, int32_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32General)(
|
||||
int64_t, int32_t, int32_t, int32_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32General)(int64_t, int32_t,
|
||||
int32_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int64Int32)(int64_t, int32_t,
|
||||
int32_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32GeneralInt32)(int64_t, int32_t,
|
||||
int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32GeneralInt32Int32)(
|
||||
int64_t, int32_t, int64_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int64Int64Int32)(int64_t, int32_t,
|
||||
int64_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneral)(int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralGeneral)(int64_t, int64_t,
|
||||
int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32Int32)(int64_t, int64_t,
|
||||
int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int32)(int64_t, int64_t,
|
||||
int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int32Int32Int32)(
|
||||
int64_t, int64_t, int32_t, int32_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int64Int32)(int64_t, int64_t,
|
||||
int32_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int64General)(
|
||||
int64_t, int64_t, int32_t, int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64)(int64_t, int64_t,
|
||||
int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64Int32)(int64_t, int64_t,
|
||||
int64_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64General)(int64_t, int64_t,
|
||||
int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64General)(
|
||||
int64_t, int64_t, int64_t, int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64Int32Int32)(
|
||||
int64_t, int64_t, int64_t, int64_t, int32_t, int32_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32)(int64_t, int32_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32Int32)(int64_t, int32_t,
|
||||
int32_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32General)(int64_t, int32_t,
|
||||
int64_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32Int32GeneralInt32)(
|
||||
int64_t, int32_t, int32_t, int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32GeneralInt32Int32Int32)(
|
||||
int64_t, int64_t, int32_t, int64_t, int32_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32Int32Int32GeneralInt32)(
|
||||
int64_t, int64_t, int32_t, int32_t, int32_t, int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32General)(int64_t, int64_t,
|
||||
int32_t, int64_t);
|
||||
typedef int64_t (*Prototype_Int64_General)(int64_t);
|
||||
typedef int64_t (*Prototype_Int64_GeneralInt32)(int64_t, int32_t);
|
||||
typedef int64_t (*Prototype_Int64_GeneralInt64)(int64_t, int64_t);
|
||||
typedef int64_t (*Prototype_Int64_GeneralInt64Int32)(int64_t, int64_t, int32_t);
|
||||
|
||||
inline int32_t Simulator::rj_reg(SimInstruction* instr) const {
|
||||
return instr->rjValue();
|
||||
}
|
||||
|
@ -2430,6 +2309,8 @@ inline int32_t Simulator::si20(SimInstruction* instr) const {
|
|||
return (instr->imm20Value() << 12) >> 12;
|
||||
}
|
||||
|
||||
ABI_FUNCTION_TYPE_SIM_PROTOTYPES
|
||||
|
||||
// Software interrupt instructions are used by the simulator to call into C++.
|
||||
void Simulator::softwareInterrupt(SimInstruction* instr) {
|
||||
// the break_ instruction could get us here.
|
||||
|
@ -2442,20 +2323,32 @@ void Simulator::softwareInterrupt(SimInstruction* instr) {
|
|||
uintptr_t nativeFn =
|
||||
reinterpret_cast<uintptr_t>(redirection->nativeFunction());
|
||||
|
||||
int64_t arg0 = getRegister(a0);
|
||||
int64_t arg1 = getRegister(a1);
|
||||
int64_t arg2 = getRegister(a2);
|
||||
int64_t arg3 = getRegister(a3);
|
||||
int64_t arg4 = getRegister(a4);
|
||||
int64_t arg5 = getRegister(a5);
|
||||
// Get the SP for reading stack arguments
|
||||
int64_t* sp_ = reinterpret_cast<int64_t*>(getRegister(sp));
|
||||
|
||||
// Store argument register values in local variables for ease of use below.
|
||||
int64_t a0_ = getRegister(a0);
|
||||
int64_t a1_ = getRegister(a1);
|
||||
int64_t a2_ = getRegister(a2);
|
||||
int64_t a3_ = getRegister(a3);
|
||||
int64_t a4_ = getRegister(a4);
|
||||
int64_t a5_ = getRegister(a5);
|
||||
int64_t a6_ = getRegister(a6);
|
||||
int64_t a7_ = getRegister(a7);
|
||||
float f0_s = getFpuRegisterFloat(f0);
|
||||
float f1_s = getFpuRegisterFloat(f1);
|
||||
float f2_s = getFpuRegisterFloat(f2);
|
||||
float f3_s = getFpuRegisterFloat(f3);
|
||||
float f4_s = getFpuRegisterFloat(f4);
|
||||
double f0_d = getFpuRegisterDouble(f0);
|
||||
double f1_d = getFpuRegisterDouble(f1);
|
||||
double f2_d = getFpuRegisterDouble(f2);
|
||||
double f3_d = getFpuRegisterDouble(f3);
|
||||
|
||||
// This is dodgy but it works because the C entry stubs are never moved.
|
||||
// See comment in codegen-arm.cc and bug 1242173.
|
||||
int64_t saved_ra = getRegister(ra);
|
||||
|
||||
intptr_t external =
|
||||
reinterpret_cast<intptr_t>(redirection->nativeFunction());
|
||||
|
||||
bool stack_aligned = (getRegister(sp) & (ABIStackAlignment - 1)) == 0;
|
||||
if (!stack_aligned) {
|
||||
fprintf(stderr, "Runtime call with unaligned stack!\n");
|
||||
|
@ -2467,477 +2360,8 @@ void Simulator::softwareInterrupt(SimInstruction* instr) {
|
|||
}
|
||||
|
||||
switch (redirection->type()) {
|
||||
case Args_General0: {
|
||||
Prototype_General0 target =
|
||||
reinterpret_cast<Prototype_General0>(external);
|
||||
int64_t result = target();
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General1: {
|
||||
Prototype_General1 target =
|
||||
reinterpret_cast<Prototype_General1>(external);
|
||||
int64_t result = target(arg0);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General2: {
|
||||
Prototype_General2 target =
|
||||
reinterpret_cast<Prototype_General2>(external);
|
||||
int64_t result = target(arg0, arg1);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General3: {
|
||||
Prototype_General3 target =
|
||||
reinterpret_cast<Prototype_General3>(external);
|
||||
int64_t result = target(arg0, arg1, arg2);
|
||||
if (external == intptr_t(&js::wasm::Instance::wake_m32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General4: {
|
||||
Prototype_General4 target =
|
||||
reinterpret_cast<Prototype_General4>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General5: {
|
||||
Prototype_General5 target =
|
||||
reinterpret_cast<Prototype_General5>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General6: {
|
||||
Prototype_General6 target =
|
||||
reinterpret_cast<Prototype_General6>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4, arg5);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General7: {
|
||||
Prototype_General7 target =
|
||||
reinterpret_cast<Prototype_General7>(external);
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4, arg5, arg6);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General8: {
|
||||
Prototype_General8 target =
|
||||
reinterpret_cast<Prototype_General8>(external);
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int64_t arg7 = getRegister(a7);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_Double_None: {
|
||||
Prototype_Double_None target =
|
||||
reinterpret_cast<Prototype_Double_None>(external);
|
||||
double dresult = target();
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int_Float32: {
|
||||
float fval0;
|
||||
fval0 = getFpuRegisterFloat(0);
|
||||
Prototype_Int_Float32 target =
|
||||
reinterpret_cast<Prototype_Int_Float32>(external);
|
||||
int64_t result = target(fval0);
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_Double: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
Prototype_Int_Double target =
|
||||
reinterpret_cast<Prototype_Int_Double>(external);
|
||||
int64_t result = target(dval0);
|
||||
if (external == intptr_t((int32_t(*)(double))JS::ToInt32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_GeneralGeneralGeneralInt64: {
|
||||
Prototype_GeneralGeneralGeneralInt64 target =
|
||||
reinterpret_cast<Prototype_GeneralGeneralGeneralInt64>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3);
|
||||
if (external == intptr_t(&js::wasm::Instance::wait_i32_m32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_GeneralGeneralInt64Int64: {
|
||||
Prototype_GeneralGeneralInt64Int64 target =
|
||||
reinterpret_cast<Prototype_GeneralGeneralInt64Int64>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3);
|
||||
if (external == intptr_t(&js::wasm::Instance::wait_i64_m32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_DoubleInt: {
|
||||
double dval = getFpuRegisterDouble(0);
|
||||
Prototype_Int_DoubleInt target =
|
||||
reinterpret_cast<Prototype_Int_DoubleInt>(external);
|
||||
int64_t result = target(dval, arg0);
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_DoubleIntInt: {
|
||||
double dval = getFpuRegisterDouble(0);
|
||||
Prototype_Int_DoubleIntInt target =
|
||||
reinterpret_cast<Prototype_Int_DoubleIntInt>(external);
|
||||
int64_t result = target(dval, arg0, arg1);
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_IntDoubleIntInt: {
|
||||
double dval = getFpuRegisterDouble(0);
|
||||
Prototype_Int_IntDoubleIntInt target =
|
||||
reinterpret_cast<Prototype_Int_IntDoubleIntInt>(external);
|
||||
int64_t result = target(arg0, dval, arg1, arg2);
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Double_Double: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
Prototype_Double_Double target =
|
||||
reinterpret_cast<Prototype_Double_Double>(external);
|
||||
double dresult = target(dval0);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Float32_Float32: {
|
||||
float fval0;
|
||||
fval0 = getFpuRegisterFloat(0);
|
||||
Prototype_Float32_Float32 target =
|
||||
reinterpret_cast<Prototype_Float32_Float32>(external);
|
||||
float fresult = target(fval0);
|
||||
setCallResultFloat(fresult);
|
||||
break;
|
||||
}
|
||||
case Args_Float32_Float32Float32: {
|
||||
float fval0;
|
||||
float fval1;
|
||||
fval0 = getFpuRegisterFloat(0);
|
||||
fval1 = getFpuRegisterFloat(1);
|
||||
Prototype_Float32_Float32Float32 target =
|
||||
reinterpret_cast<Prototype_Float32_Float32Float32>(external);
|
||||
float fresult = target(fval0, fval1);
|
||||
setCallResultFloat(fresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_Int: {
|
||||
Prototype_Double_Int target =
|
||||
reinterpret_cast<Prototype_Double_Int>(external);
|
||||
double dresult = target(arg0);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleInt: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
Prototype_Double_DoubleInt target =
|
||||
reinterpret_cast<Prototype_Double_DoubleInt>(external);
|
||||
double dresult = target(dval0, arg0);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleDouble: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
double dval1 = getFpuRegisterDouble(1);
|
||||
Prototype_Double_DoubleDouble target =
|
||||
reinterpret_cast<Prototype_Double_DoubleDouble>(external);
|
||||
double dresult = target(dval0, dval1);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_IntDouble: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
Prototype_Double_IntDouble target =
|
||||
reinterpret_cast<Prototype_Double_IntDouble>(external);
|
||||
double dresult = target(arg0, dval0);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int_IntDouble: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
Prototype_Int_IntDouble target =
|
||||
reinterpret_cast<Prototype_Int_IntDouble>(external);
|
||||
int64_t result = target(arg0, dval0);
|
||||
setRegister(a0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleDoubleDouble: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
double dval1 = getFpuRegisterDouble(1);
|
||||
double dval2 = getFpuRegisterDouble(2);
|
||||
Prototype_Double_DoubleDoubleDouble target =
|
||||
reinterpret_cast<Prototype_Double_DoubleDoubleDouble>(external);
|
||||
double dresult = target(dval0, dval1, dval2);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleDoubleDoubleDouble: {
|
||||
double dval0 = getFpuRegisterDouble(0);
|
||||
double dval1 = getFpuRegisterDouble(1);
|
||||
double dval2 = getFpuRegisterDouble(2);
|
||||
double dval3 = getFpuRegisterDouble(3);
|
||||
Prototype_Double_DoubleDoubleDoubleDouble target =
|
||||
reinterpret_cast<Prototype_Double_DoubleDoubleDoubleDouble>(
|
||||
external);
|
||||
double dresult = target(dval0, dval1, dval2, dval3);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int32_General: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_General>(nativeFn)(arg0);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt32>(nativeFn)(
|
||||
arg0, I32(arg1));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3), I32(arg4));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32Int32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3), I32(arg4),
|
||||
I32(arg5));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32Int32General: {
|
||||
int32_t ret = reinterpret_cast<
|
||||
Prototype_Int32_GeneralInt32Int32Int32Int32General>(nativeFn)(
|
||||
arg0, I32(arg1), I32(arg2), I32(arg3), I32(arg4), arg5);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32General>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3), arg4);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32General>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), arg3);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int64Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), arg3, I32(arg4));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32GeneralInt32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32GeneralInt32>(
|
||||
nativeFn)(arg0, I32(arg1), arg2, I32(arg3));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32GeneralInt32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32GeneralInt32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), arg2, I32(arg3), I32(arg4));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int64Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int64Int64Int32>(
|
||||
nativeFn)(arg0, I32(arg1), arg2, arg3, I32(arg4));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralGeneral: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralGeneral>(
|
||||
nativeFn)(arg0, arg1);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralGeneralGeneral: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralGeneralGeneral>(
|
||||
nativeFn)(arg0, arg1, arg2);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralGeneralInt32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralGeneralInt32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int32Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int32Int32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3), I32(arg4),
|
||||
I32(arg5));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int64Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3, I32(arg4));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int64General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int64General>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3, arg4);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64Int32>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3, I32(arg4));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64General>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64General>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3, arg4);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64Int32Int32>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3, I32(arg4), I32(arg5));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_General_GeneralInt32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_General_GeneralInt32>(
|
||||
nativeFn)(arg0, I32(arg1));
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case Args_General_GeneralInt32Int32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_General_GeneralInt32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2));
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case Args_General_GeneralInt32General: {
|
||||
int64_t ret = reinterpret_cast<Prototype_General_GeneralInt32General>(
|
||||
nativeFn)(arg0, I32(arg1), arg2);
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_General_GeneralInt32Int32GeneralInt32: {
|
||||
int64_t ret =
|
||||
reinterpret_cast<Prototype_General_GeneralInt32Int32GeneralInt32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), arg3, I32(arg4));
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralGeneralInt32GeneralInt32Int32Int32: {
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int32_t ret = reinterpret_cast<
|
||||
Prototype_Int32_GeneralGeneralInt32GeneralInt32Int32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3, I32(arg4), I32(arg5),
|
||||
I32(arg6));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralGeneralInt32Int32Int32GeneralInt32: {
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int32_t ret = reinterpret_cast<
|
||||
Prototype_Int32_GeneralGeneralInt32Int32Int32GeneralInt32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3), I32(arg4), arg5,
|
||||
I32(arg6));
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralGeneralInt32General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralGeneralInt32General>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3);
|
||||
setRegister(a0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_General: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_General>(nativeFn)(arg0);
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_GeneralInt32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_GeneralInt32>(nativeFn)(
|
||||
arg0, I32(arg1));
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_GeneralInt64: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_GeneralInt64>(nativeFn)(
|
||||
arg0, arg1);
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_GeneralInt64Int32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_GeneralInt64Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2));
|
||||
setRegister(a0, ret);
|
||||
break;
|
||||
}
|
||||
ABI_FUNCTION_TYPE_LOONGARCH64_SIM_DISPATCH
|
||||
|
||||
default:
|
||||
MOZ_CRASH("Unknown function type.");
|
||||
}
|
||||
|
|
|
@ -1908,126 +1908,7 @@ void Simulator::format(SimInstruction* instr, const char* format) {
|
|||
// Note: With the code below we assume that all runtime calls return a 64 bits
|
||||
// result. If they don't, the v1 result register contains a bogus value, which
|
||||
// is fine because it is caller-saved.
|
||||
typedef int64_t (*Prototype_General0)();
|
||||
typedef int64_t (*Prototype_General1)(int64_t arg0);
|
||||
typedef int64_t (*Prototype_General2)(int64_t arg0, int64_t arg1);
|
||||
typedef int64_t (*Prototype_General3)(int64_t arg0, int64_t arg1, int64_t arg2);
|
||||
typedef int64_t (*Prototype_General4)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3);
|
||||
typedef int64_t (*Prototype_General5)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4);
|
||||
typedef int64_t (*Prototype_General6)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4, int64_t arg5);
|
||||
typedef int64_t (*Prototype_General7)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4, int64_t arg5,
|
||||
int64_t arg6);
|
||||
typedef int64_t (*Prototype_General8)(int64_t arg0, int64_t arg1, int64_t arg2,
|
||||
int64_t arg3, int64_t arg4, int64_t arg5,
|
||||
int64_t arg6, int64_t arg7);
|
||||
typedef int64_t (*Prototype_GeneralGeneralGeneralInt64)(int64_t arg0,
|
||||
int64_t arg1,
|
||||
int64_t arg2,
|
||||
int64_t arg3);
|
||||
typedef int64_t (*Prototype_GeneralGeneralInt64Int64)(int64_t arg0,
|
||||
int64_t arg1,
|
||||
int64_t arg2,
|
||||
int64_t arg3);
|
||||
|
||||
typedef int64_t (*Prototype_Int_Double)(double arg0);
|
||||
typedef int64_t (*Prototype_Int_IntDouble)(int64_t arg0, double arg1);
|
||||
typedef int64_t (*Prototype_Int_DoubleInt)(double arg0, int64_t arg1);
|
||||
typedef int64_t (*Prototype_Int_DoubleIntInt)(double arg0, int64_t arg1,
|
||||
int64_t arg2);
|
||||
typedef int64_t (*Prototype_Int_IntDoubleIntInt)(int64_t arg0, double arg1,
|
||||
int64_t arg2, int64_t arg3);
|
||||
|
||||
typedef float (*Prototype_Float32_Float32)(float arg0);
|
||||
typedef int64_t (*Prototype_Int_Float32)(float arg0);
|
||||
typedef float (*Prototype_Float32_Float32Float32)(float arg0, float arg1);
|
||||
|
||||
typedef double (*Prototype_Double_None)();
|
||||
typedef double (*Prototype_Double_Double)(double arg0);
|
||||
typedef double (*Prototype_Double_Int)(int64_t arg0);
|
||||
typedef double (*Prototype_Double_DoubleInt)(double arg0, int64_t arg1);
|
||||
typedef double (*Prototype_Double_IntDouble)(int64_t arg0, double arg1);
|
||||
typedef double (*Prototype_Double_DoubleDouble)(double arg0, double arg1);
|
||||
typedef double (*Prototype_Double_DoubleDoubleDouble)(double arg0, double arg1,
|
||||
double arg2);
|
||||
typedef double (*Prototype_Double_DoubleDoubleDoubleDouble)(double arg0,
|
||||
double arg1,
|
||||
double arg2,
|
||||
double arg3);
|
||||
|
||||
typedef int32_t (*Prototype_Int32_General)(int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32)(int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32)(int64_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32)(int64_t, int32_t,
|
||||
int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32Int32)(int64_t, int32_t,
|
||||
int32_t, int32_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32Int32Int32)(
|
||||
int64_t, int32_t, int32_t, int32_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32Int32General)(
|
||||
int64_t, int32_t, int32_t, int32_t, int32_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int32General)(
|
||||
int64_t, int32_t, int32_t, int32_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32General)(int64_t, int32_t,
|
||||
int32_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int32Int64Int32)(int64_t, int32_t,
|
||||
int32_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int64Int64)(int64_t, int32_t,
|
||||
int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32GeneralInt32)(int64_t, int32_t,
|
||||
int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32GeneralInt32Int32)(
|
||||
int64_t, int32_t, int64_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt32Int64Int64Int32)(int64_t, int32_t,
|
||||
int64_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneral)(int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralGeneral)(int64_t, int64_t,
|
||||
int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32Int32)(int64_t, int64_t,
|
||||
int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int32)(int64_t, int64_t,
|
||||
int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int32Int32Int32)(
|
||||
int64_t, int64_t, int32_t, int32_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int64Int32)(int64_t, int64_t,
|
||||
int32_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int32Int64General)(
|
||||
int64_t, int64_t, int32_t, int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64)(int64_t, int64_t,
|
||||
int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64Int32)(int64_t, int64_t,
|
||||
int64_t, int64_t,
|
||||
int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64General)(int64_t, int64_t,
|
||||
int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64General)(
|
||||
int64_t, int64_t, int64_t, int64_t, int64_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralInt64Int64Int64Int32Int32)(
|
||||
int64_t, int64_t, int64_t, int64_t, int32_t, int32_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32)(int64_t, int32_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32Int32)(int64_t, int32_t,
|
||||
int32_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32General)(int64_t, int32_t,
|
||||
int64_t);
|
||||
typedef int64_t (*Prototype_General_GeneralInt32Int32GeneralInt32)(
|
||||
int64_t, int32_t, int32_t, int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32Int32Int32GeneralInt32)(
|
||||
int64_t, int64_t, int32_t, int32_t, int32_t, int64_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32GeneralInt32Int32Int32)(
|
||||
int64_t, int64_t, int32_t, int64_t, int32_t, int32_t, int32_t);
|
||||
typedef int32_t (*Prototype_Int32_GeneralGeneralInt32General)(int64_t, int64_t,
|
||||
int32_t, int64_t);
|
||||
typedef int64_t (*Prototype_Int64_General)(int64_t);
|
||||
typedef int64_t (*Prototype_Int64_GeneralInt32)(int64_t, int32_t);
|
||||
typedef int64_t (*Prototype_Int64_GeneralInt64)(int64_t, int64_t);
|
||||
typedef int64_t (*Prototype_Int64_GeneralInt64Int32)(int64_t, int64_t, int32_t);
|
||||
ABI_FUNCTION_TYPE_SIM_PROTOTYPES
|
||||
|
||||
// Software interrupt instructions are used by the simulator to call into C++.
|
||||
void Simulator::softwareInterrupt(SimInstruction* instr) {
|
||||
|
@ -2043,20 +1924,34 @@ void Simulator::softwareInterrupt(SimInstruction* instr) {
|
|||
uintptr_t nativeFn =
|
||||
reinterpret_cast<uintptr_t>(redirection->nativeFunction());
|
||||
|
||||
int64_t arg0 = getRegister(a0);
|
||||
int64_t arg1 = getRegister(a1);
|
||||
int64_t arg2 = getRegister(a2);
|
||||
int64_t arg3 = getRegister(a3);
|
||||
int64_t arg4 = getRegister(a4);
|
||||
int64_t arg5 = getRegister(a5);
|
||||
// Get the SP for reading stack arguments
|
||||
int64_t* sp_ = reinterpret_cast<int64_t*>(getRegister(sp));
|
||||
|
||||
// Store argument register values in local variables for ease of use below.
|
||||
int64_t a0_ = getRegister(a0);
|
||||
int64_t a1_ = getRegister(a1);
|
||||
int64_t a2_ = getRegister(a2);
|
||||
int64_t a3_ = getRegister(a3);
|
||||
int64_t a4_ = getRegister(a4);
|
||||
int64_t a5_ = getRegister(a5);
|
||||
int64_t a6_ = getRegister(a6);
|
||||
int64_t a7_ = getRegister(a7);
|
||||
float f12_s = getFpuRegisterFloat(f12);
|
||||
float f13_s = getFpuRegisterFloat(f13);
|
||||
float f14_s = getFpuRegisterFloat(f14);
|
||||
float f15_s = getFpuRegisterFloat(f15);
|
||||
float f16_s = getFpuRegisterFloat(f16);
|
||||
float f17_s = getFpuRegisterFloat(f17);
|
||||
float f18_s = getFpuRegisterFloat(f18);
|
||||
double f12_d = getFpuRegisterDouble(f12);
|
||||
double f13_d = getFpuRegisterDouble(f13);
|
||||
double f14_d = getFpuRegisterDouble(f14);
|
||||
double f15_d = getFpuRegisterDouble(f15);
|
||||
|
||||
// This is dodgy but it works because the C entry stubs are never moved.
|
||||
// See comment in codegen-arm.cc and bug 1242173.
|
||||
int64_t saved_ra = getRegister(ra);
|
||||
|
||||
intptr_t external =
|
||||
reinterpret_cast<intptr_t>(redirection->nativeFunction());
|
||||
|
||||
bool stack_aligned = (getRegister(sp) & (ABIStackAlignment - 1)) == 0;
|
||||
if (!stack_aligned) {
|
||||
fprintf(stderr, "Runtime call with unaligned stack!\n");
|
||||
|
@ -2068,477 +1963,8 @@ void Simulator::softwareInterrupt(SimInstruction* instr) {
|
|||
}
|
||||
|
||||
switch (redirection->type()) {
|
||||
case Args_General0: {
|
||||
Prototype_General0 target =
|
||||
reinterpret_cast<Prototype_General0>(external);
|
||||
int64_t result = target();
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General1: {
|
||||
Prototype_General1 target =
|
||||
reinterpret_cast<Prototype_General1>(external);
|
||||
int64_t result = target(arg0);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General2: {
|
||||
Prototype_General2 target =
|
||||
reinterpret_cast<Prototype_General2>(external);
|
||||
int64_t result = target(arg0, arg1);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General3: {
|
||||
Prototype_General3 target =
|
||||
reinterpret_cast<Prototype_General3>(external);
|
||||
int64_t result = target(arg0, arg1, arg2);
|
||||
if (external == intptr_t(&js::wasm::Instance::wake_m32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General4: {
|
||||
Prototype_General4 target =
|
||||
reinterpret_cast<Prototype_General4>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General5: {
|
||||
Prototype_General5 target =
|
||||
reinterpret_cast<Prototype_General5>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General6: {
|
||||
Prototype_General6 target =
|
||||
reinterpret_cast<Prototype_General6>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4, arg5);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General7: {
|
||||
Prototype_General7 target =
|
||||
reinterpret_cast<Prototype_General7>(external);
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4, arg5, arg6);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_General8: {
|
||||
Prototype_General8 target =
|
||||
reinterpret_cast<Prototype_General8>(external);
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int64_t arg7 = getRegister(a7);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7);
|
||||
setCallResult(result);
|
||||
break;
|
||||
}
|
||||
case Args_Double_None: {
|
||||
Prototype_Double_None target =
|
||||
reinterpret_cast<Prototype_Double_None>(external);
|
||||
double dresult = target();
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int_Double: {
|
||||
double dval0 = getFpuRegisterDouble(12);
|
||||
Prototype_Int_Double target =
|
||||
reinterpret_cast<Prototype_Int_Double>(external);
|
||||
int64_t result = target(dval0);
|
||||
if (external == intptr_t((int32_t(*)(double))JS::ToInt32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_GeneralGeneralGeneralInt64: {
|
||||
Prototype_GeneralGeneralGeneralInt64 target =
|
||||
reinterpret_cast<Prototype_GeneralGeneralGeneralInt64>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3);
|
||||
if (external == intptr_t(&js::wasm::Instance::wait_i32_m32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_GeneralGeneralInt64Int64: {
|
||||
Prototype_GeneralGeneralInt64Int64 target =
|
||||
reinterpret_cast<Prototype_GeneralGeneralInt64Int64>(external);
|
||||
int64_t result = target(arg0, arg1, arg2, arg3);
|
||||
if (external == intptr_t(&js::wasm::Instance::wait_i64_m32)) {
|
||||
result = int32_t(result);
|
||||
}
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_DoubleInt: {
|
||||
double dval = getFpuRegisterDouble(12);
|
||||
Prototype_Int_DoubleInt target =
|
||||
reinterpret_cast<Prototype_Int_DoubleInt>(external);
|
||||
int64_t result = target(dval, arg1);
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_DoubleIntInt: {
|
||||
double dval = getFpuRegisterDouble(12);
|
||||
Prototype_Int_DoubleIntInt target =
|
||||
reinterpret_cast<Prototype_Int_DoubleIntInt>(external);
|
||||
int64_t result = target(dval, arg1, arg2);
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Int_IntDoubleIntInt: {
|
||||
double dval = getFpuRegisterDouble(13);
|
||||
Prototype_Int_IntDoubleIntInt target =
|
||||
reinterpret_cast<Prototype_Int_IntDoubleIntInt>(external);
|
||||
int64_t result = target(arg0, dval, arg2, arg3);
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Double_Double: {
|
||||
double dval0 = getFpuRegisterDouble(12);
|
||||
Prototype_Double_Double target =
|
||||
reinterpret_cast<Prototype_Double_Double>(external);
|
||||
double dresult = target(dval0);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Float32_Float32: {
|
||||
float fval0;
|
||||
fval0 = getFpuRegisterFloat(12);
|
||||
Prototype_Float32_Float32 target =
|
||||
reinterpret_cast<Prototype_Float32_Float32>(external);
|
||||
float fresult = target(fval0);
|
||||
setCallResultFloat(fresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int_Float32: {
|
||||
float fval0;
|
||||
fval0 = getFpuRegisterFloat(12);
|
||||
Prototype_Int_Float32 target =
|
||||
reinterpret_cast<Prototype_Int_Float32>(external);
|
||||
int64_t result = target(fval0);
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Float32_Float32Float32: {
|
||||
float fval0;
|
||||
float fval1;
|
||||
fval0 = getFpuRegisterFloat(12);
|
||||
fval1 = getFpuRegisterFloat(13);
|
||||
Prototype_Float32_Float32Float32 target =
|
||||
reinterpret_cast<Prototype_Float32_Float32Float32>(external);
|
||||
float fresult = target(fval0, fval1);
|
||||
setCallResultFloat(fresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_Int: {
|
||||
Prototype_Double_Int target =
|
||||
reinterpret_cast<Prototype_Double_Int>(external);
|
||||
double dresult = target(arg0);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleInt: {
|
||||
double dval0 = getFpuRegisterDouble(12);
|
||||
Prototype_Double_DoubleInt target =
|
||||
reinterpret_cast<Prototype_Double_DoubleInt>(external);
|
||||
double dresult = target(dval0, arg1);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleDouble: {
|
||||
double dval0 = getFpuRegisterDouble(12);
|
||||
double dval1 = getFpuRegisterDouble(13);
|
||||
Prototype_Double_DoubleDouble target =
|
||||
reinterpret_cast<Prototype_Double_DoubleDouble>(external);
|
||||
double dresult = target(dval0, dval1);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_IntDouble: {
|
||||
double dval1 = getFpuRegisterDouble(13);
|
||||
Prototype_Double_IntDouble target =
|
||||
reinterpret_cast<Prototype_Double_IntDouble>(external);
|
||||
double dresult = target(arg0, dval1);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int_IntDouble: {
|
||||
double dval1 = getFpuRegisterDouble(13);
|
||||
Prototype_Int_IntDouble target =
|
||||
reinterpret_cast<Prototype_Int_IntDouble>(external);
|
||||
int64_t result = target(arg0, dval1);
|
||||
setRegister(v0, result);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleDoubleDouble: {
|
||||
double dval0 = getFpuRegisterDouble(12);
|
||||
double dval1 = getFpuRegisterDouble(13);
|
||||
double dval2 = getFpuRegisterDouble(14);
|
||||
Prototype_Double_DoubleDoubleDouble target =
|
||||
reinterpret_cast<Prototype_Double_DoubleDoubleDouble>(external);
|
||||
double dresult = target(dval0, dval1, dval2);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Double_DoubleDoubleDoubleDouble: {
|
||||
double dval0 = getFpuRegisterDouble(12);
|
||||
double dval1 = getFpuRegisterDouble(13);
|
||||
double dval2 = getFpuRegisterDouble(14);
|
||||
double dval3 = getFpuRegisterDouble(15);
|
||||
Prototype_Double_DoubleDoubleDoubleDouble target =
|
||||
reinterpret_cast<Prototype_Double_DoubleDoubleDoubleDouble>(
|
||||
external);
|
||||
double dresult = target(dval0, dval1, dval2, dval3);
|
||||
setCallResultDouble(dresult);
|
||||
break;
|
||||
}
|
||||
case Args_Int32_General: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_General>(nativeFn)(arg0);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt32>(nativeFn)(
|
||||
arg0, I32(arg1));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3), I32(arg4));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32Int32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3), I32(arg4),
|
||||
I32(arg5));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32Int32General: {
|
||||
int32_t ret = reinterpret_cast<
|
||||
Prototype_Int32_GeneralInt32Int32Int32Int32General>(nativeFn)(
|
||||
arg0, I32(arg1), I32(arg2), I32(arg3), I32(arg4), arg5);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int32General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int32General>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), I32(arg3), arg4);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32General>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), arg3);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int32Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int32Int64Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), arg3, I32(arg4));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32GeneralInt32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32GeneralInt32>(
|
||||
nativeFn)(arg0, I32(arg1), arg2, I32(arg3));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32GeneralInt32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32GeneralInt32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), arg2, I32(arg3), I32(arg4));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralInt32Int64Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt32Int64Int64Int32>(
|
||||
nativeFn)(arg0, I32(arg1), arg2, arg3, I32(arg4));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralGeneral: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralGeneral>(
|
||||
nativeFn)(arg0, arg1);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralGeneralGeneral: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralGeneralGeneral>(
|
||||
nativeFn)(arg0, arg1, arg2);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_Int32_GeneralGeneralInt32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralGeneralInt32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int32: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int32Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int32Int32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3), I32(arg4),
|
||||
I32(arg5));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int64Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3, I32(arg4));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int32Int64General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int32Int64General>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3, arg4);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64: {
|
||||
int32_t ret = reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64Int32>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3, I32(arg4));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64General>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64General>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3, arg4);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralInt64Int64Int64Int32Int32: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralInt64Int64Int64Int32Int32>(
|
||||
nativeFn)(arg0, arg1, arg2, arg3, I32(arg4), I32(arg5));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case Args_General_GeneralInt32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_General_GeneralInt32>(
|
||||
nativeFn)(arg0, I32(arg1));
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case Args_General_GeneralInt32Int32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_General_GeneralInt32Int32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2));
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case Args_General_GeneralInt32General: {
|
||||
int64_t ret = reinterpret_cast<Prototype_General_GeneralInt32General>(
|
||||
nativeFn)(arg0, I32(arg1), arg2);
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_General_GeneralInt32Int32GeneralInt32: {
|
||||
int64_t ret =
|
||||
reinterpret_cast<Prototype_General_GeneralInt32Int32GeneralInt32>(
|
||||
nativeFn)(arg0, I32(arg1), I32(arg2), arg3, I32(arg4));
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralGeneralInt32GeneralInt32Int32Int32: {
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int32_t ret = reinterpret_cast<
|
||||
Prototype_Int32_GeneralGeneralInt32GeneralInt32Int32Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3, I32(arg4), I32(arg5),
|
||||
I32(arg6));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralGeneralInt32Int32Int32GeneralInt32: {
|
||||
int64_t arg6 = getRegister(a6);
|
||||
int32_t ret = reinterpret_cast<
|
||||
Prototype_Int32_GeneralGeneralInt32Int32Int32GeneralInt32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), I32(arg3), I32(arg4), arg5,
|
||||
I32(arg6));
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int32_GeneralGeneralInt32General: {
|
||||
int32_t ret =
|
||||
reinterpret_cast<Prototype_Int32_GeneralGeneralInt32General>(
|
||||
nativeFn)(arg0, arg1, I32(arg2), arg3);
|
||||
setRegister(v0, I64(ret));
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_General: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_General>(nativeFn)(arg0);
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_GeneralInt32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_GeneralInt32>(nativeFn)(
|
||||
arg0, I32(arg1));
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_GeneralInt64: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_GeneralInt64>(nativeFn)(
|
||||
arg0, arg1);
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
case js::jit::Args_Int64_GeneralInt64Int32: {
|
||||
int64_t ret = reinterpret_cast<Prototype_Int64_GeneralInt64Int32>(
|
||||
nativeFn)(arg0, arg1, I32(arg2));
|
||||
setRegister(v0, ret);
|
||||
break;
|
||||
}
|
||||
ABI_FUNCTION_TYPE_MIPS64_SIM_DISPATCH
|
||||
|
||||
default:
|
||||
MOZ_CRASH("Unknown function type.");
|
||||
}
|
||||
|
|
|
@ -6,17 +6,21 @@
|
|||
|
||||
# Some huge-mapping optimization instead of bounds checks on supported
|
||||
# platforms.
|
||||
if CONFIG['JS_CODEGEN_X64'] or CONFIG['JS_CODEGEN_ARM64'] or CONFIG['JS_CODEGEN_RISCV64']:
|
||||
DEFINES['WASM_SUPPORTS_HUGE_MEMORY'] = True
|
||||
if (
|
||||
CONFIG["JS_CODEGEN_X64"]
|
||||
or CONFIG["JS_CODEGEN_ARM64"]
|
||||
or CONFIG["JS_CODEGEN_RISCV64"]
|
||||
):
|
||||
DEFINES["WASM_SUPPORTS_HUGE_MEMORY"] = True
|
||||
|
||||
# Enables CACHEIR_LOGS to diagnose IC coverage, and
|
||||
# Structured spewer for diagnostics
|
||||
if CONFIG['MOZ_DEBUG'] or CONFIG['NIGHTLY_BUILD']:
|
||||
DEFINES['JS_CACHEIR_SPEW'] = True
|
||||
DEFINES['JS_STRUCTURED_SPEW'] = True
|
||||
if CONFIG["MOZ_DEBUG"] or CONFIG["NIGHTLY_BUILD"]:
|
||||
DEFINES["JS_CACHEIR_SPEW"] = True
|
||||
DEFINES["JS_STRUCTURED_SPEW"] = True
|
||||
|
||||
# CTypes
|
||||
if CONFIG['JS_HAS_CTYPES']:
|
||||
DEFINES['JS_HAS_CTYPES'] = True
|
||||
if not CONFIG['MOZ_SYSTEM_FFI']:
|
||||
DEFINES['FFI_BUILDING'] = True
|
||||
if CONFIG["JS_HAS_CTYPES"]:
|
||||
DEFINES["JS_HAS_CTYPES"] = True
|
||||
if not CONFIG["MOZ_SYSTEM_FFI"]:
|
||||
DEFINES["FFI_BUILDING"] = True
|
||||
|
|
|
@ -5,14 +5,14 @@
|
|||
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
|
||||
# ICU pkg-config flags
|
||||
CXXFLAGS += CONFIG['MOZ_ICU_CFLAGS']
|
||||
CXXFLAGS += CONFIG["MOZ_ICU_CFLAGS"]
|
||||
|
||||
if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
|
||||
if CONFIG["CC_TYPE"] in ("clang", "gcc"):
|
||||
# Error on bad printf-like format strings
|
||||
CXXFLAGS += ['-Werror=format']
|
||||
CXXFLAGS += ["-Werror=format"]
|
||||
|
||||
# gcc is buggy and warns on our attempts to JS_PUBLIC_API our
|
||||
# forward-declarations or explicit template instantiations. See
|
||||
# https://gcc.gnu.org/bugzilla/show_bug.cgi?id=50044
|
||||
if CONFIG['CC_TYPE'] == 'gcc':
|
||||
CXXFLAGS += ['-Wno-attributes']
|
||||
if CONFIG["CC_TYPE"] == "gcc":
|
||||
CXXFLAGS += ["-Wno-attributes"]
|
||||
|
|
|
@ -8,8 +8,8 @@
|
|||
# Gecko build performs equivalents elsewhere in its configuration.
|
||||
|
||||
USE_LIBS += [
|
||||
'jsrust',
|
||||
'zlib',
|
||||
"jsrust",
|
||||
"zlib",
|
||||
]
|
||||
|
||||
if CONFIG["OS_ARCH"] == "WINNT":
|
||||
|
|
|
@ -8,44 +8,67 @@
|
|||
static const char16_t arr[] = u"hi, don't delete me";
|
||||
static const size_t arrlen = js_strlen(arr);
|
||||
|
||||
static const char arr2[] = "hi, don't delete me";
|
||||
static const size_t arrlen2 = js_strlen(arr2);
|
||||
|
||||
static int finalized1 = 0;
|
||||
static int finalized2 = 0;
|
||||
static int finalized3 = 0;
|
||||
static int finalized4 = 0;
|
||||
|
||||
struct ExternalStringCallbacks : public JSExternalStringCallbacks {
|
||||
int* finalizedCount = nullptr;
|
||||
bool isTwoBytes = false;
|
||||
|
||||
explicit ExternalStringCallbacks(int* finalizedCount)
|
||||
: finalizedCount(finalizedCount) {}
|
||||
explicit ExternalStringCallbacks(int* finalizedCount, bool isTwoBytes)
|
||||
: finalizedCount(finalizedCount), isTwoBytes(isTwoBytes) {}
|
||||
|
||||
void finalize(JS::Latin1Char* chars) const override {
|
||||
MOZ_ASSERT(!isTwoBytes);
|
||||
MOZ_ASSERT(chars == (JS::Latin1Char*)arr2);
|
||||
(*finalizedCount)++;
|
||||
}
|
||||
|
||||
void finalize(char16_t* chars) const override {
|
||||
MOZ_ASSERT(isTwoBytes);
|
||||
MOZ_ASSERT(chars == arr);
|
||||
(*finalizedCount)++;
|
||||
}
|
||||
|
||||
size_t sizeOfBuffer(const JS::Latin1Char* chars,
|
||||
mozilla::MallocSizeOf mallocSizeOf) const override {
|
||||
MOZ_CRASH("Unexpected call");
|
||||
}
|
||||
|
||||
size_t sizeOfBuffer(const char16_t* chars,
|
||||
mozilla::MallocSizeOf mallocSizeOf) const override {
|
||||
MOZ_CRASH("Unexpected call");
|
||||
}
|
||||
};
|
||||
|
||||
static const ExternalStringCallbacks callbacks1(&finalized1);
|
||||
static const ExternalStringCallbacks callbacks2(&finalized2);
|
||||
static const ExternalStringCallbacks callbacks1(&finalized1, true);
|
||||
static const ExternalStringCallbacks callbacks2(&finalized2, true);
|
||||
static const ExternalStringCallbacks callbacks3(&finalized3, false);
|
||||
static const ExternalStringCallbacks callbacks4(&finalized4, false);
|
||||
|
||||
BEGIN_TEST(testExternalStrings) {
|
||||
const unsigned N = 1000;
|
||||
|
||||
for (unsigned i = 0; i < N; ++i) {
|
||||
CHECK(JS_NewExternalString(cx, arr, arrlen, &callbacks1));
|
||||
CHECK(JS_NewExternalString(cx, arr, arrlen, &callbacks2));
|
||||
CHECK(JS_NewExternalUCString(cx, arr, arrlen, &callbacks1));
|
||||
CHECK(JS_NewExternalUCString(cx, arr, arrlen, &callbacks2));
|
||||
CHECK(JS_NewExternalStringLatin1(cx, (JS::Latin1Char*)arr2, arrlen2,
|
||||
&callbacks3));
|
||||
CHECK(JS_NewExternalStringLatin1(cx, (JS::Latin1Char*)arr2, arrlen2,
|
||||
&callbacks4));
|
||||
}
|
||||
|
||||
JS_GC(cx);
|
||||
|
||||
// a generous fudge factor to account for strings rooted by conservative gc
|
||||
const unsigned epsilon = 10;
|
||||
|
||||
CHECK((N - finalized1) < epsilon);
|
||||
CHECK((N - finalized2) < epsilon);
|
||||
CHECK((N - finalized1) == 0);
|
||||
CHECK((N - finalized2) == 0);
|
||||
CHECK((N - finalized3) == 0);
|
||||
CHECK((N - finalized4) == 0);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -1463,7 +1463,15 @@ JS_PUBLIC_API void JS_SetGCParametersBasedOnAvailableMemory(
|
|||
}
|
||||
}
|
||||
|
||||
JS_PUBLIC_API JSString* JS_NewExternalString(
|
||||
JS_PUBLIC_API JSString* JS_NewExternalStringLatin1(
|
||||
JSContext* cx, const Latin1Char* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks) {
|
||||
AssertHeapIsIdle();
|
||||
CHECK_THREAD(cx);
|
||||
return JSExternalString::new_(cx, chars, length, callbacks);
|
||||
}
|
||||
|
||||
JS_PUBLIC_API JSString* JS_NewExternalUCString(
|
||||
JSContext* cx, const char16_t* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks) {
|
||||
AssertHeapIsIdle();
|
||||
|
@ -1471,7 +1479,16 @@ JS_PUBLIC_API JSString* JS_NewExternalString(
|
|||
return JSExternalString::new_(cx, chars, length, callbacks);
|
||||
}
|
||||
|
||||
JS_PUBLIC_API JSString* JS_NewMaybeExternalString(
|
||||
JS_PUBLIC_API JSString* JS_NewMaybeExternalStringLatin1(
|
||||
JSContext* cx, const JS::Latin1Char* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks, bool* allocatedExternal) {
|
||||
AssertHeapIsIdle();
|
||||
CHECK_THREAD(cx);
|
||||
return NewMaybeExternalString(cx, chars, length, callbacks,
|
||||
allocatedExternal);
|
||||
}
|
||||
|
||||
JS_PUBLIC_API JSString* JS_NewMaybeExternalUCString(
|
||||
JSContext* cx, const char16_t* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks, bool* allocatedExternal) {
|
||||
AssertHeapIsIdle();
|
||||
|
|
|
@ -386,12 +386,18 @@ static bool NukedAllRealms(JS::Compartment* comp) {
|
|||
}
|
||||
|
||||
/*
|
||||
* NukeChromeCrossCompartmentWrappersForGlobal reaches into chrome and cuts
|
||||
* all of the cross-compartment wrappers that point to an object in the |target|
|
||||
* realm. The snag here is that we need to avoid cutting wrappers that point to
|
||||
* the window object on page navigation (inner window destruction) and only do
|
||||
* that on tab close (outer window destruction). Thus the option of how to
|
||||
* handle the global object.
|
||||
* NukeCrossCompartmentWrappers invalidates all cross-compartment wrappers
|
||||
* that point to objects in the |target| realm.
|
||||
*
|
||||
* There is some complexity in targeting to preserve semantics which requires
|
||||
* the filtering and behavioural options:
|
||||
*
|
||||
* - |sourceFilter| limits the compartments searched for source pointers
|
||||
* - |nukeReferencesToWindow| will, if set to DontNukeWindowReferences skip
|
||||
* wrappers whose target is the window proxy of the target realm.
|
||||
* - |nukeReferencesFromTarget| will, when set to NukeAllReferences, disallow
|
||||
* the creation of new wrappers to the target realm. This option can also
|
||||
* allow more wrappers to be cleaned up transitively.
|
||||
*/
|
||||
JS_PUBLIC_API bool js::NukeCrossCompartmentWrappers(
|
||||
JSContext* cx, const CompartmentFilter& sourceFilter, JS::Realm* target,
|
||||
|
|
|
@ -589,17 +589,29 @@ inline JSExternalString::JSExternalString(
|
|||
d.s.u3.externalCallbacks = callbacks;
|
||||
}
|
||||
|
||||
MOZ_ALWAYS_INLINE JSExternalString* JSExternalString::new_(
|
||||
JSContext* cx, const char16_t* chars, size_t length,
|
||||
inline JSExternalString::JSExternalString(
|
||||
const JS::Latin1Char* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks) {
|
||||
MOZ_ASSERT(callbacks);
|
||||
setLengthAndFlags(length, EXTERNAL_FLAGS | LATIN1_CHARS_BIT);
|
||||
d.s.u2.nonInlineCharsLatin1 = chars;
|
||||
d.s.u3.externalCallbacks = callbacks;
|
||||
}
|
||||
|
||||
template <typename CharT>
|
||||
/* static */
|
||||
MOZ_ALWAYS_INLINE JSExternalString* JSExternalString::newImpl(
|
||||
JSContext* cx, const CharT* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks) {
|
||||
if (MOZ_UNLIKELY(!validateLength(cx, length))) {
|
||||
return nullptr;
|
||||
}
|
||||
auto* str = cx->newCell<JSExternalString>(chars, length, callbacks);
|
||||
|
||||
if (!str) {
|
||||
return nullptr;
|
||||
}
|
||||
size_t nbytes = length * sizeof(char16_t);
|
||||
size_t nbytes = length * sizeof(CharT);
|
||||
|
||||
MOZ_ASSERT(str->isTenured());
|
||||
js::AddCellMemory(str, nbytes, js::MemoryUse::StringContents);
|
||||
|
@ -607,6 +619,20 @@ MOZ_ALWAYS_INLINE JSExternalString* JSExternalString::new_(
|
|||
return str;
|
||||
}
|
||||
|
||||
/* static */
|
||||
MOZ_ALWAYS_INLINE JSExternalString* JSExternalString::new_(
|
||||
JSContext* cx, const JS::Latin1Char* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks) {
|
||||
return newImpl(cx, chars, length, callbacks);
|
||||
}
|
||||
|
||||
/* static */
|
||||
MOZ_ALWAYS_INLINE JSExternalString* JSExternalString::new_(
|
||||
JSContext* cx, const char16_t* chars, size_t length,
|
||||
const JSExternalStringCallbacks* callbacks) {
|
||||
return newImpl(cx, chars, length, callbacks);
|
||||
}
|
||||
|
||||
inline js::NormalAtom::NormalAtom(size_t length, JS::Latin1Char** chars,
|
||||
js::HashNumber hash)
|
||||
: hash_(hash) {
|
||||
|
@ -725,10 +751,17 @@ inline void js::FatInlineAtom::finalize(JS::GCContext* gcx) {
|
|||
inline void JSExternalString::finalize(JS::GCContext* gcx) {
|
||||
MOZ_ASSERT(JSString::isExternal());
|
||||
|
||||
size_t nbytes = length() * sizeof(char16_t);
|
||||
gcx->removeCellMemory(this, nbytes, js::MemoryUse::StringContents);
|
||||
if (hasLatin1Chars()) {
|
||||
size_t nbytes = length() * sizeof(JS::Latin1Char);
|
||||
gcx->removeCellMemory(this, nbytes, js::MemoryUse::StringContents);
|
||||
|
||||
callbacks()->finalize(const_cast<char16_t*>(rawTwoByteChars()));
|
||||
callbacks()->finalize(const_cast<JS::Latin1Char*>(rawLatin1Chars()));
|
||||
} else {
|
||||
size_t nbytes = length() * sizeof(char16_t);
|
||||
gcx->removeCellMemory(this, nbytes, js::MemoryUse::StringContents);
|
||||
|
||||
callbacks()->finalize(const_cast<char16_t*>(rawTwoByteChars()));
|
||||
}
|
||||
}
|
||||
|
||||
#endif /* vm_StringType_inl_h */
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue