LGTM with some tiny tweaks, thanks!
BRANCH
add-optimization-remarks
================
Comment at: include/clang/Basic/Diagnostic.h:696
@@ +695,3 @@
+ /// \brief Set the value associated to this diagnostic flag.
+ void setFlagNameValue(StringRef V) { FlagNameValue = V.str(); }
+
----------------
The `.str()` should not be necessary here.
================
Comment at: include/clang/Basic/Diagnostic.h:1016
@@ +1015,3 @@
+struct AddFlagValue {
+ AddFlagValue(StringRef V) : Val(V) {}
+ StringRef Val;
----------------
Please make this constructor `explicit`.
================
Comment at: include/clang/Basic/Diagnostic.h:1123
@@ -1107,3 +1122,3 @@
CurDiagID = DiagID;
- FlagNameValue = Val.str();
+ FlagNameValue.erase();
return DiagnosticBuilder(this);
----------------
`clear` is a more common way of spelling this than `erase`.
http://reviews.llvm.org/D3453
REPLY HANDLER ACTIONS
Reply to comment, or !reject, !abandon, !reclaim, !resign, !rethink,
!unsubscribe.
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits