File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -121,7 +121,7 @@ impl<T: std::fmt::Display> Render for Raw<T> {
121
121
impl < T : std:: fmt:: Display > RenderAttributeValue for Raw < T > { }
122
122
123
123
#[ inline]
124
- pub fn raw ( value : impl std:: fmt:: Display ) -> impl Render + RenderAttributeValue {
124
+ pub fn raw ( value : impl std:: fmt:: Display ) -> impl RenderAttributeValue {
125
125
Raw ( value)
126
126
}
127
127
@@ -222,8 +222,10 @@ tuple_impl! { A B C D E F G H }
222
222
tuple_impl ! { A B C D E F G H I }
223
223
tuple_impl ! { A B C D E F G H I J }
224
224
225
+ pub type RenderFn < ' a > = dyn Fn ( & mut dyn std:: fmt:: Write ) -> std:: fmt:: Result + ' a ;
226
+
225
227
pub struct DynRender < ' a > {
226
- f : Box < dyn Fn ( & mut dyn std :: fmt :: Write ) -> std :: fmt :: Result + ' a > ,
228
+ f : Box < RenderFn < ' a > > ,
227
229
}
228
230
229
231
pub fn new < ' a , F > ( f : F ) -> DynRender < ' a >
Original file line number Diff line number Diff line change 358
358
t15,
359
359
{
360
360
A ( ) {
361
- @for | Ok ( x) | Err ( x) in vec! [ Ok ( 1 ) , Err ( 2 ) , Ok ( 3 ) ] {
361
+ @for | Ok ( x) | Err ( x) in [ Ok ( 1 ) , Err ( 2 ) , Ok ( 3 ) ] {
362
362
@x
363
363
}
364
364
}
You can’t perform that action at this time.
0 commit comments