Code reference detail
lexer.rs
reqlan rq/core_analysis/crates/reqlan-parse/tests/lexer.rs
| Idea | Status | Tags | Summary | Katz |
|---|---|---|---|---|
| comment_span_align | done | On every frozen [golden_corpus] `.rq` file, `//` and `/* … */` comment character ranges must be identical across: - the Langium lexer ( hidden `SL_COMMENT` / `ML_COMMENT` ) - `findCommentSpansInText` C-style spans ( host `#` / triple-quote spans are not `.rq` comments ) - TextMate `comment.line.reqlan` and `comment.block.reqlan` scopes Same-line fences, glob `/**/`, URL `://`, and fenced ` ` ` bodies must not open comments. Mid-line triple backticks are prose. They must not open a fence or hide later ideas. Example: `@reqlan/*` in inline code must not open a block comment. Related: [parser_align], ["../language/syntax.rq".code_snippets], ["../language/syntax.rq".comments], ["../language/syntax-edge-cases.rq".fencing_comments], ["../language/syntax.rq".inline_code]. | 0.141 | |
| lexer_rust | done | Hand-written Rust lexer that ports ["../../packages/language/src/reqlan-token-builder.ts"]: structural vs prose `{` / `}`, fence opacity, quote-aware comments, `@` only at line start, glob `/**/` not a block comment. Linear in document size with sparse brace-depth lookup ( [syntax_edges.context_sensitive_lexer_scaling] ). Owned by `reqlan-parse`; consumed by [parser_rust] and by [lsp_rust.language_server_rust]. The Langium token builder remains only for the transitional `node` engine fallback and dual-parser tests. | 0.105 | |
| parser_rust | done | Recursive-descent parser matching ["../../packages/language/src/reqlan.langium"] productions into a Rust AST the extractor can walk. Recovery: nameless `{...}` and local import mistakes still yield a usable document ( [parser_lexer.recovery_vs_budget] ). Wall-clock [parser_lexer.parse_budget_timeout] via native timeout / cancel — no Node worker process required on the index path. Open `.rq` buffers and CLI `parse` use `reqlan-parse` ( [lsp_rust.language_server_rust] ). Langium remains a dual-parser test oracle and the transitional `node` engine fallback — not the default editor LSP. Alignment contract: [parser_align]. | 0.217 |
Reference labels
comment_span_align, lexer_rust, parser_rust