Delete Reloc::Default.
Having an enum member named Default is quite confusing: Is it distinct
from the others?
This patch removes that member and instead uses Optional<Reloc> in
places where we have a user input that still hasn't been maped to the
default value, which is now clear has no be one of the remaining 3
options.
llvm-svn: 269988
diff --git a/llvm/tools/lto/lto.cpp b/llvm/tools/lto/lto.cpp
index 7829dd0..e69f360 100644
--- a/llvm/tools/lto/lto.cpp
+++ b/llvm/tools/lto/lto.cpp
@@ -357,7 +357,7 @@
unwrap(cg)->setCodePICModel(Reloc::DynamicNoPIC);
return false;
case LTO_CODEGEN_PIC_MODEL_DEFAULT:
- unwrap(cg)->setCodePICModel(Reloc::Default);
+ unwrap(cg)->setCodePICModel(None);
return false;
}
sLastErrorString = "Unknown PIC model";
@@ -552,7 +552,7 @@
unwrap(cg)->setCodePICModel(Reloc::DynamicNoPIC);
return false;
case LTO_CODEGEN_PIC_MODEL_DEFAULT:
- unwrap(cg)->setCodePICModel(Reloc::Default);
+ unwrap(cg)->setCodePICModel(None);
return false;
}
sLastErrorString = "Unknown PIC model";