Skip to content

Commit f94142b

Browse files
committed
Update tests to use new proc-macro header
1 parent f592dd9 commit f94142b

File tree

399 files changed

+425
-1084
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

399 files changed

+425
-1084
lines changed

tests/codegen/debuginfo-proc-macro/auxiliary/macro_def.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
#![crate_type = "proc-macro"]
4-
51
extern crate proc_macro;
62
use proc_macro::*;
73

tests/codegen/debuginfo-proc-macro/mir_inlined_twice_var_locs.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// MSVC is different because of the individual allocas.
44
//@ ignore-msvc
55

6-
//@ aux-build:macro_def.rs
6+
//@ proc-macro: macro_def.rs
77

88
// Find the variable.
99
// CHECK-DAG: ![[#var_dbg:]] = !DILocalVariable(name: "n",{{( arg: 1,)?}} scope: ![[#var_scope:]]

tests/incremental/auxiliary/incremental_proc_macro_aux.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72

83
use proc_macro::TokenStream;

tests/incremental/auxiliary/issue-49482-macro-def.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type="proc-macro"]
51
#![allow(non_snake_case)]
62

73
extern crate proc_macro;

tests/incremental/auxiliary/issue-49482-reexport.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//@ proc-macro: issue-49482-macro-def.rs
12
#[macro_use]
23
extern crate issue_49482_macro_def;
34

tests/incremental/auxiliary/issue-54059.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
41
// check that having extern "C" functions in a proc macro doesn't crash.
52

6-
#![crate_type="proc-macro"]
73
#![allow(non_snake_case)]
84

95
extern crate proc_macro;

tests/incremental/incremental_proc_macro.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:incremental_proc_macro_aux.rs
1+
//@ proc-macro: incremental_proc_macro_aux.rs
22
//@ revisions: cfail1 cfail2
33
//@ build-pass (FIXME(62277): could be check-pass?)
44

tests/incremental/issue-110457-same-span-closures/auxiliary/egui_inspect_derive.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
#![crate_type = "proc-macro"]
4-
51
extern crate proc_macro;
62

73
use proc_macro::{Delimiter, Group, Ident, Literal, Punct, Spacing, Span, TokenStream, TokenTree};

tests/incremental/issue-110457-same-span-closures/main.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build: egui_inspect_derive.rs
1+
//@ proc-macro: egui_inspect_derive.rs
22
//@ revisions: cpass1 cpass2
33

44
extern crate egui_inspect_derive;

tests/incremental/issue-49482.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
//@ aux-build:issue-49482-macro-def.rs
21
//@ aux-build:issue-49482-reexport.rs
32
//@ revisions: rpass1
43

tests/incremental/issue-54059.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:issue-54059.rs
1+
//@ proc-macro: issue-54059.rs
22
//@ ignore-windows - dealing with weird symbols issues on dylibs isn't worth it
33
//@ revisions: rpass1
44

tests/incremental/issue-85197-invalid-span/auxiliary/invalid-span-helper-lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//@ proc-macro: respan.rs
12
//@ revisions: rpass1 rpass2
23

34
extern crate respan;

tests/incremental/issue-85197-invalid-span/auxiliary/respan.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72
use proc_macro::TokenStream;
83

tests/incremental/issue-85197-invalid-span/invalid_span_main.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
//@ revisions: rpass1 rpass2
2-
//@ aux-build:respan.rs
32
//@ aux-build:invalid-span-helper-lib.rs
43

54
// This issue has several different parts. The high level idea is:

tests/pretty/attr-derive.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:derive-foo.rs
1+
//@ proc-macro: derive-foo.rs
22
//@ pp-exact
33
// Testing that both the inner item and next outer item are
44
// preserved, and that the first outer item parsed in main is not

tests/pretty/auxiliary/derive-foo.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72

83
use proc_macro::TokenStream;

tests/ui/annotate-snippet/auxiliary/multispan.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
51
#![feature(proc_macro_diagnostic, proc_macro_span, proc_macro_def_site)]
62

73
extern crate proc_macro;

tests/ui/annotate-snippet/multispan.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:multispan.rs
1+
//@ proc-macro: multispan.rs
22
//@ error-pattern:hello to you, too!
33
//@ compile-flags: --error-format human-annotate-rs -Z unstable-options
44

tests/ui/async-await/issues/auxiliary/issue-60674.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
#![crate_type = "proc-macro"]
4-
51
extern crate proc_macro;
62
use proc_macro::TokenStream;
73

tests/ui/async-await/issues/issue-60674.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:issue-60674.rs
1+
//@ proc-macro: issue-60674.rs
22
//@ build-pass (FIXME(62277): could be check-pass?)
33
//@ edition:2018
44

tests/ui/attributes/auxiliary/key-value-expansion.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72
use proc_macro::*;
83

tests/ui/attributes/key-value-expansion.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Regression tests for issue #55414, expansion happens in the value of a key-value attribute,
22
// and the expanded expression is more complex than simply a macro call.
33

4-
//@ aux-build:key-value-expansion.rs
4+
//@ proc-macro: key-value-expansion.rs
55

66
#![feature(rustc_attrs)]
77

tests/ui/attributes/main-removed-2/auxiliary/tokyo.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72
use proc_macro::TokenStream;
83

tests/ui/attributes/main-removed-2/main.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//@ run-pass
2-
//@ aux-build:tokyo.rs
2+
//@ proc-macro: tokyo.rs
33
//@ compile-flags:--extern tokyo
44
//@ edition:2021
55

tests/ui/autodiff/auxiliary/my_macro.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
#![crate_type = "proc-macro"]
4-
51
extern crate proc_macro;
62
use proc_macro::TokenStream;
73

tests/ui/autodiff/visibility.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//@ ignore-enzyme
22
//@ revisions: std_autodiff no_std_autodiff
33
//@[no_std_autodiff] check-pass
4-
//@ aux-build: my_macro.rs
4+
//@ proc-macro: my_macro.rs
55
#![crate_type = "lib"]
66
#![feature(autodiff)]
77

tests/ui/cfg/assume-incomplete-release/assume-incomplete.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//@ run-pass
2-
//@ aux-build:ver-cfg-rel.rs
2+
//@ proc-macro: ver-cfg-rel.rs
33
//@ revisions: assume no_assume
44
//@ [assume]compile-flags: -Z assume-incomplete-release
55

tests/ui/cfg/assume-incomplete-release/auxiliary/ver-cfg-rel.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72
use proc_macro::{TokenStream, TokenTree as Tt};
83
use std::str::FromStr;

tests/ui/crate-loading/auxiliary/proc-macro.rs

-3
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
31
#![crate_name = "reproduction"]
4-
#![crate_type = "proc-macro"]
52

63
extern crate proc_macro;
74
use proc_macro::TokenStream;

tests/ui/crate-loading/cross-compiled-proc-macro.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
//@ edition:2018
22
//@ compile-flags:--extern reproduction
3-
//@ aux-build:proc-macro.rs
3+
//@ proc-macro: proc-macro.rs
44
//@ check-pass
55

66
reproduction::mac!();

tests/ui/derives/auxiliary/derive-marker-tricky.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72
use proc_macro::*;
83

tests/ui/derives/derive-marker-tricky.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// a built-in derive in non-trivial scope (e.g. in a nested module).
33

44
//@ check-pass
5-
//@ aux-build:derive-marker-tricky.rs
5+
//@ proc-macro: derive-marker-tricky.rs
66

77
extern crate derive_marker_tricky;
88

tests/ui/deriving/auxiliary/another-proc-macro.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
51
#![feature(proc_macro_quote)]
62

73
extern crate proc_macro;

tests/ui/deriving/built-in-proc-macro-scope.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//@ check-pass
2-
//@ aux-build: another-proc-macro.rs
2+
//@ proc-macro: another-proc-macro.rs
33
//@ compile-flags: -Zunpretty=expanded
44

55
#![feature(derive_coerce_pointee)]

tests/ui/deriving/built-in-proc-macro-scope.stdout

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#![feature(prelude_import)]
22
#![no_std]
33
//@ check-pass
4-
//@ aux-build: another-proc-macro.rs
4+
//@ proc-macro: another-proc-macro.rs
55
//@ compile-flags: -Zunpretty=expanded
66

77
#![feature(derive_coerce_pointee)]

tests/ui/deriving/proc-macro-attribute-mixing.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
// are in scope.
66

77
//@ check-pass
8-
//@ aux-build: another-proc-macro.rs
8+
//@ proc-macro: another-proc-macro.rs
99
//@ compile-flags: -Zunpretty=expanded
1010

1111
#![feature(derive_coerce_pointee)]

tests/ui/deriving/proc-macro-attribute-mixing.stdout

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// are in scope.
88

