@@ -684,7 +684,7 @@ void LinkerDriver::linkerMain(ArrayRef<const char *> argsArr) {
684684 if (!ltoSampleProfile.empty ())
685685 readFile (ctx, ltoSampleProfile);
686686 } else {
687- ErrAlways (ctx) << " --reproduce: " << toString ( errOrWriter.takeError () );
687+ ErrAlways (ctx) << " --reproduce: " << errOrWriter.takeError ();
688688 }
689689 }
690690
@@ -1141,7 +1141,7 @@ static void ltoValidateAllVtablesHaveTypeInfos(Ctx &ctx,
11411141 Expected<GlobPattern> pat = GlobPattern::create (knownSafeName);
11421142 if (!pat)
11431143 ErrAlways (ctx) << " --lto-known-safe-vtables=: "
1144- << toString ( pat.takeError () );
1144+ << pat.takeError ();
11451145 vtableSymbolsWithNoRTTI.remove_if (
11461146 [&](StringRef s) { return pat->match (s); });
11471147 }
@@ -1271,7 +1271,7 @@ static bool remapInputs(Ctx &ctx, StringRef line, const Twine &location) {
12711271 else if (Expected<GlobPattern> pat = GlobPattern::create (fields[0 ]))
12721272 ctx.arg .remapInputsWildcards .emplace_back (std::move (*pat), fields[1 ]);
12731273 else {
1274- ErrAlways (ctx) << location << " : " << toString ( pat.takeError () ) << " : "
1274+ ErrAlways (ctx) << location << " : " << pat.takeError () << " : "
12751275 << fields[0 ];
12761276 return true ;
12771277 }
@@ -1600,7 +1600,7 @@ static void readConfigs(Ctx &ctx, opt::InputArgList &args) {
16001600 else if (Expected<GlobPattern> pat = GlobPattern::create (kv.first ))
16011601 ctx.arg .shuffleSections .emplace_back (std::move (*pat), uint32_t (v));
16021602 else
1603- ErrAlways (ctx) << errPrefix << toString ( pat.takeError () ) << " : "
1603+ ErrAlways (ctx) << errPrefix << pat.takeError () << " : "
16041604 << kv.first ;
16051605 }
16061606
@@ -1645,7 +1645,7 @@ static void readConfigs(Ctx &ctx, opt::InputArgList &args) {
16451645 if (Expected<GlobPattern> pat = GlobPattern::create (fields[0 ])) {
16461646 ctx.arg .compressSections .emplace_back (std::move (*pat), type, level);
16471647 } else {
1648- ErrAlways (ctx) << arg->getSpelling () << " : " << toString ( pat.takeError () );
1648+ ErrAlways (ctx) << arg->getSpelling () << " : " << pat.takeError ();
16491649 continue ;
16501650 }
16511651 }
0 commit comments