Skip to content

Commit 73a6ef6

Browse files
tests: Dedup unsupported ABI and cannot-be-called test
1 parent b6d9ace commit 73a6ef6

16 files changed

+252
-609
lines changed

tests/ui/abi/cannot-be-called.avr.stderr

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,71 @@
11
error[E0570]: "msp430-interrupt" is not a supported ABI for the current target
2-
--> $DIR/cannot-be-called.rs:36:8
2+
--> $DIR/cannot-be-called.rs:38:8
33
|
44
LL | extern "msp430-interrupt" fn msp430() {}
55
| ^^^^^^^^^^^^^^^^^^
66

77
error[E0570]: "riscv-interrupt-m" is not a supported ABI for the current target
8-
--> $DIR/cannot-be-called.rs:40:8
8+
--> $DIR/cannot-be-called.rs:42:8
99
|
1010
LL | extern "riscv-interrupt-m" fn riscv_m() {}
1111
| ^^^^^^^^^^^^^^^^^^^
1212

1313
error[E0570]: "riscv-interrupt-s" is not a supported ABI for the current target
14-
--> $DIR/cannot-be-called.rs:42:8
14+
--> $DIR/cannot-be-called.rs:44:8
1515
|
1616
LL | extern "riscv-interrupt-s" fn riscv_s() {}
1717
| ^^^^^^^^^^^^^^^^^^^
1818

1919
error[E0570]: "x86-interrupt" is not a supported ABI for the current target
20-
--> $DIR/cannot-be-called.rs:44:8
20+
--> $DIR/cannot-be-called.rs:46:8
2121
|
2222
LL | extern "x86-interrupt" fn x86() {}
2323
| ^^^^^^^^^^^^^^^
2424