99
//@ check-pass
10-
//@ aux-build: another-proc-macro.rs
10+
//@ proc-macro: another-proc-macro.rs
1111
//@ compile-flags: -Zunpretty=expanded
1212

1313
#![feature(derive_coerce_pointee)]

tests/ui/diagnostic_namespace/auxiliary/proc-macro-helper.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
#![crate_type = "proc-macro"]
4-
51
extern crate proc_macro;
62

73
use proc_macro::TokenStream;

tests/ui/diagnostic_namespace/existing_proc_macros.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//@ check-pass
2-
//@ aux-build:proc-macro-helper.rs
2+
//@ proc-macro: proc-macro-helper.rs
33

44
extern crate proc_macro_helper;
55

tests/ui/fmt/auxiliary/format-string-proc-macro.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
4-
#![crate_type = "proc-macro"]
5-
61
extern crate proc_macro;
72

83
use proc_macro::{Delimiter, Group, Ident, Literal, Punct, Spacing, Span, TokenStream, TokenTree};

tests/ui/fmt/format-args-capture-first-literal-is-macro.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:format-string-proc-macro.rs
1+
//@ proc-macro: format-string-proc-macro.rs
22

33
#[macro_use]
44
extern crate format_string_proc_macro;

tests/ui/fmt/format-args-capture-from-pm-first-arg-macro.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:format-string-proc-macro.rs
1+
//@ proc-macro: format-string-proc-macro.rs
22

33
extern crate format_string_proc_macro;
44

tests/ui/fmt/format-args-capture-issue-106408.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
//@ check-pass
2-
//@ aux-build:format-string-proc-macro.rs
2+
//@ proc-macro: format-string-proc-macro.rs
33

44
extern crate format_string_proc_macro;
55

tests/ui/fmt/format-args-capture-macro-hygiene.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:format-string-proc-macro.rs
1+
//@ proc-macro: format-string-proc-macro.rs
22

33
#[macro_use]
44
extern crate format_string_proc_macro;

tests/ui/fmt/format-expanded-string.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:format-string-proc-macro.rs
1+
//@ proc-macro: format-string-proc-macro.rs
22

33
#[macro_use]
44
extern crate format_string_proc_macro;

tests/ui/fmt/indoc-issue-106408.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:format-string-proc-macro.rs
1+
//@ proc-macro: format-string-proc-macro.rs
22
//@ check-pass
33

44
extern crate format_string_proc_macro;

tests/ui/fmt/respanned-literal-issue-106191.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
//@ aux-build:format-string-proc-macro.rs
1+
//@ proc-macro: format-string-proc-macro.rs
22

33
extern crate format_string_proc_macro;
44

tests/ui/hygiene/auxiliary/def-site-async-await.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
//@ edition:2018
2-
3-
extern crate opaque_hygiene;
2+
//@ proc-macro: opaque-hygiene.rs
43

54
pub async fn serve() {
65
opaque_hygiene::make_it!();

tests/ui/hygiene/auxiliary/opaque-hygiene.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
1-
//@ force-host
2-
//@ no-prefer-dynamic
3-
41
#![feature(proc_macro_quote)]
5-
#![crate_type = "proc-macro"]
62

73
extern crate proc_macro;
84
use proc_macro::{TokenStream, quote};

tests/ui/hygiene/issue-77523-def-site-async-await.rs

-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
//@ build-pass
2-
//@ aux-build:opaque-hygiene.rs
32
//@ aux-build:def-site-async-await.rs
43

54
// Regression test for issue #77523

tests/ui/impl-trait/precise-capturing/auxiliary/no-use-pm.rs

-5
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,6 @@
11
// A proc-macro in 2015 that has an RPIT without `use<>` that would cause a
22
// problem with 2024 capturing rules.
33

4-
//@ force-host
5-
//@ no-prefer-dynamic
6-
7-
#![crate_type = "proc-macro"]
8-
94
extern crate proc_macro;
105
use proc_macro::TokenStream;
116

tests/ui/impl-trait/precise-capturing/external-macro.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// has an RPIT will not fail when the call-site is 2024.
33
// https://github.com/rust-lang/rust/issues/132917
44

5-
//@ aux-crate: no_use_pm=no-use-pm.rs
5+
//@ proc-macro: no-use-pm.rs
66
//@ aux-crate: no_use_macro=no-use-macro.rs
77
//@ edition: 2024
88
//@ check-pass

0 commit comments

Comments
 (0)