Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
int
Rust
提交
bf544fa9
R
Rust
项目概览
int
/
Rust
11 个月 前同步成功
通知
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,发现更多精彩内容 >>
提交
bf544fa9
编写于
10月 31, 2018
作者:
F
Felix S. Klock II
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
remove `#[rustc_error]` from ui/ tests that remain compile-fail tests.
上级
8315b11b
变更
41
隐藏空白更改
内联
并排
Showing
41 changed file
with
82 addition
and
82 deletion
+82
-82
src/test/ui/asm/asm-bad-clobber.rs
src/test/ui/asm/asm-bad-clobber.rs
+2
-2
src/test/ui/coherence/coherence_copy_like_err_fundamental_struct_tuple.rs
...rence/coherence_copy_like_err_fundamental_struct_tuple.rs
+2
-2
src/test/ui/coherence/coherence_local_err_struct.rs
src/test/ui/coherence/coherence_local_err_struct.rs
+2
-2
src/test/ui/coherence/coherence_local_err_tuple.rs
src/test/ui/coherence/coherence_local_err_tuple.rs
+2
-2
src/test/ui/feature-gates/feature-gate-custom_attribute.rs
src/test/ui/feature-gates/feature-gate-custom_attribute.rs
+2
-2
src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs
src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs
+2
-2
src/test/ui/on-unimplemented/multiple-impls.rs
src/test/ui/on-unimplemented/multiple-impls.rs
+2
-2
src/test/ui/on-unimplemented/on-impl.rs
src/test/ui/on-unimplemented/on-impl.rs
+2
-2
src/test/ui/on-unimplemented/slice-index.rs
src/test/ui/on-unimplemented/slice-index.rs
+2
-2
src/test/ui/regions/regions-outlives-projection-container-hrtb.rs
.../ui/regions/regions-outlives-projection-container-hrtb.rs
+2
-2
src/test/ui/retslot-cast.rs
src/test/ui/retslot-cast.rs
+2
-2
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.rs
...nfer-outlives/regions-outlives-nominal-type-region-rev.rs
+2
-2
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.rs
...93-infer-outlives/regions-outlives-nominal-type-region.rs
+2
-2
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.rs
...-infer-outlives/regions-outlives-nominal-type-type-rev.rs
+2
-2
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.rs
...2093-infer-outlives/regions-outlives-nominal-type-type.rs
+2
-2
src/test/ui/variance/variance-btree-invariant-types.rs
src/test/ui/variance/variance-btree-invariant-types.rs
+2
-2
src/test/ui/variance/variance-use-contravariant-struct-1.rs
src/test/ui/variance/variance-use-contravariant-struct-1.rs
+2
-2
src/test/ui/variance/variance-use-invariant-struct-1.rs
src/test/ui/variance/variance-use-invariant-struct-1.rs
+2
-2
src/test/ui/wf/wf-array-elem-sized.rs
src/test/ui/wf/wf-array-elem-sized.rs
+2
-2
src/test/ui/wf/wf-const-type.rs
src/test/ui/wf/wf-const-type.rs
+2
-2
src/test/ui/wf/wf-enum-bound.rs
src/test/ui/wf/wf-enum-bound.rs
+2
-2
src/test/ui/wf/wf-enum-fields-struct-variant.rs
src/test/ui/wf/wf-enum-fields-struct-variant.rs
+2
-2
src/test/ui/wf/wf-enum-fields.rs
src/test/ui/wf/wf-enum-fields.rs
+2
-2
src/test/ui/wf/wf-fn-where-clause.rs
src/test/ui/wf/wf-fn-where-clause.rs
+2
-2
src/test/ui/wf/wf-impl-associated-type-region.rs
src/test/ui/wf/wf-impl-associated-type-region.rs
+2
-2
src/test/ui/wf/wf-impl-associated-type-trait.rs
src/test/ui/wf/wf-impl-associated-type-trait.rs
+2
-2
src/test/ui/wf/wf-in-fn-type-static.rs
src/test/ui/wf/wf-in-fn-type-static.rs
+2
-2
src/test/ui/wf/wf-in-fn-where-clause.rs
src/test/ui/wf/wf-in-fn-where-clause.rs
+2
-2
src/test/ui/wf/wf-in-obj-type-static.rs
src/test/ui/wf/wf-in-obj-type-static.rs
+2
-2
src/test/ui/wf/wf-inherent-impl-method-where-clause.rs
src/test/ui/wf/wf-inherent-impl-method-where-clause.rs
+2
-2
src/test/ui/wf/wf-inherent-impl-where-clause.rs
src/test/ui/wf/wf-inherent-impl-where-clause.rs
+2
-2
src/test/ui/wf/wf-static-type.rs
src/test/ui/wf/wf-static-type.rs
+2
-2
src/test/ui/wf/wf-struct-bound.rs
src/test/ui/wf/wf-struct-bound.rs
+2
-2
src/test/ui/wf/wf-struct-field.rs
src/test/ui/wf/wf-struct-field.rs
+2
-2
src/test/ui/wf/wf-trait-associated-type-bound.rs
src/test/ui/wf/wf-trait-associated-type-bound.rs
+2
-2
src/test/ui/wf/wf-trait-associated-type-region.rs
src/test/ui/wf/wf-trait-associated-type-region.rs
+2
-2
src/test/ui/wf/wf-trait-associated-type-trait.rs
src/test/ui/wf/wf-trait-associated-type-trait.rs
+2
-2
src/test/ui/wf/wf-trait-bound.rs
src/test/ui/wf/wf-trait-bound.rs
+2
-2
src/test/ui/wf/wf-trait-default-fn-arg.rs
src/test/ui/wf/wf-trait-default-fn-arg.rs
+2
-2
src/test/ui/wf/wf-trait-default-fn-where-clause.rs
src/test/ui/wf/wf-trait-default-fn-where-clause.rs
+2
-2
src/test/ui/wf/wf-trait-fn-where-clause.rs
src/test/ui/wf/wf-trait-fn-where-clause.rs
+2
-2
未找到文件。
src/test/ui/asm/asm-bad-clobber.rs
浏览文件 @
bf544fa9
...
...
@@ -21,11 +21,11 @@
// ignore-mips
// ignore-mips64
#![feature(asm
,
rustc_attrs
)]
#![feature(asm)]
#[cfg(any(target_arch
=
"x86"
,
target_arch
=
"x86_64"
))]
#[rustc_error]
pub
fn
main
()
{
unsafe
{
// clobber formatted as register input/output
...
...
src/test/ui/coherence/coherence_copy_like_err_fundamental_struct_tuple.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
// aux-build:coherence_copy_like_lib.rs
#![feature(rustc_attrs)]
extern
crate
coherence_copy_like_lib
as
lib
;
...
...
@@ -26,5 +26,5 @@ impl<T: lib::MyCopy> MyTrait for T { }
// Tuples are not fundamental.
impl
MyTrait
for
lib
::
MyFundamentalStruct
<
(
MyType
,)
>
{
}
//~ ERROR E0119
#[rustc_error]
fn
main
()
{
}
src/test/ui/coherence/coherence_local_err_struct.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
// aux-build:coherence_copy_like_lib.rs
#![feature(rustc_attrs)]
#![allow(dead_code)]
extern
crate
coherence_copy_like_lib
as
lib
;
...
...
@@ -25,5 +25,5 @@ struct MyType { x: i32 }
// MyStruct is not fundamental.
impl
lib
::
MyCopy
for
lib
::
MyStruct
<
MyType
>
{
}
//~ ERROR E0117
#[rustc_error]
fn
main
()
{
}
src/test/ui/coherence/coherence_local_err_tuple.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
// aux-build:coherence_copy_like_lib.rs
#![feature(rustc_attrs)]
#![allow(dead_code)]
extern
crate
coherence_copy_like_lib
as
lib
;
...
...
@@ -25,5 +25,5 @@ struct MyType { x: i32 }
// Tuples are not fundamental, so this is not a local impl.
impl
lib
::
MyCopy
for
(
MyType
,)
{
}
//~ ERROR E0117
#[rustc_error]
fn
main
()
{
}
src/test/ui/feature-gates/feature-gate-custom_attribute.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Check that literals in attributes parse just fine.
#![feature(rustc_attrs)]
#![allow(dead_code)]
#![allow(unused_variables)]
...
...
@@ -29,5 +29,5 @@
#[fake_doc(
r"doc"
)]
//~ ERROR attribute `fake_doc` is currently unknown
struct
Q
{
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/lifetimes/lifetime-bound-will-change-warning.rs
浏览文件 @
bf544fa9
...
...
@@ -15,7 +15,7 @@
#![allow(dead_code)]
#![allow(unused_variables)]
#![feature(rustc_attrs)]
extern
crate
lifetime_bound_will_change_warning_lib
as
lib
;
...
...
@@ -59,6 +59,6 @@ fn test3cc<'a>(x: &'a Box<Fn()+'static>) {
lib
::
ref_obj
(
x
)
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/on-unimplemented/multiple-impls.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test if the on_unimplemented message override works
#![feature(on_unimplemented)]
#![feature(rustc_attrs)]
struct
Foo
<
T
>
(
T
);
struct
Bar
<
T
>
(
T
);
...
...
@@ -38,7 +38,7 @@ fn index(&self, _index: Bar<usize>) -> &i32 {
}
}
#[rustc_error]
fn
main
()
{
Index
::
index
(
&
[]
as
&
[
i32
],
2u32
);
//~^ ERROR E0277
...
...
src/test/ui/on-unimplemented/on-impl.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test if the on_unimplemented message override works
#![feature(on_unimplemented)]
#![feature(rustc_attrs)]
#[rustc_on_unimplemented
=
"invalid"
]
trait
Index
<
Idx
:
?
Sized
>
{
...
...
@@ -27,7 +27,7 @@ fn index(&self, index: usize) -> &i32 {
}
}
#[rustc_error]
fn
main
()
{
Index
::
<
u32
>
::
index
(
&
[
1
,
2
,
3
]
as
&
[
i32
],
2u32
);
//~^ ERROR E0277
...
...
src/test/ui/on-unimplemented/slice-index.rs
浏览文件 @
bf544fa9
...
...
@@ -11,11 +11,11 @@
// Test new Index error message for slices
// ignore-tidy-linelength
#![feature(rustc_attrs)]
use
std
::
ops
::
Index
;
#[rustc_error]
fn
main
()
{
let
x
=
&
[
1
,
2
,
3
]
as
&
[
i32
];
x
[
1i32
];
//~ ERROR E0277
...
...
src/test/ui/regions/regions-outlives-projection-container-hrtb.rs
浏览文件 @
bf544fa9
...
...
@@ -12,7 +12,7 @@
// "outlives" requirements. Issue #22246.
#![allow(dead_code)]
#![feature(rustc_attrs)]
///////////////////////////////////////////////////////////////////////////
...
...
@@ -64,6 +64,6 @@ fn with_assoc_sub<'a,'b>() {
//~^ ERROR reference has a longer lifetime
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/retslot-cast.rs
浏览文件 @
bf544fa9
...
...
@@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![feature(rustc_attrs)]
#![allow(warnings)]
pub
fn
fail
(
x
:
Option
<&
(
Iterator
<
Item
=
()
>+
Send
)
>
)
...
...
@@ -29,5 +29,5 @@ pub fn inner(x: Option<&(Iterator<Item=()>+Send)>)
x
}
#[rustc_error]
fn
main
()
{}
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region-rev.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
//
// Rule OutlivesNominalType from RFC 1214.
#![feature(rustc_attrs)]
#![allow(dead_code)]
mod
rev_variant_struct_region
{
...
...
@@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-region.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
//
// Rule OutlivesNominalType from RFC 1214.
#![feature(rustc_attrs)]
#![allow(dead_code)]
mod
variant_struct_region
{
...
...
@@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type-rev.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
//
// Rule OutlivesNominalType from RFC 1214.
#![feature(rustc_attrs)]
#![allow(dead_code)]
mod
variant_struct_type
{
...
...
@@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/rfc-2093-infer-outlives/regions-outlives-nominal-type-type.rs
浏览文件 @
bf544fa9
...
...
@@ -13,7 +13,7 @@
//
// Rule OutlivesNominalType from RFC 1214.
#![feature(rustc_attrs)]
#![allow(dead_code)]
mod
variant_struct_type
{
...
...
@@ -28,5 +28,5 @@ impl<'a, 'b> Trait<'a, 'b> for usize {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/variance/variance-btree-invariant-types.rs
浏览文件 @
bf544fa9
...
...
@@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![feature(rustc_attrs)]
use
std
::
collections
::
btree_map
::{
IterMut
,
OccupiedEntry
,
VacantEntry
};
...
...
@@ -59,5 +59,5 @@ fn vac_contra_val<'a, 'new>(v: VacantEntry<'a, (), &'new ()>)
v
//~ ERROR mismatched types
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/variance/variance-use-contravariant-struct-1.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test various uses of structs with distint variances to make sure
// they permit lifetimes to be approximated as expected.
#![feature(rustc_attrs)]
struct
SomeStruct
<
T
>
(
fn
(
T
));
...
...
@@ -22,5 +22,5 @@ fn foo<'min,'max>(v: SomeStruct<&'max ()>)
v
//~ ERROR mismatched types
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/variance/variance-use-invariant-struct-1.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test various uses of structs with distint variances to make sure
// they permit lifetimes to be approximated as expected.
#![feature(rustc_attrs)]
struct
SomeStruct
<
T
>
(
*
mut
T
);
...
...
@@ -29,5 +29,5 @@ fn bar<'min,'max>(v: SomeStruct<&'min ()>)
v
//~ ERROR mismatched types
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-array-elem-sized.rs
浏览文件 @
bf544fa9
...
...
@@ -10,12 +10,12 @@
// Check that array elemen types must be Sized. Issue #25692.
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
Foo
{
foo
:
[[
u8
]],
//~ ERROR E0277
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-const-type.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check the types of constants are well-formed.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
IsCopy
<
T
:
Copy
>
{
t
:
T
}
...
...
@@ -20,5 +20,5 @@ struct IsCopy<T:Copy> { t: T }
const
FOO
:
IsCopy
<
Option
<
NotCopy
>>
=
IsCopy
{
t
:
None
};
//~^ ERROR E0277
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-enum-bound.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check enum bounds for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -22,5 +22,5 @@ enum SomeEnum<T,U> //~ ERROR E0277
SomeVariant
(
T
,
U
)
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-enum-fields-struct-variant.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check struct fields for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
IsCopy
<
T
:
Copy
>
{
...
...
@@ -24,5 +24,5 @@ enum AnotherEnum<A> {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-enum-fields.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check struct fields for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
IsCopy
<
T
:
Copy
>
{
...
...
@@ -22,5 +22,5 @@ enum SomeEnum<A> {
SomeVariant
(
IsCopy
<
A
>
)
//~ ERROR E0277
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-fn-where-clause.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Test that we check where-clauses on fn items.
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -23,5 +23,5 @@ fn bar() where Vec<dyn Copy>:, {}
//~^ ERROR E0277
//~| ERROR E0038
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-impl-associated-type-region.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Check that we require that associated types in an impl are well-formed.
#![feature(rustc_attrs)]
pub
trait
Foo
<
'a
>
{
type
Bar
;
...
...
@@ -20,5 +20,5 @@ impl<'a, T> Foo<'a> for T {
type
Bar
=
&
'a
T
;
//~ ERROR E0309
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-impl-associated-type-trait.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Check that we require that associated types in an impl are well-formed.
#![feature(rustc_attrs)]
#![allow(dead_code)]
pub
trait
MyHash
{
}
...
...
@@ -28,5 +28,5 @@ impl<T> Foo for T {
//~^ ERROR the trait bound `T: MyHash` is not satisfied
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-in-fn-type-static.rs
浏览文件 @
bf544fa9
...
...
@@ -12,7 +12,7 @@
// types in fns.
#![allow(dead_code)]
#![feature(rustc_attrs)]
struct
MustBeCopy
<
T
:
Copy
>
{
t
:
T
...
...
@@ -28,5 +28,5 @@ struct Bar<T> {
x
:
fn
(
&
'static
T
)
//~ ERROR E0310
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-in-fn-where-clause.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Check that we enforce WF conditions also for where clauses in fn items.
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
MustBeCopy
<
T
:
Copy
>
{
...
...
@@ -21,5 +21,5 @@ fn bar<T,U>() //~ ERROR E0277
{
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-in-obj-type-static.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Check that we enforce WF conditions also for types in fns.
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
Object
<
T
>
{
}
...
...
@@ -24,5 +24,5 @@ struct Foo<T> {
x
:
Object
<&
'static
T
>
//~ ERROR E0310
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-inherent-impl-method-where-clause.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check where-clauses on inherent impl methods.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -23,5 +23,5 @@ fn foo(self) where T: ExtraCopy<U> //~ ERROR E0277
{}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-inherent-impl-where-clause.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check where-clauses on inherent impls.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -22,5 +22,5 @@ impl<T,U> Foo<T,U> where T: ExtraCopy<U> //~ ERROR E0277
{
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-static-type.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check the types of statics are well-formed.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
IsCopy
<
T
:
Copy
>
{
t
:
T
}
...
...
@@ -20,5 +20,5 @@ struct IsCopy<T:Copy> { t: T }
static
FOO
:
IsCopy
<
Option
<
NotCopy
>>
=
IsCopy
{
t
:
None
};
//~^ ERROR E0277
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-struct-bound.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check struct bounds for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -22,5 +22,5 @@ struct SomeStruct<T,U> //~ ERROR E0277
data
:
(
T
,
U
)
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-struct-field.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check struct fields for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
IsCopy
<
T
:
Copy
>
{
...
...
@@ -22,5 +22,5 @@ struct SomeStruct<A> {
data
:
IsCopy
<
A
>
//~ ERROR E0277
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-associated-type-bound.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check associated type bounds for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -20,5 +20,5 @@ trait SomeTrait<T> { //~ ERROR E0277
type
Type1
:
ExtraCopy
<
T
>
;
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-associated-type-region.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check associated type default values for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
SomeTrait
<
'a
>
{
...
...
@@ -20,5 +20,5 @@ trait SomeTrait<'a> {
//~^ ERROR E0309
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-associated-type-trait.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check associated type default values for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
struct
IsCopy
<
T
:
Copy
>
{
x
:
T
}
...
...
@@ -22,5 +22,5 @@ trait SomeTrait {
//~^ ERROR E0277
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-bound.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Test that we check supertrait bounds for WFedness.
#![feature(associated_type_defaults)]
#![feature(rustc_attrs)]
#![allow(dead_code)]
trait
ExtraCopy
<
T
:
Copy
>
{
}
...
...
@@ -21,5 +21,5 @@ trait SomeTrait<T,U> //~ ERROR E0277
{
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-default-fn-arg.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Check that we test WF conditions for fn arguments. Because the
// current code is so goofy, this is only a warning for now.
#![feature(rustc_attrs)]
#![allow(dead_code)]
#![allow(unused_variables)]
...
...
@@ -25,5 +25,5 @@ fn bar(&self, x: &Bar<Self>) {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-default-fn-where-clause.rs
浏览文件 @
bf544fa9
...
...
@@ -11,7 +11,7 @@
// Check that we test WF conditions for fn arguments. Because the
// current code is so goofy, this is only a warning for now.
#![feature(rustc_attrs)]
#![allow(dead_code)]
#![allow(unused_variables)]
...
...
@@ -25,5 +25,5 @@ fn bar<A>(&self) where A: Bar<Self> {
}
}
#[rustc_error]
fn
main
()
{
}
src/test/ui/wf/wf-trait-fn-where-clause.rs
浏览文件 @
bf544fa9
...
...
@@ -10,7 +10,7 @@
// Check that we test WF conditions for fn where clauses in a trait definition.
#![feature(rustc_attrs)]
#![allow(dead_code)]
#![allow(unused_variables)]
...
...
@@ -23,5 +23,5 @@ trait Foo {
// Here, Eq ought to be implemented.
}
#[rustc_error]
fn
main
()
{
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录