diff options
Diffstat (limited to 'lib/Serialization/ASTWriter.cpp')
-rw-r--r-- | lib/Serialization/ASTWriter.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/Serialization/ASTWriter.cpp b/lib/Serialization/ASTWriter.cpp index 3b6b218e74..f661b45df0 100644 --- a/lib/Serialization/ASTWriter.cpp +++ b/lib/Serialization/ASTWriter.cpp @@ -2690,10 +2690,8 @@ void ASTWriter::AddSourceRange(SourceRange Range, RecordData &Record) { void ASTWriter::AddAPInt(const llvm::APInt &Value, RecordData &Record) { Record.push_back(Value.getBitWidth()); - unsigned N = Value.getNumWords(); - const uint64_t* Words = Value.getRawData(); - for (unsigned I = 0; I != N; ++I) - Record.push_back(Words[I]); + const uint64_t *Words = Value.getRawData(); + Record.append(Words, Words + Value.getNumWords()); } void ASTWriter::AddAPSInt(const llvm::APSInt &Value, RecordData &Record) { |