[PATCH] D41421: Eliminate a magic number. NFC.

Eli Friedman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 19 17:05:04 PST 2017

efriedma added a comment.

Please use llvm::array_lengthof to compute the length of an array.

Alternatively, there's an overload of PP.getSpelling which takes a SmallVector and returns a StringRef as a parameter; you could change this code to use it, which would remove the need for the check.


More information about the cfe-commits mailing list