fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
1.0 KiB27 linesraw
1// run-rustfix
2#![allow(unused)]
3fn foo() { }
4
5/// Misplaced comment...
6//~^ ERROR expected outer doc comment
7fn bar() { } //~ NOTE the inner doc comment doesn't annotate this function
8
9#[test] //~ ERROR an inner attribute is not permitted in this context
10fn baz() { } //~ NOTE the inner attribute doesn't annotate this function
11//~^^ NOTE inner attributes, like `#![no_std]`, annotate the item enclosing them, and are usually
12
13/** Misplaced comment... */
14//~^ ERROR expected outer doc comment
15fn bat() { } //~ NOTE the inner doc comment doesn't annotate this function
16
17fn main() { }
18
19// Misplaced comment...
20//~^ ERROR expected outer doc comment
21//~| NOTE inner doc comments like this (starting with `//!` or `/*!`) can only appear before items
22//~| NOTE other attributes here
23/* Misplaced comment... */
24//~^ ERROR expected outer doc comment
25//~| NOTE this doc comment doesn't document anything
26//~| ERROR expected item after doc comment
27//~| NOTE inner doc comments like this (starting with `//!` or `/*!`) can only appear before items