summaryrefslogtreecommitdiffstats
path: root/debian/patches/ubuntu/ubuntu-ignore-arm-doctest.patch
blob: 4249b18e6c552b8bd6d9c3de5a446b7f914f227e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
From: Simon Chopin <simon.chopin@canonical.com>
Date: Thu, 13 Jun 2024 11:16:41 +0200
Subject: Disable the doctests for the instruction_set errors

Bug: https://github.com/rust-lang/rust/issues/83453
Last-Update: 2022-02-23

The fix is as described in the upstream issue.
---
 compiler/rustc_error_codes/src/error_codes/E0778.md | 4 ++--
 compiler/rustc_error_codes/src/error_codes/E0779.md | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/compiler/rustc_error_codes/src/error_codes/E0778.md b/compiler/rustc_error_codes/src/error_codes/E0778.md
index 467362d..d5688c2 100644
--- a/compiler/rustc_error_codes/src/error_codes/E0778.md
+++ b/compiler/rustc_error_codes/src/error_codes/E0778.md
@@ -16,7 +16,7 @@ specified:
 ```
 #![feature(isa_attribute)]
 
-#[cfg_attr(target_arch="arm", instruction_set(arm::a32))]
+#[cfg_attr(all(target_arch="arm", target_os="none"), instruction_set(arm::a32))]
 fn something() {}
 ```
 
@@ -25,7 +25,7 @@ or:
 ```
 #![feature(isa_attribute)]
 
-#[cfg_attr(target_arch="arm", instruction_set(arm::t32))]
+#[cfg_attr(all(target_arch="arm", target_os="none"), instruction_set(arm::t32))]
 fn something() {}
 ```
 
diff --git a/compiler/rustc_error_codes/src/error_codes/E0779.md b/compiler/rustc_error_codes/src/error_codes/E0779.md
index 146e20c..9d23322 100644
--- a/compiler/rustc_error_codes/src/error_codes/E0779.md
+++ b/compiler/rustc_error_codes/src/error_codes/E0779.md
@@ -21,7 +21,7 @@ error. Example:
 ```
 #![feature(isa_attribute)]
 
-#[cfg_attr(target_arch="arm", instruction_set(arm::a32))] // ok!
+#[cfg_attr(all(target_arch="arm", target_os="none"), instruction_set(arm::a32))] // ok!
 pub fn something() {}
 fn main() {}
 ```