[PATCH] D124033: [NFC] Adding a note about the macro __FLT_EVAL_METHOD__

Zahira Ammarguellat via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Apr 19 12:09:35 PDT 2022


zahiraam created this revision.
zahiraam added a reviewer: aaron.ballman.
Herald added a project: All.
zahiraam requested review of this revision.
Herald added a project: clang.

This is to clarify  that the macro __FLT_EVAL_METHOD__   it is not pre-defined like other preprocessor macros. It will not appear when preprocessor macros are dumped.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D124033

Files:
  clang/docs/UsersManual.rst


Index: clang/docs/UsersManual.rst
===================================================================
--- clang/docs/UsersManual.rst
+++ clang/docs/UsersManual.rst
@@ -1609,10 +1609,13 @@
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 The macro ``__FLT_EVAL_METHOD__`` will expand to either the value set from the
 command line option ``ffp-eval-method`` or to the value from the target info
-setting. The ``__FLT_EVAL_METHOD__`` macro cannot expand to the correct
-evaluation method in the presence of a ``#pragma`` which alters the evaluation
-method. An error is issued if ``__FLT_EVAL_METHOD__`` is expanded inside a scope
-modified by ``#pragma clang fp eval_method``.
+setting. The ``__FLT_EVAL_METHOD__`` macro is resolved as a macro
+definition during expansion. When predefined preprocessor macros are dumped,
+``__FLT_EVAL_METHOD__`` will not be listed.
+The ``__FLT_EVAL_METHOD__`` macro cannot expand to the correct evaluation method
+in the presence of a ``#pragma`` which alters the evaluation method. An error is
+issued if ``__FLT_EVAL_METHOD__`` is expanded inside a scope modified by
+``#pragma clang fp eval_method``.
 
 .. _fp-constant-eval:
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D124033.423700.patch
Type: text/x-patch
Size: 1156 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220419/4ed162b8/attachment-0001.bin>


More information about the cfe-commits mailing list