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

Improve compiler error reporting #3780

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lock9
Copy link

@lock9 lock9 commented Jan 6, 2025

Problem

The compiler may fail without informing where the error is coming from. I found at least two places that can be fixed.

Solution

Include the file line and position of the error message

Output example:

error while trying to compile smart contract file: .../abstract.go:101:9: '&' can be used only with struct literals

Note: I didn't find test cases covering this error so I didn't add any new test.

@roman-khimov roman-khimov added compiler Go smart contract compiler I3 Minimal impact U4 Nothing urgent enhancement Improving existing functionality S4 Routine labels Jan 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler Go smart contract compiler enhancement Improving existing functionality I3 Minimal impact S4 Routine U4 Nothing urgent
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants