Closed Bug 1077887 Opened 6 years ago Closed 6 years ago

Work around GCC bug in static_cast<...>(enum-class-value)

Categories

(Core :: Security: PSM, defect)

x86
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla35

People

(Reporter: briansmith, Assigned: briansmith)

References

Details

Attachments

(1 file)

See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48106. Without this patch, older versions of GCC, in particular one of the versions of GCC used to compile B2G, will crash trying to compile the code for bug 1063281. This patch makes GCC use "enum" instead of "enum class" if we detect a GCC version where the bug wasn't fixed. We already do something similar for older versions of Visual Studio.
Attachment #8500084 - Flags: review?(mmc)
Comment on attachment 8500084 [details] [diff] [review]
gcc-enum-class.patch

Review of attachment 8500084 [details] [diff] [review]:
-----------------------------------------------------------------

LG pending green try on windows.
Attachment #8500084 - Flags: review?(mmc) → review+
This already passed try on all platforms before I asked for review.

https://hg.mozilla.org/integration/mozilla-inbound/rev/16fe1b9eb9e6
sorry had to back this out in https://treeherder.mozilla.org/ui/#/jobs?repo=mozilla-inbound&revision=8847ac2e2a53 since one of this 3 checkins made XPCshell tests more failing frequently like the issues in bug 964673 as example
Thanks for the backout. I relanded this since it wasn't causing the issue that caused the need for a backout: https://hg.mozilla.org/integration/mozilla-inbound/rev/cd32febb260a
https://hg.mozilla.org/mozilla-central/rev/cd32febb260a
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.