MCPcopy Index your code
hub / github.com/endbasic/endbasic / start

Method start

std/src/console/linebuffer.rs:61–63  ·  view source on GitHub ↗

Returns the characters from the start of the string to `end_pos`, excluding `end_pos`. Calling this with `end_pos` set to 0 will return an empty string, and a 1-char string if `end_pos` is 1 (if the string contains at least 1 character).

(&self, end_pos: usize)

Source from the content-addressed store, hash-verified

59 /// Calling this with `end_pos` set to 0 will return an empty string, and a 1-char string if
60 /// `end_pos` is 1 (if the string contains at least 1 character).
61 pub fn start(&self, end_pos: usize) -> String {
62 self.chars().take(end_pos).collect()
63 }
64
65 /// Extracts a range of characters from this buffer.
66 pub fn range(&self, start_pos: usize, end_pos: usize) -> String {

Callers 2

newMethod · 0.80
play_toneMethod · 0.80

Calls 1

charsMethod · 0.80

Tested by

no test coverage detected