[PATCH] D144157: Add 128-bit integer support to enum element

zhouyizhou via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Feb 22 14:43:20 PST 2023


zhouyizhou marked an inline comment as done.
zhouyizhou added a comment.

Thank you all for your guidance!

Now I am starting to learn C2X N2997, this is a fruitful process of learning for me ;-)

Cheers
Zhouyi



================
Comment at: clang/lib/Sema/SemaDecl.cpp:19571-19573
-  // TODO: If the result value doesn't fit in an int, it must be a long or long
-  // long value.  ISO C does not support this, but GCC does as an extension,
-  // emit a warning.
----------------
h-vetinari wrote:
> That comment is still relevant AFAICT, at least partially (the ISO C restrictions are still there, GCC still extends it)
> That comment is still relevant AFAICT, at least partially (the ISO C restrictions are still there, GCC still extends it)

Thank for reviewing the patch ;-)

I think clang (with -pedantic) has emit the warning in function Sema::CheckEnumConstant, which behave very similar to what GCC (with -pedantic) do.

Cheers
Zhouyi


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D144157/new/

https://reviews.llvm.org/D144157



More information about the cfe-commits mailing list