================ @@ -222,6 +222,8 @@ def note_constexpr_ltor_non_integral : Note< "is not allowed in a constant expression">; def note_constexpr_ltor_non_constexpr : Note< "read of non-constexpr variable %0 is not allowed in a constant expression">; +def note_constexpr_ltor_for_range_var : Note< + "'begin' variable of range-based 'for' loop is not a constant expression">; ---------------- akash-manna-sky wrote:
Reworded again based on Sirraide's suggestion, to keep the variable name but phrase it as a read: `read of implicit variable '__begin1' of range-based 'for' loop is not allowed in a constant expression`. Same shape as the neighbouring `read of … is not allowed notes`, and it still says which of `__begin/__end/__range` was read. https://github.com/llvm/llvm-project/pull/218145 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
