Skip to content
This repository was archived by the owner on Sep 8, 2022. It is now read-only.
This repository was archived by the owner on Sep 8, 2022. It is now read-only.

Drop scala-xml dependency? #104

@ashawley

Description

@ashawley

In scala/scala#6436, scala-xml was dropped from the scala compiler build.

Turns out, when the compiler bootstrap script tries to build partest it fails to find a scala-xml version that satisfies the scalaBinaryVersion.

However, the dependency on scala-xml here is only "provided". It's not clear why it even needs to be "provided". Removing the dependency from build.sbt, it will still compile. Usually, "provided" suggests there are code paths that require it, but the user should provide it themselves. But I'm not seeing any code paths that require scala-xml. Perhaps, there is a use case in partest that requires scala-xml that's not obvious?

If not, could the provided-dependency on scala-xml just be ripped out?

Maybe, when scala-xml was part of scaladoc (as far back as yesterday), it was important to probably sprinkle the dependency everywhere, including here.

An old comment in build.sbt hints as much:

scalap depends on scala-compiler, which depends (for the scaladoc part) on scala-xml
and scala-parser-combinators more precisely, scala-compiler_2.11.0-M5 depends on
                     scala-xml_2.11.0-M4 and
      scala-parser-combinators_2.11.0-M4,
so that we get a binary version incompatibility warning
To fix this, we'll modularize scaladoc to remove the dependency from scala-compiler-core,
and use dbuild to replicate the staged build we had originally,
so that we don't mix cross-versioned artifacts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions