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

Alexander Kornienko alexfh at google.com
Sun Sep 21 17:00:58 PDT 2014



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)
----------------
kimgr wrote:
> This doesn't work on Windows. The variable there is USERNAME; would it make sense to check both?
Thanks for noting. Some further work on this is happening in D5408, and I'll add USERNAME variable handling there.

http://reviews.llvm.org/D5393






More information about the cfe-commits mailing list