Skip to content

Provide helpful stack trace in WritableResourceStream#96

Merged
trowski merged 2 commits intov2from
helpful-stacktrace-wrs
Mar 26, 2022
Merged

Provide helpful stack trace in WritableResourceStream#96
trowski merged 2 commits intov2from
helpful-stacktrace-wrs

Conversation

@kelunik
Copy link
Copy Markdown
Member

@kelunik kelunik commented Mar 14, 2022

No description provided.

@kelunik kelunik requested a review from trowski March 14, 2022 19:46
@kelunik kelunik force-pushed the helpful-stacktrace-wrs branch from 2593b71 to 1a6251b Compare March 14, 2022 19:47
@trowski
Copy link
Copy Markdown
Member

trowski commented Mar 25, 2022

Personally I would pass a closure or null to the suspension to resume, e.g. static fn () => throw new ClosedException("The stream was closed by the peer");. It adds another function call to the stack trace, but the code seems less strange and Psalm should be more accepting of it.

@kelunik kelunik force-pushed the helpful-stacktrace-wrs branch from 1a6251b to 51e8d2d Compare March 26, 2022 15:06
@trowski trowski merged commit 5dfd811 into v2 Mar 26, 2022
@kelunik kelunik deleted the helpful-stacktrace-wrs branch March 26, 2022 20:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants