Documentation
¶
Index ¶
- func ContainsRune(str string, match rune) bool
- func HasUnescapedPrefix(str string, target rune) bool
- func IsEnclosedByAndUnescaped(str string, charA, charB rune) bool
- func IsEscaped(str string, char rune) bool
- func IsLogicalRuneEscaped(str string, logicalPos int) bool
- func IsRuneEscaped(str string, pos int) bool
- func ToArray(sliceStr string) []string
- func ToType(str string) any
- func UnescapeAll(str string) string
- func UnescapeRune(str string, target rune) string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ContainsRune ¶ added in v0.0.4
Does string contain match and is match not escaped
func HasUnescapedPrefix ¶ added in v0.0.4
Checks if str starts with target rune and it is not escaped by `\`
func IsEnclosedByAndUnescaped ¶ added in v0.0.4
Checks if str starts with charA and ends with charB (and are unescaped)
func IsLogicalRuneEscaped ¶ added in v0.0.7
Checks escape status using logical index (backslashes do not contribute to index)
func IsRuneEscaped ¶ added in v0.0.4
Checks if the rune at index `pos` in `str` is escaped by a single backslash
func ToArray ¶
Helper method for converting a (!unescaped) comma-separated string into string slices
func UnescapeAll ¶ added in v0.0.4
Removes single backslash escapes from the entire string (`\a` => `a`, `\\a` => `\a`)
func UnescapeRune ¶ added in v0.0.4
Removes the escaping backslash for a specific rune in the string
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.