[PATCH] D142606: Lazyly initialize uncommon toolchain detector

Fangrui Song via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Feb 5 17:48:18 PST 2023


MaskRay added a comment.

LGTM



================
Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:36
+    }
+    return &Detector.value();
+  }
----------------
tbaeder wrote:
> Is the `.value()` here permitted? AFAIK the convention is to always use `operator*`.
> 
> And I think @aaron.ballman would tell you to drop the `{}` around that single-statement `if` :)
llvm style prefers `const T` to `T const`


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D142606/new/

https://reviews.llvm.org/D142606



More information about the cfe-commits mailing list