Moved problematic tests on x86_64-pc-windows-gnu back to compile-fail.
This commit is contained in:
parent
67ec37b608
commit
d775e6132c
8 changed files with 54 additions and 37 deletions
22
src/test/compile-fail/auxiliary/some-panic-impl.rs
Normal file
22
src/test/compile-fail/auxiliary/some-panic-impl.rs
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
// Copyright 2018 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.
|
||||
|
||||
// no-prefer-dynamic
|
||||
|
||||
#![crate_type = "rlib"]
|
||||
#![feature(panic_implementation)]
|
||||
#![no_std]
|
||||
|
||||
use core::panic::PanicInfo;
|
||||
|
||||
#[panic_implementation]
|
||||
fn panic(info: &PanicInfo) -> ! {
|
||||
loop {}
|
||||
}
|
||||
32
src/test/compile-fail/auxiliary/weak-lang-items.rs
Normal file
32
src/test/compile-fail/auxiliary/weak-lang-items.rs
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
// Copyright 2014 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.
|
||||
|
||||
// no-prefer-dynamic
|
||||
|
||||
// This aux-file will require the eh_personality function to be codegen'd, but
|
||||
// it hasn't been defined just yet. Make sure we don't explode.
|
||||
|
||||
#![no_std]
|
||||
#![crate_type = "rlib"]
|
||||
|
||||
struct A;
|
||||
|
||||
impl core::ops::Drop for A {
|
||||
fn drop(&mut self) {}
|
||||
}
|
||||
|
||||
pub fn foo() {
|
||||
let _a = A;
|
||||
panic!("wut");
|
||||
}
|
||||
|
||||
mod std {
|
||||
pub use core::{option, fmt};
|
||||
}
|
||||
|
|
@ -1,4 +0,0 @@
|
|||
error: `#[panic_implementation]` function required, but not found
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
|
|
@ -1,14 +0,0 @@
|
|||
error[E0152]: duplicate lang item found: `panic_impl`.
|
||||
--> $DIR/panic-implementation-twice.rs:23:1
|
||||
|
|
||||
LL | / fn panic(info: &PanicInfo) -> ! {
|
||||
LL | | //~^ error duplicate lang item found: `panic_impl`
|
||||
LL | | loop {}
|
||||
LL | | }
|
||||
| |_^
|
||||
|
|
||||
= note: first defined in crate `some_panic_impl`.
|
||||
|
||||
error: aborting due to previous error
|
||||
|
||||
For more information about this error, try `rustc --explain E0152`.
|
||||
|
|
@ -1,19 +0,0 @@
|
|||
error[E0259]: the name `core` is defined multiple times
|
||||
--> $DIR/weak-lang-item.rs:18:1
|
||||
|
|
||||
LL | extern crate core;
|
||||
| ^^^^^^^^^^^^^^^^^^ `core` reimported here
|
||||
|
|
||||
= note: `core` must be defined only once in the type namespace of this module
|
||||
help: You can use `as` to change the binding name of the import
|
||||
|
|
||||
LL | extern crate core as other_core;
|
||||
|
|
||||
|
||||
error: `#[panic_implementation]` function required, but not found
|
||||
|
||||
error: language item required, but not found: `eh_personality`
|
||||
|
||||
error: aborting due to 3 previous errors
|
||||
|
||||
For more information about this error, try `rustc --explain E0259`.
|
||||
Loading…
Add table
Add a link
Reference in a new issue