MCPcopy Create free account
hub / github.com/RtlZeroMemory/Rezi / pushToken

Function pushToken

packages/core/src/widgets/codeEditorSyntax.ts:792–799  ·  view source on GitHub ↗
(
  tokens: CodeEditorSyntaxToken[],
  text: string,
  kind: CodeEditorSyntaxTokenKind,
)

Source from the content-addressed store, hash-verified

790}
791
792function pushToken(
793 tokens: CodeEditorSyntaxToken[],
794 text: string,
795 kind: CodeEditorSyntaxTokenKind,
796): void {
797 if (text.length === 0) return;
798 tokens.push(Object.freeze({ text, kind }));
799}
800
801function isWhitespace(ch: string): boolean {
802 return ch === " " || ch === "\t";

Callers 2

consumeWhitespaceFunction · 0.85
tokenizeLineWithGrammarFunction · 0.85

Calls 1

pushMethod · 0.45

Tested by

no test coverage detected