MCPcopy Create free account
hub / github.com/dop251/goja / Substring

Method Substring

string_imported.go:182–188  ·  view source on GitHub ↗
(start, end int)

Source from the content-addressed store, hash-verified

180}
181
182func (i *importedString) Substring(start, end int) String {
183 i.ensureScanned()
184 if i.u != nil {
185 return i.u.Substring(start, end)
186 }
187 return asciiString(i.s).Substring(start, end)
188}
189
190func (i *importedString) CompareTo(v String) int {
191 return strings.Compare(i.s, v.String())

Callers

nothing calls this directly

Calls 3

ensureScannedMethod · 0.95
asciiStringTypeAlias · 0.85
SubstringMethod · 0.65

Tested by

no test coverage detected