Skip to content

support debugging for dotc/dotr #2705

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

Merged
merged 1 commit into from
Jun 8, 2017
Merged

Conversation

liufengyun
Copy link
Contributor

Support debugging option for dotc/dotr:

$ dotc -debug hello.scala
Listening for transport dt_socket at address: 5005

$ dotr -d Test
Listening for transport dt_socket at address: 5005

With this PR, we may consider remove the bin/dotc scripts:

  • New scripts don't depend on source code
  • New scripts support all features of old scripts
  • New scripts is CI tested on Linux/Mac/Windows
  • sbt dist/pack or sbt dist-bootstrapped/pack can be used for compiler development

The CI on Linux/Mac/Windows for this PR is here: liufengyun/packtest#3

Note: -d is already used in the compiler for output directory, thus dotc has to use -debug.

@liufengyun liufengyun requested a review from felixmulder June 7, 2017 16:44
@DarkDimius
Copy link
Contributor

New scripts don't depend on source code

Does this mean that they may run a "dirty" compiler that doesn't match the compiled thing?
If it's the case, I'll still keep the old scripts. I use them during local development

@liufengyun
Copy link
Contributor Author

As I said, you can run sbt dist/pack or sbt dist-bootstrapped/pack to have two different versions of dotc/dotr at the same time for development.

  • sbt dist/pack: generate bin under dist/target/pack/bin
  • sbt dist-bootstrapped/pack: generate bin under dist-bootstrapped/target/pack/bin

My experience tells that it's easier and more flexible to work with the news scripts than the old ones for compiler development.

https://github.com/xerial/sbt-pack#features

Anyway, just a proposal to try the new ones. We don't remove old ones in this PR.

@DarkDimius DarkDimius merged commit 1f7af24 into scala:master Jun 8, 2017
@allanrenucci allanrenucci deleted the debugging branch December 14, 2017 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants