std.string

A UTF-8 encoded string

Values

let eq : std.cmp.Eq String

Eq a defines equality (==) on a

let ord : std.cmp.Ord String

Ord a defines an ordering on a

let show : std.show.Show String

Show a represents a conversion function from a to a readable string.

let semigroup : std.semigroup.Semigroup String

Semigroup a represents an associative operation on a. This means the following laws must hold:

  • forall x . append x (append y z) == append (append x y) z

let monoid : std.monoid.Monoid String

Monoid a represents an semigroup an which has an identity. This means the following additional laws must hold:

  • forall x . append x empty == x
  • forall x . append empty x == x

let ++ : String -> String -> String

Appends two strings.

Re-export of semigroup.append.

let len : String -> Int

let is_empty : String -> std.types.Bool

let is_char_boundary : String -> Int -> std.types.Bool

let as_bytes : String -> Array Byte

let split_at : String -> Int -> (String, String)

let contains : String -> String -> std.types.Bool

let starts_with : String -> String -> std.types.Bool

let ends_with : String -> String -> std.types.Bool

let find : String -> String -> std.types.Option Int

let rfind : String -> String -> std.types.Option Int

let trim : String -> String

let trim_left : String -> String

let trim_left_matches : String -> String -> String

let trim_right : String -> String

let trim_right_matches : String -> String -> String

let append : String -> String -> String

let slice : String -> Int -> Int -> String

let from_utf8 : Array Byte -> std.types.Result () String

let char_at : String -> Int -> Char