mirror of
https://github.com/rust-lang/rust.git
synced 2025-05-10 17:07:36 +00:00

I also added `// skip-codegen` to each one, to address potential concerns that this change would otherwise slow down our test suite spending time generating code for files that are really just meant to be checks of compiler diagnostics. (However, I will say: My preference is to not use `// skip-codegen` if one can avoid it. We can use all the testing of how we drive LLVM that we can get...) (Updated post rebase.)
21 lines
646 B
Rust
21 lines
646 B
Rust
// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
|
|
// file at the top-level directory of this distribution and at
|
|
// http://rust-lang.org/COPYRIGHT.
|
|
//
|
|
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
|
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
|
|
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
|
|
// option. This file may not be copied, modified, or distributed
|
|
// except according to those terms.
|
|
|
|
// compile-pass
|
|
// skip-codegen
|
|
#![allow(warnings)]
|
|
// This used to ICE because the "if" being unreachable was not handled correctly
|
|
fn err() {
|
|
if loop {} {}
|
|
}
|
|
|
|
|
|
fn main() {}
|