[llvm] [llvm-remarkutil] Auto-detect serializer format based on file extension (PR #160545)
Jon Roelofs via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 24 09:51:06 PDT 2025
================
@@ -46,12 +46,8 @@ static Error tryFilter() {
return MaybeParser.takeError();
auto &Parser = **MaybeParser;
- Format SerializerFormat = OutputFormat;
- if (SerializerFormat == Format::Auto) {
- SerializerFormat = Parser.ParserFormat;
- if (OutputFileName.empty() || OutputFileName == "-")
- SerializerFormat = Format::YAML;
- }
+ Format SerializerFormat =
+ getSerializerFormat(OutputFileName, OutputFormat, Parser.ParserFormat);
----------------
jroelofs wrote:
I like that!
https://github.com/llvm/llvm-project/pull/160545
More information about the llvm-commits
mailing list