================
@@ -20257,7 +20257,11 @@ static void DoMarkVarDeclReferenced(
bool UsableInConstantExpr =
Var->mightBeUsableInConstantExpressions(SemaRef.Context);
- if (Var->isLocalVarDeclOrParm() && !Var->hasExternalStorage()) {
+ bool ShouldTrackForUnusedButSet = Var->isStaticFileVar() &&
+ !Var->isStaticDataMember() &&
+ !Var->getType()->isFunctionPointerType();
----------------
zwuis wrote:
Why variables with function pointer type and static data members are handled
specially? Are there any other bugs in our implementation?
https://github.com/llvm/llvm-project/pull/178342
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits