[llvm-commits] [lld] r158544 - in /lld/trunk/lib/ReaderWriter/MachO: ReferenceKinds.cpp WriterOptionsMachO.cpp
Nick Kledzik
kledzik at apple.com
Fri Jun 15 14:04:32 PDT 2012
Author: kledzik
Date: Fri Jun 15 16:04:32 2012
New Revision: 158544
URL: http://llvm.org/viewvc/llvm-project?rev=158544&view=rev
Log:
remove return statements after llvm_unreachable() as the compiler no longer warns abot missing return values
Modified:
lld/trunk/lib/ReaderWriter/MachO/ReferenceKinds.cpp
lld/trunk/lib/ReaderWriter/MachO/WriterOptionsMachO.cpp
Modified: lld/trunk/lib/ReaderWriter/MachO/ReferenceKinds.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/MachO/ReferenceKinds.cpp?rev=158544&r1=158543&r2=158544&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/MachO/ReferenceKinds.cpp (original)
+++ lld/trunk/lib/ReaderWriter/MachO/ReferenceKinds.cpp Fri Jun 15 16:04:32 2012
@@ -74,7 +74,6 @@
.Case("subordinateLSDA", subordinateLSDA);
llvm_unreachable("invalid x86_64 Reference kind");
- return 0;
}
StringRef KindHandler_x86_64::kindToString(Reference::Kind kind) {
@@ -115,7 +114,6 @@
return StringRef("subordinateLSDA");
}
llvm_unreachable("invalid x86_64 Reference kind");
- return StringRef();
}
bool KindHandler_x86_64::isCallSite(Kind kind) {
@@ -199,7 +197,6 @@
.Case("lazyImmediate", lazyImmediate);
llvm_unreachable("invalid x86 Reference kind");
- return 0;
}
StringRef KindHandler_x86::kindToString(Reference::Kind kind) {
@@ -224,7 +221,6 @@
return StringRef("subordinateLSDA");
}
llvm_unreachable("invalid x86 Reference kind");
- return StringRef();
}
bool KindHandler_x86::isCallSite(Kind kind) {
@@ -294,7 +290,6 @@
.Case("subordinateLSDA", subordinateLSDA);
llvm_unreachable("invalid ARM Reference kind");
- return 0;
}
StringRef KindHandler_arm::kindToString(Reference::Kind kind) {
@@ -325,7 +320,6 @@
return StringRef("subordinateLSDA");
}
llvm_unreachable("invalid ARM Reference kind");
- return StringRef();
}
bool KindHandler_arm::isCallSite(Kind kind) {
Modified: lld/trunk/lib/ReaderWriter/MachO/WriterOptionsMachO.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/ReaderWriter/MachO/WriterOptionsMachO.cpp?rev=158544&r1=158543&r2=158544&view=diff
==============================================================================
--- lld/trunk/lib/ReaderWriter/MachO/WriterOptionsMachO.cpp (original)
+++ lld/trunk/lib/ReaderWriter/MachO/WriterOptionsMachO.cpp Fri Jun 15 16:04:32 2012
@@ -42,7 +42,6 @@
return StringRef("armv7");
}
llvm_unreachable("unknown arch");
- return StringRef("???");
}
uint32_t WriterOptionsMachO::cpuType() const {
@@ -56,7 +55,6 @@
return mach_o::CPU_TYPE_ARM;
}
llvm_unreachable("unknown arch");
- return 0;
}
uint32_t WriterOptionsMachO::cpuSubtype() const {
@@ -71,7 +69,6 @@
return mach_o::CPU_SUBTYPE_ARM_V7;
}
llvm_unreachable("unknown arch");
- return 0;
}
uint64_t WriterOptionsMachO::pageZeroSize() const {
@@ -85,7 +82,6 @@
return 0;
}
llvm_unreachable("unknown outputkind");
- return 0;
}
bool WriterOptionsMachO::addEntryPointLoadCommand() const {
@@ -99,7 +95,6 @@
return false;
}
llvm_unreachable("unknown outputkind");
- return false;
}
bool WriterOptionsMachO::addUnixThreadLoadCommand() const {
@@ -113,7 +108,6 @@
return false;
}
llvm_unreachable("unknown outputkind");
- return false;
}
StringRef WriterOptionsMachO::entryPointName() const {
@@ -136,7 +130,6 @@
return StringRef();
}
llvm_unreachable("unknown outputkind");
- return StringRef();
}
More information about the llvm-commits
mailing list