mirror of
https://github.com/RustPython/Parser.git
synced 2025-07-14 16:45:25 +00:00
Break down rustpython_parser::error module
because it doesn't share any common errors but specific error for each sub module
This commit is contained in:
parent
2a8aa6f308
commit
1511b6631b
7 changed files with 338 additions and 345 deletions
|
@ -1,7 +1,7 @@
|
|||
// Contains functions that perform validation and parsing of arguments and parameters.
|
||||
// Checks apply both to functions and to lambdas.
|
||||
use crate::ast;
|
||||
use crate::error::{LexicalError, LexicalErrorType};
|
||||
use crate::lexer::{LexicalError, LexicalErrorType};
|
||||
use rustc_hash::FxHashSet;
|
||||
|
||||
pub(crate) struct ArgumentList {
|
||||
|
@ -149,8 +149,8 @@ fn is_starred(exp: &ast::Expr) -> bool {
|
|||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use crate::error::{LexicalErrorType, ParseErrorType};
|
||||
use crate::parser::parse_program;
|
||||
use crate::lexer::LexicalErrorType;
|
||||
use crate::parser::{parse_program, ParseErrorType};
|
||||
|
||||
macro_rules! function_and_lambda {
|
||||
($($name:ident: $code:expr,)*) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue