diff options
author | Rui Ueyama <ruiu@google.com> | 2013-07-26 20:54:36 +0000 |
---|---|---|
committer | Rui Ueyama <ruiu@google.com> | 2013-07-26 20:54:36 +0000 |
commit | 9dcbf8b3f68c37a509eba91d3c8dcdef68ca09a2 (patch) | |
tree | bb07b6d2f6e6168c66f41a001288d063c2a20e22 /lld/unittests/DriverTests/WinLinkDriverTest.cpp | |
parent | 8bce21c154fa363b3d8ae0d8fdba4ffec6931df4 (diff) | |
download | bcm5719-llvm-9dcbf8b3f68c37a509eba91d3c8dcdef68ca09a2.tar.gz bcm5719-llvm-9dcbf8b3f68c37a509eba91d3c8dcdef68ca09a2.zip |
[PECOFF][Driver] Fix a bug that -mllvm does not take any arguments.
llvm-svn: 187243
Diffstat (limited to 'lld/unittests/DriverTests/WinLinkDriverTest.cpp')
-rw-r--r-- | lld/unittests/DriverTests/WinLinkDriverTest.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lld/unittests/DriverTests/WinLinkDriverTest.cpp b/lld/unittests/DriverTests/WinLinkDriverTest.cpp index 89fea5a3097..da4e434a615 100644 --- a/lld/unittests/DriverTests/WinLinkDriverTest.cpp +++ b/lld/unittests/DriverTests/WinLinkDriverTest.cpp @@ -66,6 +66,13 @@ TEST_F(WinLinkParserTest, UnixStyleOption) { EXPECT_EQ("a.obj", inputFile(0)); } +TEST_F(WinLinkParserTest, Mllvm) { + EXPECT_FALSE(parse("link.exe", "-mllvm", "-debug", "a.obj", nullptr)); + const std::vector<const char *> &options = _info.llvmOptions(); + EXPECT_EQ(1U, options.size()); + EXPECT_EQ("-debug", options[0]); +} + TEST_F(WinLinkParserTest, NoFileExtension) { EXPECT_FALSE(parse("link.exe", "foo", "bar", nullptr)); EXPECT_EQ("foo.exe", _info.outputPath()); |