diff options
| author | Tim Chevalier <chevalier@alum.wellesley.edu> | 2011-05-20 14:15:39 -0700 |
|---|---|---|
| committer | Graydon Hoare <graydon@mozilla.com> | 2011-05-20 16:57:37 -0700 |
| commit | a08a376d6e4c0b8805d94dadd43a320b0f00b375 (patch) | |
| tree | 2275100c990c9d774e61f784bbd5e8d98f8f5cbb /src/rt/rust_kernel.cpp | |
| parent | 3dd2877975efd0dd9ed8debe202c8e9d48810f48 (diff) | |
| download | rust-a08a376d6e4c0b8805d94dadd43a320b0f00b375.tar.gz rust-a08a376d6e4c0b8805d94dadd43a320b0f00b375.zip | |
Make controlflow part of a function type
Change ty_fn to have a controlflow field. A 'controlflow' is
essentially a bit of data that says whether or not this function
never returns to the caller (if it never returns, that means it calls
"fail" or another "never-returns" function on every control path).
Also add syntax for annotating functions that never return:
fn foo() -> ! {
fail;
}
for example. Functions marked with ! implicitly have a result type of
ty_bot, which is a new type that this commit also adds.
Diffstat (limited to 'src/rt/rust_kernel.cpp')
0 files changed, 0 insertions, 0 deletions
