-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Fix #2184: Hyper Bootstrap! Integrate the backend as a git submodule #2260
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great to get this in!
docs/docs/contributing/backend.md
Outdated
|
||
``` shell | ||
git submodule update | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could make sbt do this so that we never miss it - also helps beginners.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not a fan of doing more weird stuff with sbt, let's not do that for now.
scalaCompiler % Test, | ||
"com.storm-enroute" %% "scalameter" % "0.6" % Test | ||
), | ||
libraryDependencies += "com.storm-enroute" %% "scalameter" % "0.6" % Test, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is this needed for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was already here before, no idea.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we can we should kill it with 🔥
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, but removing/updating the bench
project is a separate issue.
@@ -1187,7 +1187,7 @@ object TreeTransforms { | |||
case NonFatal(ex) => | |||
if (tree ne crashingTree) { | |||
crashingTree = tree | |||
println(i"exception while transforming $tree of class ${tree.getClass} # ${tree.uniqueId}") | |||
// println(i"exception while transforming $tree of class ${tree.getClass} # ${tree.uniqueId}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, missed that.
b93daa0
to
5f1852b
Compare
…dule The backend lives in the scalac fork at https://github.com/lampepfl/scala/tree/sharing-backend. Before this commit, the scala-compiler built from this fork was a dependency of Scala just to get this backend. This made it much more cumbersome to test changes to the backend and also forced us to depend on Scala 2.11.5 since that is the version of scalac that the forked backend is based on. This commit changes this by adding a git submodule in the `scala-backend` directory that points to the scalac fork. We do not compile the whole submodule, instead we add the subset of files we need to the dotty-compiler project in the sbt build. See backend.md for more information (online at http://dotty.epfl.ch/docs/contributing/backend.html) once this commit is merged. The most important thing to note is that whenever you clone dotty you should do `git clone --recursive` to also clone the submodule. If you already have a cloned dotty you'll need to do: git submodule update --init You will need to repeat this command anytime you update dotty and the backend has been updated, otherwise the content of `scala-backend` will be stale.
5f1852b
to
4767786
Compare
@odersky @nicolasstucki @liufengyun @OlivierBlanvillain The backend is in! Don''t forget to do: git submodule update --init After pulling these changes. See https://github.com/lampepfl/dotty/blob/master/docs/docs/contributing/backend.md (soon rendered at http://dotty.epfl.ch/docs/contributing/backend.html) for more information. |
Now that scala#2260 has been merged, nothing is holding us back from upgrading.
The backend lives in the scalac fork at
https://github.com/lampepfl/scala/tree/sharing-backend. Before this
commit, the scala-compiler built from this fork was a dependency of
Scala just to get this backend. This made it much more cumbersome to
test changes to the backend and also forced us to depend on Scala 2.11.5
since that is the version of scalac that the forked backend is based on.
This commit changes this by adding a git submodule in the
scala-backend
directory that points to the scalac fork. We do notcompile the whole submodule, instead we add the subset of files we need
to the dotty-compiler project in the sbt build. See backend.md for more
information (online at
http://dotty.epfl.ch/docs/contributing/backend.html) once this commit is
merged.
The most important thing to note is that whenever you clone dotty you
should do
git clone --recursive
to also clone the submodule. If youalready have a cloned dotty you'll need to do:
You will need to repeat this command anytime you update dotty and the backend has been updated, otherwise the content of
scala-backend
will be stale.