span

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 23, 2026 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Span

type Span struct {
	Start int64
	End   int64
}

Span is a half-open byte offset range [Start, End).

func New

func New(start, end int64) Span

New constructs a normalized span. Negative offsets are clamped to zero and End is clamped to be at least Start.

func (Span) Contains

func (s Span) Contains(pos int64) bool

func (Span) IsZero

func (s Span) IsZero() bool

func (Span) Len

func (s Span) Len() int64

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL