mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-26 21:32:10 +00:00
Remove ".bc" from the end of InputFile if it is there, in
tools/lli/lli.cpp:main(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6317 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
69a79600cb
commit
6ae73dc98f
@ -88,6 +88,13 @@ int main(int argc, char** argv) {
|
||||
EE = ExecutionEngine::createInterpreter(M, Config, DebugMode, TraceMode);
|
||||
|
||||
// Add the module name to the start of the argv vector...
|
||||
// But delete .bc first, since programs (and users) might not expect to
|
||||
// see it.
|
||||
const std::string ByteCodeFileSuffix (".bc");
|
||||
if (InputFile.rfind (ByteCodeFileSuffix) ==
|
||||
InputFile.length () - ByteCodeFileSuffix.length ()) {
|
||||
InputFile.erase (InputFile.length () - ByteCodeFileSuffix.length ());
|
||||
}
|
||||
InputArgv.insert(InputArgv.begin(), InputFile);
|
||||
|
||||
// Run the main function!
|
||||
|
Loading…
Reference in New Issue
Block a user