aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/ExtractAPI/DeclarationFragments.cpp
diff options
context:
space:
mode:
authorYoungsuk Kim <youngsuk.kim@hpe.com>2024-09-19 13:36:53 -0500
committerYoungsuk Kim <youngsuk.kim@hpe.com>2024-09-19 14:56:45 -0500
commitac664697c54cf2ffa9ebef0215f734bcca3b718f (patch)
treee51c26852b32915c90c3f4ebf399827f8b45324d /clang/lib/ExtractAPI/DeclarationFragments.cpp
parent434c9c50f99b1ad4e551c64af93287869389b087 (diff)
downloadllvm-ac664697c54cf2ffa9ebef0215f734bcca3b718f.zip
llvm-ac664697c54cf2ffa9ebef0215f734bcca3b718f.tar.gz
llvm-ac664697c54cf2ffa9ebef0215f734bcca3b718f.tar.bz2
[clang] Tidy uses of raw_string_ostream (NFC)
As specified in the docs, 1) raw_string_ostream is always unbuffered and 2) the underlying buffer may be used directly ( 65b13610a5226b84889b923bae884ba395ad084d for further reference ) * Don't call raw_string_ostream::flush(), which is essentially a no-op. * Avoid unneeded calls to raw_string_ostream::str(), to avoid excess indirection.
Diffstat (limited to 'clang/lib/ExtractAPI/DeclarationFragments.cpp')
-rw-r--r--clang/lib/ExtractAPI/DeclarationFragments.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/clang/lib/ExtractAPI/DeclarationFragments.cpp b/clang/lib/ExtractAPI/DeclarationFragments.cpp
index 06ce5ed..9cb45c8 100644
--- a/clang/lib/ExtractAPI/DeclarationFragments.cpp
+++ b/clang/lib/ExtractAPI/DeclarationFragments.cpp
@@ -1110,7 +1110,6 @@ DeclarationFragmentsBuilder::getFragmentsForTemplateArguments(
Spelling.clear();
raw_string_ostream OutStream(Spelling);
CTA.print(Context.getPrintingPolicy(), OutStream, false);
- OutStream.flush();
}
}