Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Rule 6.0.3 and extern "C"
#2
extern "C" only affects linkage, and MISRA C++:2023 rules do not place any limits on their contents.

The intention of 6.0.3 is to allows extern "C" to be used at global scope so that use can be made to declarations/definitions in headers from other  C-compatible languages. There is an expectation that they will not be used to add objects at global scope that would otherwise be disallowed by 6.0.3.
Posted by and on behalf of
the MISRA C++ Working Group
Reply


Messages In This Thread
Rule 6.0.3 and extern "C" - by kth - 04-05-2026, 03:12 PM
RE: Rule 6.0.3 and extern "C" - by misra cpp - 08-05-2026, 01:35 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)