Skip to content

Commit

Permalink
doc: Clarify C++ standards support
Browse files Browse the repository at this point in the history
We weren't explicit about what we mean by "C++ support" as it relates
to standards versions, and it's been causing some friction in the tree
vs. some of our cruftier toolchains.  Add a paragraph to clarify
things.

Fixes zephyrproject-rtos#55204

Signed-off-by: Andy Ross <andyross@google.com>
  • Loading branch information
andyross committed Mar 1, 2023
1 parent 7359b25 commit d1d85b3
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions doc/develop/languages/cpp/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ and the included compiler must be supported by the Zephyr build system. The
is supported by Zephyr, and the features and their availability documented
here assume the use of the Zephyr SDK.

The default C++ standard level (i.e. the language enforced by the
compiler flags passed) for Zephyr apps is C++11. Other standards are
available via kconfig choice, for example
:kconfig:option:`CONFIG_STD_CPP98`. The oldest standard supported and
tested in Zephyr is C++98.

When compiling a source file, the build system selects the C++ compiler based
on the suffix (extension) of the files. Files identified with either a **cpp**
or a **cxx** suffix are compiled using the C++ compiler. For example,
Expand Down

0 comments on commit d1d85b3

Please sign in to comment.