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

Add err outport for fmt.Print and fmt.Println #859

Open
emil14 opened this issue Feb 1, 2025 · 4 comments · May be fixed by #860
Open

Add err outport for fmt.Print and fmt.Println #859

emil14 opened this issue Feb 1, 2025 · 4 comments · May be fixed by #860
Assignees
Labels

Comments

@emil14
Copy link
Collaborator

emil14 commented Feb 1, 2025

  • update runtime-function
  • update stdlib println signature
  • update all examples and e2e tests that uses fmt.Println (use search across *.neva)
    • ignore smoke tests for parser, they don't care about semantics
  • make sure all tests are green, update tests if needed
@MDH0
Copy link

MDH0 commented Feb 1, 2025

@emil14 Currently working on it. Just noticed, that the test e2e/interface_with_imports is importing from the x repository, which includes a wrapper for Println, which needs to be updated to also take into account, that Println will return an error additionally to the result.

@emil14
Copy link
Collaborator Author

emil14 commented Feb 1, 2025

@MDH0 good catch

x was updated to 0.0.17, use it instead

@MDH0
Copy link

MDH0 commented Feb 1, 2025

Example image_png.
Currently it prints all errors to println. I could change it, so the error of the println is handled too, but doesn't it make more sense, to send the errors to panic?

@emil14
Copy link
Collaborator Author

emil14 commented Feb 1, 2025

@MDH0

Propogate errors downstream

Use ? operator when possible, panic in main

@MDH0 MDH0 linked a pull request Feb 1, 2025 that will close this issue
@emil14 emil14 changed the title Add err outport for fmt.Println Add err outport for fmt.Print and fmt.Println Feb 5, 2025
@emil14 emil14 added Critical and removed Major labels Feb 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: No status
Development

Successfully merging a pull request may close this issue.

2 participants