2525
error[E0570]: "msp430-interrupt" is not a supported ABI for the current target
26-
--> $DIR/cannot-be-called.rs:60:25
26+
--> $DIR/cannot-be-called.rs:65:25
2727
|
2828
LL | fn msp430_ptr(f: extern "msp430-interrupt" fn()) {
2929
| ^^^^^^^^^^^^^^^^^^
3030

3131
error[E0570]: "riscv-interrupt-m" is not a supported ABI for the current target
32-
--> $DIR/cannot-be-called.rs:72:26
32+
--> $DIR/cannot-be-called.rs:77:26
3333
|
3434
LL | fn riscv_m_ptr(f: extern "riscv-interrupt-m" fn()) {
3535
| ^^^^^^^^^^^^^^^^^^^
3636

3737
error[E0570]: "riscv-interrupt-s" is not a supported ABI for the current target
38-
--> $DIR/cannot-be-called.rs:78:26
38+
--> $DIR/cannot-be-called.rs:83:26
3939
|
4040
LL | fn riscv_s_ptr(f: extern "riscv-interrupt-s" fn()) {
4141
| ^^^^^^^^^^^^^^^^^^^
4242

4343
error[E0570]: "x86-interrupt" is not a supported ABI for the current target
44-
--> $DIR/cannot-be-called.rs:84:22
44+
--> $DIR/cannot-be-called.rs:89:22
4545
|
4646
LL | fn x86_ptr(f: extern "x86-interrupt" fn()) {
4747
| ^^^^^^^^^^^^^^^
4848

4949
error: functions with the "avr-interrupt" ABI cannot be called
50-
--> $DIR/cannot-be-called.rs:50:5
50+
--> $DIR/cannot-be-called.rs:53:5
5151
|
5252
LL | avr();
5353
| ^^^^^
5454
|
5555
note: an `extern "avr-interrupt"` function can only be called using inline assembly
56-
--> $DIR/cannot-be-called.rs:50:5
56+
--> $DIR/cannot-be-called.rs:53:5
5757
|
5858
LL | avr();
5959
| ^^^^^
6060

6161
error: functions with the "avr-interrupt" ABI cannot be called
62-
--> $DIR/cannot-be-called.rs:68:5
62+
--> $DIR/cannot-be-called.rs:73:5
6363
|
6464
LL | f()
6565
| ^^^
6666
|
6767
note: an `extern "avr-interrupt"` function can only be called using inline assembly
68-
--> $DIR/cannot-be-called.rs:68:5
68+
--> $DIR/cannot-be-called.rs:73:5
6969
|
7070
LL | f()
7171
| ^^^

tests/ui/abi/cannot-be-called.i686.stderr

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,71 @@
11
error[E0570]: "msp430-interrupt" is not a supported ABI for the current target
2-
--> $DIR/cannot-be-called.rs:36:8
2+
--> $DIR/cannot-be-called.rs:38:8
33
|
44
LL | extern "msp430-interrupt" fn msp430() {}
55
| ^^^^^^^^^^^^^^^^^^
66

77
error[E0570]: "avr-interrupt" is not a supported ABI for the current target
8-
--> $DIR/cannot-be-called.rs:38:8
8+
--> $DIR/cannot-be-called.rs:40:8
99
|
1010
LL | extern "avr-interrupt" fn avr() {}
1111
| ^^^^^^^^^^^^^^^
1212

1313
error[E0570]: "riscv-interrupt-m" is not a supported ABI for the current target
14-
--> $DIR/cannot-be-called.rs:40:8
14+
--> $DIR/cannot-be-called.rs:42:8
1515
|
1616
LL | extern "riscv-interrupt-m" fn riscv_m() {}
1717
| ^^^^^^^^^^^^^^^^^^^
1818

1919
error[E0570]: "riscv-interrupt-s" is not a supported ABI for the current target
20-
--> $DIR/cannot-be-called.rs:42:8
20+
--> $DIR/cannot-be-called.rs:44:8
2121
|
2222
LL | extern "riscv-interrupt-s" fn riscv_s() {}
2323
| ^^^^^^^^^^^^^^^^^^^
2424

2525
error[E0570]: "msp430-interrupt" is not a supported ABI for the current target
26-
--> $DIR/cannot-be-called.rs:60:25
26+
--> $DIR/cannot-be-called.rs:65:25
2727
|
2828
LL | fn msp430_ptr(f: extern "msp430-interrupt" fn()) {
2929
| ^^^^^^^^^^^^^^^^^^
3030

3131
error[E0570]: "avr-interrupt" is not a supported ABI for the current target
32-
--> $DIR/cannot-be-called.rs:66:22
32+
--> $DIR/cannot-be-called.rs:71:22
3333
|
3434
LL | fn avr_ptr(f: extern "avr-interrupt" fn()) {
3535
| ^^^^^^^^^^^^^^^
3636

3737
error[E0570]: "riscv-interrupt-m" is not a supported ABI for the current target
38-
--> $DIR/cannot-be-called.rs:72:26
38+
--> $DIR/cannot-be-called.rs:77:26
3939
|
4040
LL | fn riscv_m_ptr(f: extern "riscv-interrupt-m" fn()) {
4141
| ^^^^^^^^^^^^^^^^^^^
4242

4343
error[E0570]: "riscv-interrupt-s" is not a supported ABI for the current target
44-
--> $DIR/cannot-be-called.rs:78:26
44+
--> $DIR/cannot-be-called.rs:83:26
4545
|
4646
LL | fn riscv_s_ptr(f: extern "riscv-interrupt-s" fn()) {
4747
| ^^^^^^^^^^^^^^^^^^^
4848

4949
error: functions with the "x86-interrupt" ABI cannot be called
50-
--> $DIR/cannot-be-called.rs:56:5
50+
--> $DIR/cannot-be-called.rs:59:5
5151
|
5252
LL | x86();
5353
| ^^^^^
5454
|
5555
note: an `extern "x86-interrupt"` function can only be called using inline assembly
56-
--> $DIR/cannot-be-called.rs:56:5
56+
--> $DIR/cannot-be-called.rs:59:5
5757
|
5858
LL | x86();
5959
| ^^^^^
6060

6161
error: functions with the "x86-interrupt" ABI cannot be called
62-
--> $DIR/cannot-be-called.rs:86:5
62+
--> $DIR/cannot-be-called.rs:91:5
6363
|
6464
LL | f()
6565
| ^^^
6666
|
6767
note: an `extern "x86-interrupt"` function can only be called using inline assembly
68-
--> $DIR/cannot-be-called.rs:86:5
68+
--> $DIR/cannot-be-called.rs:91:5
6969
|
7070
LL | f()
7171
| ^^^

tests/ui/abi/cannot-be-called.msp430.stderr

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,71 @@
11
error[E0570]: "avr-interrupt" is not a supported ABI for the current target
2-
--> $DIR/cannot-be-called.rs:38:8
2+
--> $DIR/cannot-be-called.rs:40:8
33
|
44
LL | extern "avr-interrupt" fn avr() {}
55
| ^^^^^^^^^^^^^^^
66

77
error[E0570]: "riscv-interrupt-m" is not a supported ABI for the current target
8-
--> $DIR/cannot-be-called.rs:40:8
8+
--> $DIR/cannot-be-called.rs:42:8
99
|
1010
LL | extern "riscv-interrupt-m" fn riscv_m() {}
1111
| ^^^^^^^^^^^^^^^^^^^
1212

1313
error[E0570]: "riscv-interrupt-s" is not a supported ABI for the current target
14-
--> $DIR/cannot-be-called.rs:42:8
14+
--> $DIR/cannot-be-called.rs:44:8
1515
|
1616
LL | extern "riscv-interrupt-s" fn riscv_s() {}
1717
| ^^^^^^^^^^^^^^^^^^^
1818

1919
error[E0570]: "x86-interrupt" is not a supported ABI for the current target
20-
--> $DIR/cannot-be-called.rs:44:8
20+
--> $DIR/cannot-be-called.rs:46:8
2121
|
2222
LL | extern "x86-interrupt" fn x86() {}
2323
| ^^^^^^^^^^^^^^^
2424

2525
error[E0570]: "avr-interrupt" is not a supported ABI for the current target
26-
--> $DIR/cannot-be-called.rs:66:22
26+
--> $DIR/cannot-be-called.rs:71:22
2727
|
2828
LL | fn avr_ptr(f: extern "avr-interrupt" fn()) {
2929
| ^^^^^^^^^^^^^^^
3030

3131
error[E0570]: "riscv-interrupt-m" is not a supported ABI for the current target
32-
--> $DIR/cannot-be-called.rs:72:26
32+
--> $DIR/cannot-be-called.rs:77:26
3333
|
3434
LL | fn riscv_m_ptr(f: extern "riscv-interrupt-m" fn()) {
3535
| ^^^^^^^^^^^^^^^^^^^
3636

3737
error[E0570]: "riscv-interrupt-s" is not a supported ABI for the current target
38-
--> $DIR/cannot-be-called.rs:78:26
38+
--> $DIR/cannot-be-called.rs:83:26
3939
|
4040
LL | fn riscv_s_ptr(f: extern "riscv-interrupt-s" fn()) {
4141
| ^^^^^^^^^^^^^^^^^^^
4242

4343
error[E0570]: "x86-interrupt" is not a supported ABI for the current target
44-
--> $DIR/cannot-be-called.rs:84:22
44+
--> $DIR/cannot-be-called.rs:89:22
4545
|
4646
LL | fn x86_ptr(f: extern "x86-interrupt" fn()) {
4747
| ^^^^^^^^^^^^^^^
4848

4949
error: functions with the "msp430-interrupt" ABI cannot be called
50-
--> $DIR/cannot-be-called.rs:48:5
50+
--> $DIR/cannot-be-called.rs:51:5
5151
|
5252
LL | msp430();
5353
| ^^^^^^^^
5454
|
5555
note: an `extern "msp430-interrupt"` function can only be called using inline assembly
56-
--> $DIR/cannot-be-called.rs:48:5
56+
--> $DIR/cannot-be-called.rs:51:5
5757
|
5858
LL | msp430();
5959
| ^^^^^^^^
6060

6161
error: functions with the "msp430-interrupt" ABI cannot be called
62-
--> $DIR/cannot-be-called.rs:62:5
62+
--> $DIR/cannot-be-called.rs:67:5
6363
|
6464
LL | f()
6565
| ^^^
6666
|
6767
note: an `extern "msp430-interrupt"` function can only be called using inline assembly
68-
--> $DIR/cannot-be-called.rs:62:5
68+
--> $DIR/cannot-be-called.rs:67:5
6969
|
7070
LL | f()
7171
| ^^^

tests/ui/abi/cannot-be-called.riscv32.stderr

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,83 @@
11
error[E0570]: "msp430-interrupt" is not a supported ABI for the current target
2-
--> $DIR/cannot-be-called.rs:36:8
2+
--> $DIR/cannot-be-called.rs:38:8
33
|
44
LL | extern "msp430-interrupt" fn msp430() {}
55
| ^^^^^^^^^^^^^^^^^^
66

77
error[E0570]: "avr-interrupt" is not a supported ABI for the current target
8-
--> $DIR/cannot-be-called.rs:38:8
8+
--> $DIR/cannot-be-called.rs:40:8
99
|
1010
LL | extern "avr-interrupt" fn avr() {}
1111
| ^^^^^^^^^^^^^^^
1212

1313
error[E0570]: "x86-interrupt" is not a supported ABI for the current target
14-
--> $DIR/cannot-be-called.rs:44:8
14+
--> $DIR/cannot-be-called.rs:46:8
1515
|
1616
LL | extern "x86-interrupt" fn x86() {}
1717
| ^^^^^^^^^^^^^^^
1818

1919
error[E0570]: "msp430-interrupt" is not a supported ABI for the current target
20-
--> $DIR/cannot-be-called.rs:60:25
20+
--> $DIR/cannot-be-called.rs:65:25
2121
|
2222
LL | fn msp430_ptr(f: extern "msp430-interrupt" fn()) {
2323
| ^^^^^^^^^^^^^^^^^^
2424

2525
error[E0570]: "avr-interrupt" is not a supported ABI for the current target
26-
--> $DIR/cannot-be-called.rs:66:22
26+
--> $DIR/cannot-be-called.rs:71:22
2727
|
2828
LL | fn avr_ptr(f: extern "avr-interrupt" fn()) {
2929
| ^^^^^^^^^^^^^^^
3030

3131
error[E0570]: "x86-interrupt" is not a supported ABI for the current target
32-
--> $DIR/cannot-be-called.rs:84:22
32+
--> $DIR/cannot-be-called.rs:89:22
3333
|
3434
LL | fn x86_ptr(f: extern "x86-interrupt" fn()) {
3535
| ^^^^^^^^^^^^^^^
3636

3737
error: functions with the "riscv-interrupt-m" ABI cannot be called
38-
--> $DIR/cannot-be-called.rs:52:5
38+
--> $DIR/cannot-be-called.rs:55:5
3939
|
4040
LL | riscv_m();
4141
| ^^^^^^^^^
4242
|
4343
note: an `extern "riscv-interrupt-m"` function can only be called using inline assembly
44-
--> $DIR/cannot-be-called.rs:52:5
44+
--> $DIR/cannot-be-called.rs:55:5
4545
|
4646
LL | riscv_m();
4747
| ^^^^^^^^^
4848

4949
error: functions with the "riscv-interrupt-s" ABI cannot be called
50-
--> $DIR/cannot-be-called.rs:54:5
50+
--> $DIR/cannot-be-called.rs:57:5
5151
|
5252
LL | riscv_s();
5353
| ^^^^^^^^^
5454
|
5555
note: an `extern "riscv-interrupt-s"` function can only be called using inline assembly
56-
--> $DIR/cannot-be-called.rs:54:5
56+
--> $DIR/cannot-be-called.rs:57:5
5757
|
5858
LL | riscv_s();
5959
| ^^^^^^^^^
6060

6161
error: functions with the "riscv-interrupt-m" ABI cannot be called
62-
--> $DIR/cannot-be-called.rs:74:5
62+
--> $DIR/cannot-be-called.rs:79:5
6363
|
6464
LL | f()
6565
| ^^^
6666
|
6767
note: an `extern "riscv-interrupt-m"` function can only be called using inline assembly
68-
--> $DIR/cannot-be-called.rs:74:5
68+
--> $DIR/cannot-be-called.rs:79:5
6969
|
7070
LL | f()
7171
| ^^^
7272

7373
error: functions with the "riscv-interrupt-s" ABI cannot be called
74-
--> $DIR/cannot-be-called.rs:80:5
74+
--> $DIR/cannot-be-called.rs:85:5
7575
|
7676
LL | f()
7777
| ^^^
7878
|
7979
note: an `extern "riscv-interrupt-s"` function can only be called using inline assembly
80-
--> $DIR/cannot-be-called.rs:80:5
80+
--> $DIR/cannot-be-called.rs:85:5
8181
|
8282
LL | f()
8383
| ^^^

0 commit comments

Comments
 (0)