Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Test multiple_bound_lifetimes_give_static

Source location: crates/formality-rust/src/prove/test/outlives.rs:56

#[test]
fn multiple_bound_lifetimes_give_static() {
    // Exercise both binder positions, including an unused bound lifetime.
    for assertion in [
        "forall<T> {for<'a, 'b> T : 'a} => {T : 'static}",
        "forall<T> {for<'a, 'b> T : 'b} => {T : 'static}",
    ] {
        test_prove(Program::empty(), term(assertion))
            .assert_ok(expect!["{Constraints { env: Env { variables: [!ty_1], bias: Soundness, pending: [], allow_pending_outlives: false }, known_true: true, substitution: {} }}"]);
    }
}

Rules proved (5)

Premises failed (0)

This test records no negative coverage.

Proof trees

Proof tree

How to read this page