From 8c34dd82575920209d18f9fb93634886f7edbe26 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Wed, 18 May 2016 22:04:49 +0000 Subject: 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 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 --- llvm/lib/Target/TargetMachineC.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'llvm/lib/Target/TargetMachineC.cpp') diff --git a/llvm/lib/Target/TargetMachineC.cpp b/llvm/lib/Target/TargetMachineC.cpp index 208c59c5f47..02836eaf08e 100644 --- a/llvm/lib/Target/TargetMachineC.cpp +++ b/llvm/lib/Target/TargetMachineC.cpp @@ -105,7 +105,7 @@ LLVMTargetMachineRef LLVMCreateTargetMachine(LLVMTargetRef T, const char* Triple, const char* CPU, const char* Features, LLVMCodeGenOptLevel Level, LLVMRelocMode Reloc, LLVMCodeModel CodeModel) { - Reloc::Model RM; + Optional RM; switch (Reloc){ case LLVMRelocStatic: RM = Reloc::Static; @@ -117,7 +117,6 @@ LLVMTargetMachineRef LLVMCreateTargetMachine(LLVMTargetRef T, RM = Reloc::DynamicNoPIC; break; default: - RM = Reloc::Default; break; } -- cgit v1.2.3