Skip to content

Commit 5e13a53

Browse files
committed
[Localization] Make return type of the serialization main cross platform
1 parent 3a4d156 commit 5e13a53

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

tools/swift-serialize-diagnostics/swift-serialize-diagnostics.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,15 +53,14 @@ static llvm::cl::opt<std::string>
5353

5454
int main(int argc, char *argv[]) {
5555
PROGRAM_START(argc, argv);
56-
INITIALIZE_LLVM();
5756

5857
llvm::cl::HideUnrelatedOptions(options::Category);
5958
llvm::cl::ParseCommandLineOptions(argc, argv,
6059
"Swift Serialize Diagnostics Tool\n");
6160

6261
if (!llvm::sys::fs::exists(options::InputFilePath)) {
6362
llvm::errs() << "YAML file not found\n";
64-
return 1;
63+
return EXIT_FAILURE;
6564
}
6665

6766
YAMLLocalizationProducer yaml(options::InputFilePath);
@@ -80,8 +79,8 @@ int main(int argc, char *argv[]) {
8079
if (Serializer.emit(SerializedFilePath.str())) {
8180
llvm::errs() << "Cannot serialize diagnostic file "
8281
<< options::InputFilePath << '\n';
83-
return 1;
82+
return EXIT_FAILURE;
8483
}
8584

86-
return 0;
85+
return EXIT_SUCCESS;
8786
}

0 commit comments

Comments
 (0)