Skip to content

Commit 74a592a

Browse files
authored
Merge pull request #70470 from xedin/use-stringref-in-emit-with-blob
[SerializedDiagnosticConsumer] Pass StringRef instead of raw data for…
2 parents 2e85a4c + dbc25f7 commit 74a592a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/Frontend/SerializedDiagnosticConsumer.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ unsigned SerializedDiagnosticConsumer::getEmitCategory(StringRef Category) {
319319
Record.push_back(entry);
320320
Record.push_back(Category.size());
321321
State->Stream.EmitRecordWithBlob(State->Abbrevs.get(RECORD_CATEGORY), Record,
322-
Category.data());
322+
Category);
323323

324324
return entry;
325325
}
@@ -348,7 +348,7 @@ SerializedDiagnosticConsumer::emitEducationalNotes(const DiagnosticInfo &Info) {
348348
Record.push_back(recordID);
349349
Record.push_back(paths.size());
350350
State->Stream.EmitRecordWithBlob(State->Abbrevs.get(RECORD_DIAG_FLAG), Record,
351-
paths.data());
351+
paths);
352352
return recordID;
353353
}
354354

0 commit comments

Comments
 (0)