JSAbrahams / mamba

🐍 The Mamba programming language, because we care about safety
MIT License
85 stars 3 forks source link

Check if a function may raise a certain error #149

Closed JSAbrahams closed 2 years ago

JSAbrahams commented 5 years ago

Current Issue

Use the context built using #148

High-level description of the feature

Do a simple check to check whether a function does indeed raise, and only raise, the errors mentioned in its signature.

Description of potential implementation

Check that the errors, and only the errors, are raised by statements: <statement> raises [<Error>]

JSAbrahams commented 4 years ago

Due to the type checker noting what errors may be raised we don't need to explicitly check that the user annotated these errors.

Currently, it appears that this behaviour has actually been fixed, but we should add some tests to confirm this before closing this issue.

JSAbrahams commented 2 years ago

Closing for now since it is assumed that this has been fixed.