Skip to content

Commit 9902f10

Browse files
author
Mandeep Singh Grang
committed
Set the correct offset for ASTStmtReader::NumExprFields
For creating an empty DeclRefExpr, we need to pass NumTemplateArgs. This depends on the NumExprFields. In Checked C, we changed the NumExprFields from 5 to 7. But upstream has this field as 6. So we adjust this and change it to 8.
1 parent 70af78c commit 9902f10

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/lib/Serialization/ASTReaderStmt.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2691,7 +2691,7 @@ Stmt *ASTReader::ReadStmtFromStream(ModuleFile &F) {
26912691
/*HasFoundDecl=*/Record[ASTStmtReader::NumExprFields + 1],
26922692
/*HasTemplateKWAndArgsInfo=*/Record[ASTStmtReader::NumExprFields + 2],
26932693
/*NumTemplateArgs=*/Record[ASTStmtReader::NumExprFields + 2] ?
2694-
Record[ASTStmtReader::NumExprFields + 6] : 0);
2694+
Record[ASTStmtReader::NumExprFields + 8] : 0);
26952695
break;
26962696

26972697
case EXPR_INTEGER_LITERAL:

0 commit comments

Comments
 (0)