Skip to content

Migrate build.sc to Scala 3Β #3152

@lihaoyi

Description

@lihaoyi

The goal of this ticket is to move Mill from Scala 2.13 to Scala 3.

Most of Mill's code should be easily portable with minimal changes (e.g. syntax tweaks), but there are three major areas which may require more work:

  1. The import $ivy parser is currently using FastParse's ScalaParse, and would need to be moved over to use a Scala 3 compatible parser similar to what Ammonite does

  2. The compiler plugin for auto-override would need to be migrated over

  3. The various macros like Caller, Task, and Applicative would need to be ported over

  4. The CodeSig analyzer used for fine grained invalidation on build.sc code changes may need to be ported over if Scala 3 generates very different bytecode (not sure, seems unlikely?)

  5. Any older dependencies that only support Scala 2 may need to be updated or replaced

The acceptance criteria is A PR that passes all existing tests on Scala 3, and either modify some existing tests to exercise Scala 3 language features, or add new tests to do so. We may not merge the PR immediately, but having the PR open with all tests passing should be enough for us to integrate the Scala 3 support and at our leisure. This would be a breaking change and would need a version bump, with associated downstream inconvenience

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions