]> git.lizzy.rs Git - rust.git/commit
ensure that compile-flags arguments are the last in ui tests
authorPietro Albini <pietro.albini@ferrous-systems.com>
Thu, 20 Oct 2022 09:35:28 +0000 (11:35 +0200)
committerPietro Albini <pietro.albini@ferrous-systems.com>
Tue, 25 Oct 2022 08:41:23 +0000 (10:41 +0200)
commit6457df3d4b945f2b56ada653e30116bb2267c004
treef7caca91a2c28cc98e8d3d4fd04180c933053dad
parent31d754a1dfba4d091a05589459708f286d5a231e
ensure that compile-flags arguments are the last in ui tests

Before this commit, compiletest would add `-L path/to/aux` at the end of
the rustc flags, even after the custom ones set with the compile-flags
header comment. This made it impossible to check how rustc would behave
when a flag requiring an argument was passed without the argument,
because the argument would become `-L`.

This PR fixes that by adding the `-L path/to/aux` before the arguments
defined in compile-flags, at least for UI tests. Other test suites might
either be fixed as well by this change, or still present the old
behavior.
src/tools/compiletest/src/runtest.rs