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

Migrate node_io to null safety #98

Merged
merged 9 commits into from
Apr 24, 2021
Merged

Migrate node_io to null safety #98

merged 9 commits into from
Apr 24, 2021

Conversation

jathak
Copy link
Collaborator

@jathak jathak commented Apr 20, 2021

This migrates the node_io code itself, but not the tests

node_io/lib/src/http_server.dart Outdated Show resolved Hide resolved
if (code is! int) {
throw ArgumentError('Integer value for exit code expected');
}
Never exit(int code) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason for this behavior change?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm trying to match the API for dart:io, which has exit take in a non-nullable integer and return the new Never type.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. Worth documenting in the changelog?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

@jathak jathak requested a review from Awjin April 21, 2021 17:25
@jathak jathak merged commit 96d4e7f into master Apr 24, 2021
@jathak jathak deleted the node-io-null-safety branch April 24, 2021 00:39
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