Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use () instead of libc::c_void #1000

Closed
4 tasks done
bvssvni opened this issue Nov 6, 2015 · 7 comments
Closed
4 tasks done

Use () instead of libc::c_void #1000

bvssvni opened this issue Nov 6, 2015 · 7 comments
Assignees
Labels

Comments

@bvssvni
Copy link
Member

bvssvni commented Nov 6, 2015

https://github.com/PistonDevelopers/piston/blob/master/src/window/src/lib.rs#L14

This could get rid of the libc dependency.

  • Remove libc dependency from pistoncore-window
  • Bump pistoncore-window to 0.14.0
  • Bump pistoncore-event_loop 0.16.0
  • Bump piston to 0.16.0
@mitchmindtree
Copy link
Contributor

I've also noticed the use of () as a replacement for libc::c_void - maybe this could be nice so that a user doesn't even need to import any types at all?

@bvssvni
Copy link
Member Author

bvssvni commented Nov 7, 2015

I'm getting "mismatched types" error for all the window backends, both for () and std::os::raw::c_void.

@bvssvni
Copy link
Member Author

bvssvni commented Nov 7, 2015

Seems Glutin is planning to use (). rust-windowing/glutin#652

@bvssvni
Copy link
Member Author

bvssvni commented Nov 7, 2015

I opened Rust-SDL2/rust-sdl2#465.

@bvssvni
Copy link
Member Author

bvssvni commented Nov 9, 2015

Looks like changing to () in Glutin is motivated by avoiding another libc breaking change.

@bvssvni
Copy link
Member Author

bvssvni commented Nov 20, 2015

  • sdl2_window is ready
  • glfw_window is ready
  • glutin_window is ready

@bvssvni bvssvni added easy and removed discussion labels Nov 20, 2015
@bvssvni
Copy link
Member Author

bvssvni commented Nov 20, 2015

Window backends are now ready for this change. I wrote down a todo list in top comment. Need to go, so unless somebody else does this, I'll do it later.

@bvssvni bvssvni self-assigned this Nov 21, 2015
@bvssvni bvssvni changed the title Use std::os::raw::c_void instead of libc::c_void Use () instead of libc::c_void Nov 21, 2015
bvssvni added a commit to bvssvni/piston that referenced this issue Nov 21, 2015
Closes PistonDevelopers#1000

- Removed dependency on libc in pistoncore-window
- Updated from `sleep_ms` to `sleep` in pistoncore-event_loop
- Bumped to 0.16.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants