================
@@ -1527,20 +1527,20 @@ struct DeclaratorChunk {
 
     /// Retrieve the location of the 'const' qualifier.
     SourceLocation getConstQualifierLoc() const {
-      assert(MethodQualifiers);
-      return MethodQualifiers->getConstSpecLoc();
+      return MethodQualifiers ? MethodQualifiers->getConstSpecLoc()
----------------
erichkeane wrote:

Hmm... these asserts make sense in just about every situation except for the 
'fixits'.  I wonder if there is instead value in capturing that we did it with 
a 'fixit' instead?  So the assert becomes `MethodQualifiers || 
WasFixConstFixit`.  

https://github.com/llvm/llvm-project/pull/92452
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to