Skip to main content

strip_literal_suffix

Function strip_literal_suffix 

Source
fn strip_literal_suffix(hir: &Hir, suffix: &[u8]) -> Option<Hir>
Expand description

Strip suffix from the end of hir and return the HIR that remains.

This is conservative. It returns None when the structure of the HIR does not make the suffix straightforward to remove, even when suffix might be required by the pattern.