Check builtin function possible immediate argument

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.




Does Expr::isIntegerConstantExpr fit your need?