Closed Bug 1611520 Opened 4 years ago Closed 4 years ago

FunctionTypeTraits.h: 'size_t' has not been declared

Categories

(Developer Infrastructure :: Source Code Analysis, defect)

defect
Not set
normal

Tracking

(firefox-esr68 fixed, firefox74 fixed)

RESOLVED FIXED
mozilla74
Tracking Status
firefox-esr68 --- fixed
firefox74 --- fixed

People

(Reporter: Sylvestre, Assigned: Sylvestre)

References

(Depends on 1 open bug)

Details

Attachments

(1 file)

Looks like some headers aren't included by default anymore

 0:01.38 In file included from /root/firefox-gcc-last/mfbt/tests/TestFunctionTypeTraits.cpp:7:
 0:01.38 /root/firefox-gcc-last/obj-x86_64-pc-linux-gnu/dist/include/mozilla/FunctionTypeTraits.h:59:22: error: 'size_t' has not been declared
 0:01.38    59 | template <bool safe, size_t N, typename... As>
 0:01.38       |                      ^~~~~~
Summary: FunctionTypeTraits.h: 'size_t' has not been declared " → FunctionTypeTraits.h: 'size_t' has not been declared

I guess it is Reduced header dependencies, leading to faster compilation for some code from the gcc 10 release notes:
https://gcc.gnu.org/gcc-10/changes.html

Pushed by sledru@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/8f7f2e18862c
gcc-10: Include <cstddef> in FunctionTypeTraits.h r=gerald
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla74

Comment on attachment 9122978 [details]
Bug 1611520 - gcc-10: Include <cstddef> in FunctionTypeTraits.h r?gerald

ESR Uplift Approval Request

  • If this is not a sec:{high,crit} bug, please state case for ESR consideration: This affects embedders building SpiderMonkey ESR68 with GCC 10 and apparently some version of Clang as well.
  • User impact if declined: Standalone SpiderMonkey won't be buildable with GCC 10.
  • Fix Landed on Version: 74
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Patch is trivial, and any regressions would be obvious at build time.
  • String or UUID changes made by this patch: None
Attachment #9122978 - Flags: approval-mozilla-esr68?

Comment on attachment 9122978 [details]
Bug 1611520 - gcc-10: Include <cstddef> in FunctionTypeTraits.h r?gerald

Simple fix needed for SM to compile with GCC10. Approved for 68.8esr.

Attachment #9122978 - Flags: approval-mozilla-esr68? → approval-mozilla-esr68+
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: