librustc: Disallow "unsafe" for external functions

This commit is contained in:
Patrick Walton 2013-08-02 14:30:00 -07:00
parent 887c656970
commit 9457ebee55
36 changed files with 1709 additions and 1829 deletions

View file

@ -119,7 +119,7 @@ fn main() {
foreach y in range(0, 256) {
foreach x in range(0, 256) {
print((symbols[pixels[y*256+x] / 0.2f32) as int]);
print(symbols[(pixels[y*256+x] / 0.2f32) as int]);
}
println("");
}

View file

@ -13,7 +13,7 @@
mod test {
#[abi = "cdecl"]
extern {
pub unsafe fn free();
pub fn free();
}
}

View file

@ -1,5 +1,5 @@
extern {
pub unsafe fn free(p: *u8);
pub fn free(p: *u8);
}
pub fn main() {