[cfe-dev] Check builtin function possible immediate argument

陳韋任 via cfe-dev cfe-dev at lists.llvm.org
Wed May 24 04:40:41 PDT 2017


Hi All,

  I have builtin functions whose argument could be variable or immediate
(constant), and I would like to
check the range of argument if it's
immediate. Sema::SemaBuiltinConstantArgRange [1] more or less
fits my need. But seems it requires the argument must be immediate, it will
throw "argument must be
constant" otherwise.

  I am wondering if there is other function achieve my goal, or my
understanding about SemaBuiltinConstantArgRange
is wrong. Thanks.

[1] https://clang.llvm.org/doxygen/SemaChecking_8cpp_source.html

Regards,
chenwj

-- 
Wei-Ren Chen (陳韋任)
Homepage: https://people.cs.nctu.edu.tw/~chenwj
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20170524/6c46c770/attachment.html>


More information about the cfe-dev mailing list