We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cd3a7bb commit 2638e4eCopy full SHA for 2638e4e
src/tools/compiletest/src/header.rs
@@ -378,7 +378,13 @@ impl TestProps {
378
}
379
380
if let Some(flags) = config.parse_name_value_directive(ln, COMPILE_FLAGS) {
381
- self.compile_flags.extend(split_flags(&flags));
+ let flags = split_flags(&flags);
382
+ for flag in &flags {
383
+ if flag == "--edition" || flag.starts_with("--edition=") {
384
+ panic!("you must use `//@ edition` to configure the edition");
385
+ }
386
387
+ self.compile_flags.extend(flags);
388
389
if config.parse_name_value_directive(ln, INCORRECT_COMPILER_FLAGS).is_some() {
390
panic!("`compiler-flags` directive should be spelled `compile-flags`");
0 commit comments