edwood: github.com/rjkroege/edwood/internal/runes Index | Files

package runes

import "github.com/rjkroege/edwood/internal/runes"

Package runes implements functions for the manipulation of rune slices.

Index

Package Files

runes.go

func ContainsRune Uses

func ContainsRune(s []rune, r rune) bool

ContainsRune reports whether the rune is contained in the runes slice s.

func Equal Uses

func Equal(a, b []rune) bool

Equal returns a boolean reporting whether a and b are the same length and contain the same runes.

func HasPrefix Uses

func HasPrefix(s, prefix []rune) bool

HasPrefix tests whether the rune slice s begins with prefix.

func Index Uses

func Index(s, sep []rune) int

Index returns the index of the first instance of sep in s, or -1 if sep is not present in s.

func IndexRune Uses

func IndexRune(s []rune, r rune) int

IndexRune returns the index of the first occurrence in s of the given rune r. It returns -1 if rune is not present in s.

func TrimLeft Uses

func TrimLeft(s []rune, cutset string) []rune

TrimLeft returns a subslice of s by slicing off all leading UTF-8-encoded code points contained in cutset.

Package runes is imported by 2 packages. Updated 2019-03-02. Refresh now. Tools for package owners.