You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In rust-analyzer-master/crates/hir-expand/src/name.rss, I think the code should check text.len() <= 22 as comments mentioned before use text to avoid possible incompleteness.
/// Shortcut to create inline plain text name. Panics if `text.len() > 22`constfnnew_static(text:&'staticstr) -> Name{Name::new_text(SmolStr::new_static(text))}
The text was updated successfully, but these errors were encountered:
No, it's shouldn't check, because it's fine to panic for strings known at compile-time (SmolStr::new_static used to panic on these). But the comment is outdated anyway, since we no longer panic in that case.
In rust-analyzer-master/crates/hir-expand/src/name.rss, I think the code should check text.len() <= 22 as comments mentioned before use text to avoid possible incompleteness.
The text was updated successfully, but these errors were encountered: