why is this err caused?...

This is an auto-generated question from the MPS Slack community: why is this err caused?
0
5 comments
can't you print an exception in mps?
0
Your surrounding method expects a return statement or 'returnable' expression, I guess.
0
Yes this is the case. If you define a method with a return type, it needs a return statement. If you don't specify a return statement it implicitly chooses the last statement as return. In your case it is a println call, which returns void, which is not a legal return statement.
0
This is auto-generated question from the MPS Community Slack Workspace. If you want to comment on the question, do it from the Slack workspace
0

Post is closed for comments.