Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
int
Rust
提交
f8e157b3
R
Rust
项目概览
int
/
Rust
大约 1 年 前同步成功
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
Rust
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
f8e157b3
编写于
10月 19, 2022
作者:
J
Josh Stone
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fixup a few tests needing asm support
上级
a24a020e
变更
12
隐藏空白更改
内联
并排
Showing
12 changed file
with
44 addition
and
49 deletion
+44
-49
compiler/rustc_lint/src/builtin.rs
compiler/rustc_lint/src/builtin.rs
+1
-0
compiler/rustc_lint_defs/src/builtin.rs
compiler/rustc_lint_defs/src/builtin.rs
+1
-1
src/test/pretty/raw-str-nonexpr.rs
src/test/pretty/raw-str-nonexpr.rs
+1
-0
src/test/run-make-fulldeps/intrinsic-unreachable/Makefile
src/test/run-make-fulldeps/intrinsic-unreachable/Makefile
+1
-0
src/test/ui/asm/unpretty-expanded.rs
src/test/ui/asm/unpretty-expanded.rs
+1
-0
src/test/ui/asm/unpretty-expanded.stdout
src/test/ui/asm/unpretty-expanded.stdout
+1
-0
src/test/ui/empty_global_asm.rs
src/test/ui/empty_global_asm.rs
+1
-14
src/tools/clippy/tests/ui/entry.fixed
src/tools/clippy/tests/ui/entry.fixed
+1
-0
src/tools/clippy/tests/ui/entry.rs
src/tools/clippy/tests/ui/entry.rs
+1
-0
src/tools/clippy/tests/ui/entry.stderr
src/tools/clippy/tests/ui/entry.stderr
+10
-10
src/tools/clippy/tests/ui/missing_doc.rs
src/tools/clippy/tests/ui/missing_doc.rs
+1
-0
src/tools/clippy/tests/ui/missing_doc.stderr
src/tools/clippy/tests/ui/missing_doc.stderr
+24
-24
未找到文件。
compiler/rustc_lint/src/builtin.rs
浏览文件 @
f8e157b3
...
...
@@ -3176,6 +3176,7 @@ fn is_zero(expr: &hir::Expr<'_>) -> bool {
/// ### Example
///
/// ```rust,compile_fail
/// # #![feature(asm_experimental_arch)]
/// use std::arch::asm;
///
/// fn main() {
...
...
compiler/rustc_lint_defs/src/builtin.rs
浏览文件 @
f8e157b3
...
...
@@ -2878,7 +2878,7 @@
/// ### Example
///
/// ```rust
/// #![feature(naked_functions)]
/// #![feature(
asm_experimental_arch,
naked_functions)]
///
/// use std::arch::asm;
///
...
...
src/test/pretty/raw-str-nonexpr.rs
浏览文件 @
f8e157b3
// needs-asm-support
// pp-exact
#[cfg(foo
=
r#"just parse this"#
)]
...
...
src/test/run-make-fulldeps/intrinsic-unreachable/Makefile
浏览文件 @
f8e157b3
include
../tools.mk
# needs-asm-support
# ignore-windows-msvc
#
# Because of Windows exception handling, the code is not necessarily any shorter.
...
...
src/test/ui/asm/unpretty-expanded.rs
浏览文件 @
f8e157b3
// needs-asm-support
// check-pass
// compile-flags: -Zunpretty=expanded
core
::
arch
::
global_asm!
(
"x: .byte 42"
);
src/test/ui/asm/unpretty-expanded.stdout
浏览文件 @
f8e157b3
...
...
@@ -4,6 +4,7 @@
use ::std::prelude::rust_2015::*;
#[macro_use]
extern crate std;
// needs-asm-support
// check-pass
// compile-flags: -Zunpretty=expanded
global_asm! ("x: .byte 42");
src/test/ui/empty_global_asm.rs
浏览文件 @
f8e157b3
// needs-asm-support
// run-pass
#[allow(unused_imports)]
use
std
::
arch
::
global_asm
;
#[cfg(target_arch
=
"x86"
)]
global_asm!
(
""
);
#[cfg(target_arch
=
"x86_64"
)]
global_asm!
(
""
);
#[cfg(target_arch
=
"arm"
)]
global_asm!
(
""
);
#[cfg(target_arch
=
"aarch64"
)]
global_asm!
(
""
);
#[cfg(target_arch
=
"mips"
)]
global_asm!
(
""
);
fn
main
()
{}
src/tools/clippy/tests/ui/entry.fixed
浏览文件 @
f8e157b3
// needs-asm-support
// run-rustfix
#![allow(unused, clippy::needless_pass_by_value, clippy::collapsible_if)]
...
...
src/tools/clippy/tests/ui/entry.rs
浏览文件 @
f8e157b3
// needs-asm-support
// run-rustfix
#![allow(unused,
clippy::needless_pass_by_value,
clippy::collapsible_if)]
...
...
src/tools/clippy/tests/ui/entry.stderr
浏览文件 @
f8e157b3
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:2
4
:5
--> $DIR/entry.rs:2
5
:5
|
LL | / if !m.contains_key(&k) {
LL | | m.insert(k, v);
...
...
@@ -9,7 +9,7 @@ LL | | }
= note: `-D clippy::map-entry` implied by `-D warnings`
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:
29
:5
--> $DIR/entry.rs:
30
:5
|
LL | / if !m.contains_key(&k) {
LL | | if true {
...
...
@@ -32,7 +32,7 @@ LL + });
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:3
8
:5
--> $DIR/entry.rs:3
9
:5
|
LL | / if !m.contains_key(&k) {
LL | | if true {
...
...
@@ -55,7 +55,7 @@ LL + });
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:4
7
:5
--> $DIR/entry.rs:4
8
:5
|
LL | / if !m.contains_key(&k) {
LL | | if true {
...
...
@@ -79,7 +79,7 @@ LL + }
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:5
7
:5
--> $DIR/entry.rs:5
8
:5
|
LL | / if !m.contains_key(&k) {
LL | | foo();
...
...
@@ -96,7 +96,7 @@ LL + });
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:6
3
:5
--> $DIR/entry.rs:6
4
:5
|
LL | / if !m.contains_key(&k) {
LL | | match 0 {
...
...
@@ -122,7 +122,7 @@ LL + });
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:7
5
:5
--> $DIR/entry.rs:7
6
:5
|
LL | / if !m.contains_key(&k) {
LL | | match 0 {
...
...
@@ -146,7 +146,7 @@ LL + }
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:8
5
:5
--> $DIR/entry.rs:8
6
:5
|
LL | / if !m.contains_key(&k) {
LL | | foo();
...
...
@@ -187,7 +187,7 @@ LL + });
|
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:1
19
:5
--> $DIR/entry.rs:1
20
:5
|
LL | / if !m.contains_key(&m!(k)) {
LL | | m.insert(m!(k), m!(v));
...
...
@@ -195,7 +195,7 @@ LL | | }
| |_____^ help: try this: `m.entry(m!(k)).or_insert_with(|| m!(v));`
error: usage of `contains_key` followed by `insert` on a `HashMap`
--> $DIR/entry.rs:15
1
:5
--> $DIR/entry.rs:15
2
:5
|
LL | / if !m.contains_key(&k) {
LL | | let x = (String::new(), String::new());
...
...
src/tools/clippy/tests/ui/missing_doc.rs
浏览文件 @
f8e157b3
// needs-asm-support
// aux-build: proc_macro_with_span.rs
#![warn(clippy::missing_docs_in_private_items)]
...
...
src/tools/clippy/tests/ui/missing_doc.stderr
浏览文件 @
f8e157b3
error: missing documentation for a type alias
--> $DIR/missing_doc.rs:1
5
:1
--> $DIR/missing_doc.rs:1
6
:1
|
LL | type Typedef = String;
| ^^^^^^^^^^^^^^^^^^^^^^
...
...
@@ -7,37 +7,37 @@ LL | type Typedef = String;
= note: `-D clippy::missing-docs-in-private-items` implied by `-D warnings`
error: missing documentation for a type alias
--> $DIR/missing_doc.rs:1
6
:1
--> $DIR/missing_doc.rs:1
7
:1
|
LL | pub type PubTypedef = String;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a module
--> $DIR/missing_doc.rs:1
8
:1
--> $DIR/missing_doc.rs:1
9
:1
|
LL | mod module_no_dox {}
| ^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a module
--> $DIR/missing_doc.rs:
19
:1
--> $DIR/missing_doc.rs:
20
:1
|
LL | pub mod pub_module_no_dox {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a function
--> $DIR/missing_doc.rs:2
3
:1
--> $DIR/missing_doc.rs:2
4
:1
|
LL | pub fn foo2() {}
| ^^^^^^^^^^^^^^^^
error: missing documentation for a function
--> $DIR/missing_doc.rs:2
4
:1
--> $DIR/missing_doc.rs:2
5
:1
|
LL | fn foo3() {}
| ^^^^^^^^^^^^
error: missing documentation for an enum
--> $DIR/missing_doc.rs:3
8
:1
--> $DIR/missing_doc.rs:3
9
:1
|
LL | / enum Baz {
LL | | BazA { a: isize, b: isize },
...
...
@@ -46,31 +46,31 @@ LL | | }
| |_^
error: missing documentation for a variant
--> $DIR/missing_doc.rs:
39
:5
--> $DIR/missing_doc.rs:
40
:5
|
LL | BazA { a: isize, b: isize },
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a struct field
--> $DIR/missing_doc.rs:
39
:12
--> $DIR/missing_doc.rs:
40
:12
|
LL | BazA { a: isize, b: isize },
| ^^^^^^^^
error: missing documentation for a struct field
--> $DIR/missing_doc.rs:
39
:22
--> $DIR/missing_doc.rs:
40
:22
|
LL | BazA { a: isize, b: isize },
| ^^^^^^^^
error: missing documentation for a variant
--> $DIR/missing_doc.rs:4
0
:5
--> $DIR/missing_doc.rs:4
1
:5
|
LL | BarB,
| ^^^^
error: missing documentation for an enum
--> $DIR/missing_doc.rs:4
3
:1
--> $DIR/missing_doc.rs:4
4
:1
|
LL | / pub enum PubBaz {
LL | | PubBazA { a: isize },
...
...
@@ -78,43 +78,43 @@ LL | | }
| |_^
error: missing documentation for a variant
--> $DIR/missing_doc.rs:4
4
:5
--> $DIR/missing_doc.rs:4
5
:5
|
LL | PubBazA { a: isize },
| ^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a struct field
--> $DIR/missing_doc.rs:4
4
:15
--> $DIR/missing_doc.rs:4
5
:15
|
LL | PubBazA { a: isize },
| ^^^^^^^^
error: missing documentation for a constant
--> $DIR/missing_doc.rs:6
4
:1
--> $DIR/missing_doc.rs:6
5
:1
|
LL | const FOO: u32 = 0;
| ^^^^^^^^^^^^^^^^^^^
error: missing documentation for a constant
--> $DIR/missing_doc.rs:7
1
:1
--> $DIR/missing_doc.rs:7
2
:1
|
LL | pub const FOO4: u32 = 0;
| ^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a static
--> $DIR/missing_doc.rs:7
3
:1
--> $DIR/missing_doc.rs:7
4
:1
|
LL | static BAR: u32 = 0;
| ^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a static
--> $DIR/missing_doc.rs:8
0
:1
--> $DIR/missing_doc.rs:8
1
:1
|
LL | pub static BAR4: u32 = 0;
| ^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a module
--> $DIR/missing_doc.rs:8
2
:1
--> $DIR/missing_doc.rs:8
3
:1
|
LL | / mod internal_impl {
LL | | /// dox
...
...
@@ -126,31 +126,31 @@ LL | | }
| |_^
error: missing documentation for a function
--> $DIR/missing_doc.rs:8
5
:5
--> $DIR/missing_doc.rs:8
6
:5
|
LL | pub fn undocumented1() {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a function
--> $DIR/missing_doc.rs:8
6
:5
--> $DIR/missing_doc.rs:8
7
:5
|
LL | pub fn undocumented2() {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a function
--> $DIR/missing_doc.rs:8
7
:5
--> $DIR/missing_doc.rs:8
8
:5
|
LL | fn undocumented3() {}
| ^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a function
--> $DIR/missing_doc.rs:9
2
:9
--> $DIR/missing_doc.rs:9
3
:9
|
LL | pub fn also_undocumented1() {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: missing documentation for a function
--> $DIR/missing_doc.rs:9
3
:9
--> $DIR/missing_doc.rs:9
4
:9
|
LL | fn also_undocumented2() {}
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录