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

Replace use of libdparse with dmd as a library in dfix #104

Open
RazvanN7 opened this issue Jul 10, 2023 · 0 comments
Open

Replace use of libdparse with dmd as a library in dfix #104

RazvanN7 opened this issue Jul 10, 2023 · 0 comments
Labels

Comments

@RazvanN7
Copy link
Contributor

Description

dfix is a tool to automatically upgrade code to new features. It uses libdparse - a third party implementation of a D lexer+parser - to obtain an AST which it then uses to generate the fixed code. Since libdparse has a different implementation from the reference D frontend, every time a parser change occurs, libdparse and (likely) its dependencies need to be updated.

The project aims at using the dmd-as-a-library package, which shares its implementation with the reference D compiler, to substitute the use of libdparse in dfix.

What are rough milestones of this project?

  1. Create a fork of dfix and set up a testing pipeline.
  2. Use dmd-as-a-library to obtain the AST.
  3. Rewrite the existing visitors to use the generated AST
  4. Write more potential fixes for existing deprecations.
  5. Integrate the fork in the original dfix repo.

How does this project help the D community?

Ideally, every deprecation or language change should be accompanied by a tool that automatically updates the wrong code to the correct code. Having dfix use the compiler as a library will make it easier for compiler devs to implement the fixes and thus improving the user experience when deprecations/language changes occur.

Recommended skills

Knowledgeable with AST, parsers, compilers.
Prior experience with D/C/C++/Java
OOP
Visitor pattern
Git
Tenacity, patience
Motivated and able to work independently.

Point of Contact

@RazvanN7

@RazvanN7 RazvanN7 added the saoc label Jul 10, 2023
@mdparker mdparker added gsoc and removed gsoc labels Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants