Skip to content

Commit 266f49f

Browse files
committed
---
yaml --- r: 234923 b: refs/heads/stable c: 759a7f1 h: refs/heads/master i: 234921: 589701c 234919: 84c718f v: v3
1 parent bbe657c commit 266f49f

File tree

3 files changed

+9
-58
lines changed

3 files changed

+9
-58
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: afae2ff723393b3ab4ccffef6ac7c6d1809e2da0
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: f859507de8c410b648d934d8f5ec1c52daac971d
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: 9e3cb6447596049464292c0afa8c4b9a0cb8c806
32+
refs/heads/stable: 759a7f1f66490191a6f809c9709151d6d27cea87
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/src/test/auxiliary/lang-item-public.rs

Lines changed: 7 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -8,42 +8,21 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
#![feature(no_std)]
11+
#![feature(no_std, core, libc)]
1212
#![no_std]
1313
#![feature(lang_items)]
1414

15-
#[lang="sized"]
16-
pub trait Sized { }
17-
18-
#[lang="panic"]
19-
fn panic(_: &(&'static str, &'static str, usize)) -> ! { loop {} }
15+
extern crate core;
16+
extern crate libc;
2017

2118
#[lang = "stack_exhausted"]
2219
extern fn stack_exhausted() {}
2320

2421
#[lang = "eh_personality"]
2522
extern fn eh_personality() {}
2623

27-
#[lang="copy"]
28-
pub trait Copy {
29-
// Empty.
30-
}
31-
32-
#[lang="rem"]
33-
pub trait Rem<RHS=Self> {
34-
type Output = Self;
35-
fn rem(self, rhs: RHS) -> Self::Output;
36-
}
37-
38-
impl Rem for isize {
39-
type Output = isize;
40-
41-
#[inline]
42-
fn rem(self, other: isize) -> isize {
43-
// if you use `self % other` here, as one would expect, you
44-
// get back an error because of potential failure/overflow,
45-
// which tries to invoke error fns that don't have the
46-
// appropriate signatures anymore. So...just return 0.
47-
0
48-
}
24+
#[lang = "panic_fmt"]
25+
extern fn rust_begin_unwind(msg: core::fmt::Arguments, file: &'static str,
26+
line: u32) -> ! {
27+
loop {}
4928
}

branches/stable/src/test/run-pass/lang-item-public.rs

Lines changed: 1 addition & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -11,39 +11,11 @@
1111
// aux-build:lang-item-public.rs
1212
// ignore-android
1313

14-
#![feature(lang_items, start, no_std)]
14+
#![feature(start, no_std)]
1515
#![no_std]
1616

1717
extern crate lang_item_public as lang_lib;
1818

19-
#[cfg(target_os = "linux")]
20-
#[link(name = "c")]
21-
extern {}
22-
23-
#[cfg(target_os = "android")]
24-
#[link(name = "c")]
25-
extern {}
26-
27-
#[cfg(target_os = "freebsd")]
28-
#[link(name = "execinfo")]
29-
extern {}
30-
31-
#[cfg(target_os = "freebsd")]
32-
#[link(name = "c")]
33-
extern {}
34-
35-
#[cfg(target_os = "dragonfly")]
36-
#[link(name = "c")]
37-
extern {}
38-
39-
#[cfg(any(target_os = "bitrig", target_os = "openbsd"))]
40-
#[link(name = "c")]
41-
extern {}
42-
43-
#[cfg(target_os = "macos")]
44-
#[link(name = "System")]
45-
extern {}
46-
4719
#[start]
4820
fn main(_: isize, _: *const *const u8) -> isize {
4921
1_isize % 1_isize

0 commit comments

Comments
 (0)