Skip to main content

replace_string_pattern

Function replace_string_pattern 

Source
pub(crate) fn replace_string_pattern(
    it: &mut Interp,
    s: &str,
    search: &str,
    repl: Value,
    all: bool,
) -> Result<String, Value>
Expand description

文字列の検索値での replace(先頭の一致だけ)・replaceAll(全部)。ToString(replaceValue) は検索より前(仕様の順序)。