Auto merge of #107 - rthomas:106-warnings, r=jdm
Remove zero-sized struct warning. #106. This change will fix the remaining warnings in servo/core-text-rs#62 when it is released and the core-text crate is updated. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/core-foundation-rs/107) <!-- Reviewable:end -->
This commit is contained in:
@@ -3,7 +3,7 @@ name = "core-foundation-sys"
|
||||
description = "Bindings to Core Foundation for OS X"
|
||||
homepage = "https://github.com/servo/core-foundation-rs"
|
||||
repository = "https://github.com/servo/core-foundation-rs"
|
||||
version = "0.4.1"
|
||||
version = "0.4.2"
|
||||
authors = ["The Servo Project Developers"]
|
||||
license = "MIT / Apache-2.0"
|
||||
build = "build.rs"
|
||||
|
||||
@@ -37,8 +37,9 @@ pub static kCFNumberFloat64Type: CFNumberType = 6;
|
||||
// static kCFNumberCGFloatType: CFNumberType = 16;
|
||||
// static kCFNumberMaxType: CFNumberType = 16;
|
||||
|
||||
#[repr(C)]
|
||||
pub struct __CFNumber;
|
||||
// This is an enum due to zero-sized types warnings.
|
||||
// For more details see https://github.com/rust-lang/rust/issues/27303
|
||||
pub enum __CFNumber {}
|
||||
|
||||
pub type CFNumberRef = *const __CFNumber;
|
||||
|
||||
|
||||
@@ -3,13 +3,13 @@ name = "core-foundation"
|
||||
description = "Bindings to Core Foundation for OS X"
|
||||
homepage = "https://github.com/servo/core-foundation-rs"
|
||||
repository = "https://github.com/servo/core-foundation-rs"
|
||||
version = "0.4.1"
|
||||
version = "0.4.2"
|
||||
authors = ["The Servo Project Developers"]
|
||||
license = "MIT / Apache-2.0"
|
||||
|
||||
[dependencies.core-foundation-sys]
|
||||
path = "../core-foundation-sys"
|
||||
version = "0.4.0"
|
||||
version = "0.4.2"
|
||||
|
||||
[dependencies]
|
||||
libc = "0.2"
|
||||
|
||||
@@ -125,8 +125,9 @@ mod test {
|
||||
|
||||
|
||||
let run_loop_timer = CFRunLoopTimer::new(now + 0.20f64, 0f64, 0, 0, timer_popped, &mut context);
|
||||
run_loop.add_timer(&run_loop_timer, kCFRunLoopDefaultMode);
|
||||
|
||||
unsafe {
|
||||
run_loop.add_timer(&run_loop_timer, kCFRunLoopDefaultMode);
|
||||
}
|
||||
CFRunLoop::run_current();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user