mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
Fix build errors: use extern keyword
This commit is contained in:
parent
8861aba3ec
commit
7f343661a6
3 changed files with 9 additions and 9 deletions
|
@ -77,9 +77,9 @@ fn do_draw(sender: chan<AzDrawTargetRef>,
|
||||||
|
|
||||||
listen(|data_ch: chan<[u8]>| {
|
listen(|data_ch: chan<[u8]>| {
|
||||||
|
|
||||||
crust fn write_fn(closure: *c_void,
|
extern fn write_fn(closure: *c_void,
|
||||||
data: *c_uchar,
|
data: *c_uchar,
|
||||||
len: c_uint)
|
len: c_uint)
|
||||||
|
|
||||||
-> cairo_status_t unsafe {
|
-> cairo_status_t unsafe {
|
||||||
|
|
||||||
|
|
|
@ -271,7 +271,7 @@ mod platform {
|
||||||
}
|
}
|
||||||
|
|
||||||
mod MainObj {
|
mod MainObj {
|
||||||
crust fn applicationDidFinishLaunching(this: id, _sel: SEL) {
|
extern fn applicationDidFinishLaunching(this: id, _sel: SEL) {
|
||||||
#debug("applicationDidFinishLaunching");
|
#debug("applicationDidFinishLaunching");
|
||||||
|
|
||||||
let fptr: *fn() = ptr::null();
|
let fptr: *fn() = ptr::null();
|
||||||
|
|
|
@ -101,7 +101,7 @@ fn shape_text(font: &Font, text: str) -> [Glyph] unsafe {
|
||||||
ret glyphs;
|
ret glyphs;
|
||||||
}
|
}
|
||||||
|
|
||||||
crust fn glyph_func(_font: *hb_font_t,
|
extern fn glyph_func(_font: *hb_font_t,
|
||||||
font_data: *c_void,
|
font_data: *c_void,
|
||||||
unicode: hb_codepoint_t,
|
unicode: hb_codepoint_t,
|
||||||
_variant_selector: hb_codepoint_t,
|
_variant_selector: hb_codepoint_t,
|
||||||
|
@ -122,10 +122,10 @@ crust fn glyph_func(_font: *hb_font_t,
|
||||||
} as hb_bool_t;
|
} as hb_bool_t;
|
||||||
}
|
}
|
||||||
|
|
||||||
crust fn glyph_h_advance_func(_font: *hb_font_t,
|
extern fn glyph_h_advance_func(_font: *hb_font_t,
|
||||||
font_data: *c_void,
|
font_data: *c_void,
|
||||||
glyph: hb_codepoint_t,
|
glyph: hb_codepoint_t,
|
||||||
_user_data: *c_void) -> hb_position_t unsafe {
|
_user_data: *c_void) -> hb_position_t unsafe {
|
||||||
let font: *Font = reinterpret_cast(font_data);
|
let font: *Font = reinterpret_cast(font_data);
|
||||||
assert font.is_not_null();
|
assert font.is_not_null();
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue