unblock hot reloading on stable now that proc-macro spans are stabilized

This commit is contained in:
Greg Johnston
2025-07-16 17:20:15 -04:00
parent d2409a22a7
commit b276e703a8

View File

@@ -358,16 +358,14 @@ fn view_macro_impl(tokens: TokenStream, template: bool) -> TokenStream {
}
fn normalized_call_site(site: proc_macro::Span) -> Option<String> {
cfg_if::cfg_if! {
if #[cfg(all(debug_assertions, feature = "nightly", rustc_nightly))] {
Some(leptos_hot_reload::span_to_stable_id(
site.file(),
site.start().line()
))
} else {
_ = site;
None
}
if cfg!(debug_assertions) {
Some(leptos_hot_reload::span_to_stable_id(
site.file(),
site.start().line(),
))
} else {
_ = site;
None
}
}