Skip to content
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

Handle compiler diagnostics in Rust. #2445

Merged
merged 4 commits into from Jun 4, 2019

Conversation

3 participants
@kitsonk
Copy link
Contributor

commented Jun 3, 2019

Resolves #1738

Replaces #2310

This PR is a more simplified approach to dealing with diagnostics. It only touches the cli in Rust.

It doesn't touch any of the JSError code, which means it doesn't align it to the TypeScript style of output. There is a trait though in cli/diagnostic.ts called DisplayFormatter which could be moved into core and simplify the logic of formatting the parts of a JSError to align the TypeScript style, which could be tackled as a seperate PR.

@kitsonk kitsonk referenced this pull request Jun 3, 2019

Closed

Handle compiler errors in Rust. #2310

4 of 4 tasks complete

@kitsonk kitsonk force-pushed the kitsonk:rust-diagnostics branch 2 times, most recently from bd5acec to b59d403 Jun 3, 2019

@ry
Copy link
Collaborator

left a comment

Very nice clean up!

Show resolved Hide resolved js/compiler.ts
Show resolved Hide resolved cli/diagnostics.rs Outdated
Show resolved Hide resolved cli/diagnostics.rs
Show resolved Hide resolved cli/diagnostics.rs
Show resolved Hide resolved cli/diagnostics.rs
@ry
Copy link
Collaborator

left a comment

Looks good - just a few nits and loose ends - otherwise I'm ready to land.

kitsonk added some commits Jun 3, 2019

@kitsonk kitsonk force-pushed the kitsonk:rust-diagnostics branch from b59d403 to 4fc69b1 Jun 4, 2019

@kitsonk

This comment has been minimized.

Copy link
Contributor Author

commented Jun 4, 2019

@ry I think all the feedback has been addressed.

@kitsonk

This comment has been minimized.

Copy link
Contributor Author

commented Jun 4, 2019

Actually I need to upgrade prettier it looks like. It needs to be running on 3.4 TypeScript, because I had to use some new 3.4 syntax to get some of the code to work, and prettier doesn't like it.

@kitsonk kitsonk force-pushed the kitsonk:rust-diagnostics branch from 19590b7 to 8977c3f Jun 4, 2019

@kitsonk

This comment has been minimized.

Copy link
Contributor Author

commented Jun 4, 2019

Ok, finally, should be all fixed now.

@ry

ry approved these changes Jun 4, 2019

Copy link
Collaborator

left a comment

LGTM!

@ry ry merged commit a71305b into denoland:master Jun 4, 2019

3 checks passed

Travis CI - Pull Request Build Passed
Details
continuous-integration/appveyor/pr AppVeyor build succeeded
Details
license/cla Contributor License Agreement is signed.
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.