Skip to content

Commit f689237

Browse files
committed
Refactor
1 parent 6c9da55 commit f689237

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

libs/extractor/src/tailwind.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -355,9 +355,12 @@ impl TailwindClass {
355355
StyleSelector::At { kind, query, .. } => {
356356
has_at_rule = Some((kind, query));
357357
}
358-
// Note: TailwindVariant::to_selector() never produces Global, but this arm
359-
// is required for exhaustive matching. Kept as no-op for forward compatibility.
360-
StyleSelector::Global(_, _) => {}
358+
// SAFETY: TailwindVariant::to_selector() never produces Global.
359+
// This arm exists only for exhaustive matching. If reached, it indicates
360+
// a bug where a new TailwindVariant was added that produces Global.
361+
StyleSelector::Global(_, _) => {
362+
unreachable!("TailwindVariant should not produce Global selector")
363+
}
361364
}
362365
}
363366

0 commit comments

Comments
 (0)