rust/src/test/run-fail/binop-fail-2.rs
Tim Chevalier 731797d075 In trans, don't assume both sides of a binop have the same type
This was at least partially responsible for Issue 777.

    The only solution I can think of is for trans to just not generate
    code for a comparison if one or both sides has type _|_. Since
    that means evaluating that subexpression diverges, it should be ok
    to never do the comparison. Actually generating code for the
    comparison would trip an LLVM assertion failure.
2011-08-02 17:36:41 -07:00

4 lines
108 B
Rust

// error-pattern:quux
fn my_err(s: str) -> ! { log_err s; fail "quux"; }
fn main() { 3u == my_err("bye"); }