diff options
| author | Oliver Middleton <olliemail27@gmail.com> | 2020-01-20 18:14:51 +0000 |
|---|---|---|
| committer | Oliver Middleton <olliemail27@gmail.com> | 2020-01-20 18:14:51 +0000 |
| commit | 3e0bfe1238e26ce57c2201172f0a4bb7cfbbba0a (patch) | |
| tree | 61b2f411fe890e968f420581a2686b37b82f0ed5 /src/test | |
| parent | 900811e43047fc5593f39b0363373530b02c87e0 (diff) | |
rustdoc: Correct order of `async` and `unsafe` in `async unsafe fn`s
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/rustdoc/async-fn.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/test/rustdoc/async-fn.rs b/src/test/rustdoc/async-fn.rs index 5f9708a3972..5a03e821e8a 100644 --- a/src/test/rustdoc/async-fn.rs +++ b/src/test/rustdoc/async-fn.rs @@ -15,6 +15,11 @@ pub async fn baz<T>(a: T) -> T { a } +// @has async_fn/fn.qux.html '//pre[@class="rust fn"]' 'pub async unsafe fn qux() -> char' +pub async unsafe fn qux() -> char { + '⚠' +} + trait Bar {} impl Bar for () {} @@ -26,8 +31,10 @@ pub async fn quux() -> impl Bar { // @has async_fn/struct.Foo.html // @matches - '//code' 'pub async fn f\(\)$' +// @matches - '//code' 'pub async unsafe fn g\(\)$' pub struct Foo; impl Foo { pub async fn f() {} + pub async unsafe fn g() {} } |
