Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parser improvements #173

Merged
merged 8 commits into from
Aug 16, 2024
Merged

Parser improvements #173

merged 8 commits into from
Aug 16, 2024

Conversation

kaleidawave
Copy link
Owner

@kaleidawave kaleidawave commented Jul 10, 2024

haven't added lexing state yet, just tests

Also todo

  • Remove
    if readonly_position.is_some() {
    // TODO positioning:
    let position = start.union(type_annotation.get_position());
    type_annotation =
    TypeAnnotation::Readonly(Box::new(type_annotation), position);
    }
  • rename MappedReadonlyKind::False => Default (+ make default)
  • Template literal interpolations should be described with interpolations: Vec<(String, Expression)>, end: String
  • Fix precedence of `keyof T & string
  • Fix get?() key not allowed in interface key
  • Code blocks to script: split into modules rather than arrow functions (keep declare) AND also repeat until
    • Also should log the number of expected errors
  • Skip printing more than two Statement::Empty in a row
  • Error on hashbang #176
  • ] not eaten in the string and number cases here
  • get and set not allowed as interface member keys
  • Allow types with generics as keys for interface keys
  • Add --check to experimental format
  • Top level html mode

@kaleidawave kaleidawave added bug Something isn't working parser Related to Ezno's syntax parser, AST definitions and output labels Aug 9, 2024
- Change template literal definition (better matches JS semantics)
- Fix for `keyof T & string`
- Namespace name fixes
- Remove bad `readonly` thing
- Fix template expression and type annotation issue
- Combine import and export part
- Move number and options out of parser/lib.rs
- Improves comment handling
- ImportExport part name sorting under pretty
- Get `lib.es5.d.ts` parsing again through fixes to type annotations
- Remove commments from tests for now
- Add `--check` to experimental format command
@kaleidawave kaleidawave changed the title Add more state to lexing Parser improvements Aug 16, 2024
- Add type definition for ImportExportPart to fix generics issue
- Add `extends` to expression prefixes
@kaleidawave kaleidawave marked this pull request as ready for review August 16, 2024 16:39
@kaleidawave kaleidawave merged commit a7b6b94 into main Aug 16, 2024
8 checks passed
@kaleidawave kaleidawave deleted the lexing-state branch August 16, 2024 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working parser Related to Ezno's syntax parser, AST definitions and output
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant