forked from scala/scala3
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bump compiler-interface and capture the diagnosticCode
NOTE: It's important that in `Problem` we don't construct the actual `DiagnosticCode` _unless_ the method is called to get it. By doing this we keep compatibility ensuring that older build tools can still use the bridge just fine. That's what the `sbt-test/sbt-bridge` tests ensuring that this is still usable by an older tool using the old `Problem`. This then unlocks forwarding the diagnostic code on for tools to use. refs: scala#14904
- Loading branch information
1 parent
3d64d24
commit b3807a4
Showing
5 changed files
with
44 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package dotty.tools.xsbt; | ||
|
||
import java.util.Optional; | ||
|
||
final public class DiagnosticCode implements xsbti.DiagnosticCode { | ||
private final String _code; | ||
private final Optional<String> _explanation; | ||
|
||
public DiagnosticCode(String code, Optional<String> explanation) { | ||
super(); | ||
this._code = code; | ||
this._explanation = explanation; | ||
} | ||
|
||
public String code() { | ||
return _code; | ||
} | ||
|
||
public Optional<String> explanation() { | ||
return _explanation; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters