{"action":"created","issue":{"url":"https://api.github.com/repos/rust-gnome/gtk/issues/42","labels_url":"https://api.github.com/repos/rust-gnome/gtk/issues/42/labels{/name}","comments_url":"https://api.github.com/repos/rust-gnome/gtk/issues/42/comments","events_url":"https://api.github.com/repos/rust-gnome/gtk/issues/42/events","html_url":"https://github.com/rust-gnome/gtk/issues/42","id":71286936,"number":42,"title":"Can't build due to usage of removed std::num::FromPrimitive","user":{"login":"MaTachi","id":980838,"avatar_url":"https://avatars.githubusercontent.com/u/980838?v=3","gravatar_id":"","url":"https://api.github.com/users/MaTachi","html_url":"https://github.com/MaTachi","followers_url":"https://api.github.com/users/MaTachi/followers","following_url":"https://api.github.com/users/MaTachi/following{/other_user}","gists_url":"https://api.github.com/users/MaTachi/gists{/gist_id}","starred_url":"https://api.github.com/users/MaTachi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MaTachi/subscriptions","organizations_url":"https://api.github.com/users/MaTachi/orgs","repos_url":"https://api.github.com/users/MaTachi/repos","events_url":"https://api.github.com/users/MaTachi/events{/privacy}","received_events_url":"https://api.github.com/users/MaTachi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":15,"created_at":"2015-04-27T13:38:10Z","updated_at":"2015-04-30T13:20:50Z","closed_at":null,"body":"I cloned the examples repo, https://github.com/rust-gnome/examples, and tried to build it with the latest Rust nightly. However, it fails since `gtk-sys` depends on `std::num::FromPrimitive` which has been removed from Rust's API. Here's another project that experienced the same problem: https://github.com/brson/rust-sdl/issues/165\r\n\r\nMy terminal output:\r\n\r\n    $ rustc --version\r\n    rustc 1.1.0-nightly (5fb0259ed 2015-04-26) (built 2015-04-27)\r\n    $ cargo clean\r\n    $ cargo build\r\n      Compiling libc v0.1.6\r\n      Compiling gcc v0.3.4\r\n      Compiling bitflags v0.1.1\r\n      Compiling c_vec v1.0.11\r\n      Compiling pkg-config v0.3.3\r\n      Compiling gtk-sys v0.1.0 (https://github.com/rust-gnome/gtk#0121d69b)\r\n      Compiling gdk-sys v0.1.0 (https://github.com/rust-gnome/gdk#2b1fc225)\r\n      Compiling pango-sys v0.1.0 (https://github.com/rust-gnome/pango#3ce36f5e)\r\n      Compiling glib-sys v0.1.0 (https://github.com/rust-gnome/glib#e8fc0580)\r\n      Compiling cairo-sys v0.1.0 (https://github.com/rust-gnome/cairo#93cb13e5)\r\n      Compiling glib v0.0.1 (https://github.com/rust-gnome/glib#e8fc0580)\r\n      Compiling pango v0.0.1 (https://github.com/rust-gnome/pango#3ce36f5e)\r\n      Compiling cairo v0.0.1 (https://github.com/rust-gnome/cairo#93cb13e5)\r\n      Compiling gdk v0.0.1 (https://github.com/rust-gnome/gdk#2b1fc225)\r\n    /home/matachi/.cargo/git/checkouts/gtk-d0515cff4231591e/master/gtk-sys/src/enums.rs:816:47: 816:60 error: use of undeclared trait name `std::num::FromPrimitive`\r\n    /home/matachi/.cargo/git/checkouts/gtk-d0515cff4231591e/master/gtk-sys/src/enums.rs:816 #[derive(Clone, PartialEq, PartialOrd, Debug, FromPrimitive, Copy)]\r\n                                                                                                                                          ^~~~~~~~~~~~~\r\n    /home/matachi/.cargo/git/checkouts/gtk-d0515cff4231591e/master/gtk-sys/src/enums.rs:816:47: 816:60 note: in expansion of #[derive_FromPrimitive]\r\n    /home/matachi/.cargo/git/checkouts/gtk-d0515cff4231591e/master/gtk-sys/src/enums.rs:816:47: 816:60 note: expansion site\r\n    error: aborting due to previous error\r\n    Build failed, waiting for other jobs to finish...\r\n    Could not compile `gtk-sys`.\r\n\r\n    To learn more, run the command again with --verbose.\r\n"},"comment":{"url":"https://api.github.com/repos/rust-gnome/gtk/issues/comments/97778653","html_url":"https://github.com/rust-gnome/gtk/issues/42#issuecomment-97778653","issue_url":"https://api.github.com/repos/rust-gnome/gtk/issues/42","id":97778653,"user":{"login":"GuillaumeGomez","id":3050060,"avatar_url":"https://avatars.githubusercontent.com/u/3050060?v=3","gravatar_id":"","url":"https://api.github.com/users/GuillaumeGomez","html_url":"https://github.com/GuillaumeGomez","followers_url":"https://api.github.com/users/GuillaumeGomez/followers","following_url":"https://api.github.com/users/GuillaumeGomez/following{/other_user}","gists_url":"https://api.github.com/users/GuillaumeGomez/gists{/gist_id}","starred_url":"https://api.github.com/users/GuillaumeGomez/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GuillaumeGomez/subscriptions","organizations_url":"https://api.github.com/users/GuillaumeGomez/orgs","repos_url":"https://api.github.com/users/GuillaumeGomez/repos","events_url":"https://api.github.com/users/GuillaumeGomez/events{/privacy}","received_events_url":"https://api.github.com/users/GuillaumeGomez/received_events","type":"User","site_admin":false},"created_at":"2015-04-30T13:20:49Z","updated_at":"2015-04-30T13:20:49Z","body":"I think it's better to update `c_vec`. `gtk` isn't the only project to use it so I'll have to change it a day or another before the 1.0 release.\r\n\r\nI'll update it tonight, or maybe you wanna do it ? You implemented the Unique part so as you prefer."}}