-
Notifications
You must be signed in to change notification settings - Fork 111
Open
Description
Hello! I am hoping for a noreturn branch flag feature that will indicate to steep that if a branch is taken, control flow does not return to the caller. For example:
# @rbs noreturn
def raise_error(node)
# ...
end
def compile(node)
case node
when Foo
compile_foo(node)
when Bar
compile_bar(node)
else
raise_error(node)
end
endCurrently this will union the types of compile_foo, compile_bar, and raise_error. I am hoping to have it ignore the return type of raise_error instead. (Note I do see that some methods use a return type of bot for this purpose, but I figured I'd check since noreturn is in other systems.)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels