[PATCH] Add readability-redundant-void-arg check to clang-tidy

Gábor Horváth xazax.hun at gmail.com
Sun Mar 8 00:43:46 PST 2015


In http://reviews.llvm.org/D7639#136129, @LegalizeAdulthood wrote:

> If you can show me how to lex a SourceRange without getting that error, I'm happy to change it. I tried the method shown in the linked diff and I get the same error.


As far as I know, the point is that you can not do that without creating a null terminated string, however you do not need to do that. What you can do insead: you can lex the whole file buffer starting from the beginning of a declaration and you can make sure that you finish lexing on the end of the declaration (e.g.: end lexing when you match the closing paren of the declaration). This way you might have a bit more complicated lexing logic but you avoid heap allocation.


http://reviews.llvm.org/D7639

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the cfe-commits mailing list