mirror of
https://github.com/astral-sh/ruff
synced 2026-01-23 14:30:53 -05:00
Move token and error structs into related modules (#11957)
## Summary This PR does some housekeeping into moving certain structs into related modules. Specifically, 1. Move `LexicalError` from `lexer.rs` to `error.rs` which also contains the `ParseError` 2. Move `Token`, `TokenFlags` and `TokenValue` from `lexer.rs` to `token.rs`
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
use ruff_python_ast::{self as ast, Expr, ExprContext, Number, Operator, Pattern, Singleton};
|
||||
use ruff_text_size::{Ranged, TextSize};
|
||||
|
||||
use crate::lexer::TokenValue;
|
||||
use crate::parser::progress::ParserProgress;
|
||||
use crate::parser::{recovery, Parser, RecoveryContextKind, SequenceMatchPatternParentheses};
|
||||
use crate::token::{TokenKind, TokenValue};
|
||||
use crate::token_set::TokenSet;
|
||||
use crate::{ParseErrorType, TokenKind};
|
||||
use crate::ParseErrorType;
|
||||
|
||||
use super::expression::ExpressionContext;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user