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

Typestate for snapshot #397

Closed

Commits on May 20, 2011

  1. 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.
    catamorphism committed May 20, 2011
    Configuration menu
    Copy the full SHA
    e2a854f View commit details
    Browse the repository at this point in the history
  2. Add a "fail" after a while(true) loop in two places

    (in preparation for changing the "function may not return" warning
    to an error)
    catamorphism committed May 20, 2011
    Configuration menu
    Copy the full SHA
    5d99fdf View commit details
    Browse the repository at this point in the history
  3. rm unused import

    catamorphism committed May 20, 2011
    Configuration menu
    Copy the full SHA
    afecd6f View commit details
    Browse the repository at this point in the history
  4. rm unnecessary logging

    catamorphism committed May 20, 2011
    Configuration menu
    Copy the full SHA
    cd8c4f2 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    587ec27 View commit details
    Browse the repository at this point in the history