[PATCH] [clang-tidy] Add a checker that warns on TODO comments without username.

Kim Gräsman kim.grasman at gmail.com
Sun Sep 21 12:21:55 PDT 2014


See inline.

REPOSITORY
  rL LLVM

================
Comment at: clang-tools-extra/trunk/clang-tidy/google/TodoCommentCheck.cpp:42
@@ +41,3 @@
+    // FIXME: Can we get this from a more reliable source?
+    const char *User = std::getenv("USER");
+    if (!User)
----------------
This doesn't work on Windows. The variable there is USERNAME; would it make sense to check both?

http://reviews.llvm.org/D5393






More information about the cfe-commits mailing list