@@ -30,41 +30,39 @@ fn main() {
3030}
3131"# ;
3232 let message = & [
33- Group :: new ( )
34- . element (
35- Level :: ERROR
36- . title ( "`break` with value from a `while` loop" )
37- . id ( "E0571" ) ,
38- )
39- . element (
40- Snippet :: source ( source)
41- . line_start ( 1 )
42- . path ( "$DIR/issue-114529-illegal-break-with-value.rs" )
43- . fold ( true )
44- . annotation (
45- AnnotationKind :: Primary
46- . span ( 483 ..581 )
47- . label ( "can only break with a value inside `loop` or breakable block" ) ,
48- )
49- . annotation (
50- AnnotationKind :: Context
51- . span ( 462 ..472 )
52- . label ( "you can't `break` with a value in a `while` loop" ) ,
53- ) ,
54- ) ,
55- Group :: new ( )
56- . element (
57- Level :: HELP
58- . text ( Some ( "suggestion" ) )
59- . title ( "use `break` on its own without a value inside this `while` loop" ) ,
60- )
61- . element (
62- Snippet :: source ( source)
63- . line_start ( 1 )
64- . path ( "$DIR/issue-114529-illegal-break-with-value.rs" )
65- . fold ( true )
66- . patch ( Patch :: new ( 483 ..581 , "break" ) ) ,
67- ) ,
33+ Group :: with_title (
34+ Level :: ERROR
35+ . title ( "`break` with value from a `while` loop" )
36+ . id ( "E0571" ) ,
37+ )
38+ . element (
39+ Snippet :: source ( source)
40+ . line_start ( 1 )
41+ . path ( "$DIR/issue-114529-illegal-break-with-value.rs" )
42+ . fold ( true )
43+ . annotation (
44+ AnnotationKind :: Primary
45+ . span ( 483 ..581 )
46+ . label ( "can only break with a value inside `loop` or breakable block" ) ,
47+ )
48+ . annotation (
49+ AnnotationKind :: Context
50+ . span ( 462 ..472 )
51+ . label ( "you can't `break` with a value in a `while` loop" ) ,
52+ ) ,
53+ ) ,
54+ Group :: with_title (
55+ Level :: HELP
56+ . text ( Some ( "suggestion" ) )
57+ . title ( "use `break` on its own without a value inside this `while` loop" ) ,
58+ )
59+ . element (
60+ Snippet :: source ( source)
61+ . line_start ( 1 )
62+ . path ( "$DIR/issue-114529-illegal-break-with-value.rs" )
63+ . fold ( true )
64+ . patch ( Patch :: new ( 483 ..581 , "break" ) ) ,
65+ ) ,
6866 ] ;
6967
7068 let renderer = Renderer :: styled ( ) . theme ( OutputTheme :: Unicode ) ;
0 commit comments