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

Changing for the create_exception works #16

Open
hazelld opened this issue May 6, 2016 · 0 comments
Open

Changing for the create_exception works #16

hazelld opened this issue May 6, 2016 · 0 comments

Comments

@hazelld
Copy link
Collaborator

hazelld commented May 6, 2016

I think we need to find a more elegant way to set this up, I'm not sold on the way we do it now. One issue I see would be if someone was to do:

create_exception(excep1); create_exception(execp2);

Maybe we keep an internal lists of the used IDs and what they reference? That we it also adds the ability to throw that custom exception from inside a function in the try block, like:

func1() {
create_exception(e);
try {
func2();
} catch (e) { ... }
}

func2() {
throw(e);
}

I'll start working on something like this on another branch and see what I can come up with.

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

No branches or pull requests

1 participant