Logo
Explore Help
Register Sign In
rust-lang/rust
1
0
Fork 0
You've already forked rust
Code Issues Pull Requests Actions 2 Packages Projects Releases Wiki Activity
Files
5bff8429a0655320c1aef0c16fb0fd2ec0184a9a
rust/src/test/rustdoc/impl-trait-alias.rs

15 lines
264 B
Rust
Raw Normal View History

Replace `type_alias_impl_trait` by `min_type_alias_impl_trait` with no actual changes in behaviour This makes `type_alias_impl_trait` not actually do anything anymore
2021-03-12 10:53:51 +00:00
#![feature(min_type_alias_impl_trait)]
Don't ICE on errors in function returning impl trait Instead, report the error. This emits the errors on-demand, without special-casing `impl Trait`, so it should catch all ICEs of this kind, including ones that haven't been found yet. Since the error is emitted during type-checking there is less info about the error; see comments in the code for details. - Add test case for -> impl Trait - Add test for impl trait with alias - Move EmitIgnoredResolutionErrors to rustdoc This makes `fn typeck_item_bodies` public, which is not desired behavior. That change should be removed once https://github.com/rust-lang/rust/pull/74070 is merged. - Don't visit nested closures twice
2020-07-03 18:41:23 -04:00
trait MyTrait {}
impl MyTrait for i32 {}
// @has impl_trait_alias/type.Foo.html 'Foo'
/// debug type
pub type Foo = impl MyTrait;
// @has impl_trait_alias/fn.foo.html 'foo'
/// debug function
pub fn foo() -> Foo {
1
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 233ms Template: 2ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API