فهرست منبع

fix merging static attributes

Evan Almloff 1 سال پیش
والد
کامیت
561830d814
1فایلهای تغییر یافته به همراه3 افزوده شده و 1 حذف شده
  1. 3 1
      packages/rsx/src/ifmt.rs

+ 3 - 1
packages/rsx/src/ifmt.rs

@@ -47,7 +47,9 @@ impl IfmtInput {
     }
 
     pub fn is_static(&self) -> bool {
-        matches!(self.segments.as_slice(), &[Segment::Literal(_)] | &[])
+        self.segments
+            .iter()
+            .all(|seg| matches!(seg, Segment::Literal(_)))
     }
 }