Giter Site home page Giter Site logo

rlua-builders's People

Contributors

caranatar avatar yancouto avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

caranatar

rlua-builders's Issues

Crate only works with rlua version 0.17

When attempting to build a trivial project based on coping and pasting the example from the documentation, cargo check fails with:

    Checking rlua-build v0.1.0 (/rlua-build)
error[E0277]: the trait bound `Person: rlua::userdata::UserData` is not satisfied
  --> src/main.rs:3:10
   |
3  | #[derive(LuaBuilder, UserData, Clone, PartialEq, Debug)]
   |          ^^^^^^^^^^ the trait `rlua::userdata::UserData` is not implemented for `Person`
   |
note: required by a bound in `LuaBuilder`
  --> /rlua-build/.cargo/registry/src/github.com-1ecc6299db9ec823/rlua-builders-0.1.4/src/lib.rs:95:41
   |
95 | pub trait LuaBuilder<'s, T: ToLua<'s>>: UserData + Clone {
   |                                         ^^^^^^^^ required by this bound in `LuaBuilder`
   = note: this error originates in the derive macro `LuaBuilder` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: the trait bound `LuaFunction<'s>: rlua::userdata::UserData` is not satisfied
  --> src/main.rs:3:10
   |
3  | #[derive(LuaBuilder, UserData, Clone, PartialEq, Debug)]
   |          ^^^^^^^^^^ the trait `rlua::userdata::UserData` is not implemented for `LuaFunction<'s>`
   |
   = note: required because of the requirements on the impl of `rlua::value::ToLua<'s>` for `LuaFunction<'s>`
note: required by a bound in `LuaBuilder`
  --> /rlua-build/.cargo/registry/src/github.com-1ecc6299db9ec823/rlua-builders-0.1.4/src/lib.rs:95:29
   |
95 | pub trait LuaBuilder<'s, T: ToLua<'s>>: UserData + Clone {
   |                             ^^^^^^^^^ required by this bound in `LuaBuilder`
   = note: this error originates in the derive macro `LuaBuilder` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: `*mut rlua_lua54_sys::bindings::lua_State` cannot be sent between threads safely
  --> src/main.rs:3:10
   |
3  | #[derive(LuaBuilder, UserData, Clone, PartialEq, Debug)]
   |          ^^^^^^^^^^ `*mut rlua_lua54_sys::bindings::lua_State` cannot be sent between threads safely
   |
   = help: within `LuaFunction<'s>`, the trait `Send` is not implemented for `*mut rlua_lua54_sys::bindings::lua_State`
   = note: required because it appears within the type `LuaContext<'s>`
   = note: required because it appears within the type `rlua::types::LuaRef<'s>`
   = note: required because it appears within the type `LuaFunction<'s>`
   = note: required because of the requirements on the impl of `rlua::value::ToLua<'s>` for `LuaFunction<'s>`
note: required by a bound in `LuaBuilder`
  --> /rlua-build/.cargo/registry/src/github.com-1ecc6299db9ec823/rlua-builders-0.1.4/src/lib.rs:95:29
   |
95 | pub trait LuaBuilder<'s, T: ToLua<'s>>: UserData + Clone {
   |                             ^^^^^^^^^ required by this bound in `LuaBuilder`
   = note: this error originates in the derive macro `LuaBuilder` (in Nightly builds, run with -Z macro-backtrace for more info)

error[E0277]: `*mut PhantomData<UnsafeCell<()>>` cannot be sent between threads safely
  --> src/main.rs:3:10
   |
3  | #[derive(LuaBuilder, UserData, Clone, PartialEq, Debug)]
   |          ^^^^^^^^^^ `*mut PhantomData<UnsafeCell<()>>` cannot be sent between threads safely
   |
   = help: within `LuaFunction<'s>`, the trait `Send` is not implemented for `*mut PhantomData<UnsafeCell<()>>`
   = note: required because it appears within the type `PhantomData<*mut PhantomData<UnsafeCell<()>>>`
   = note: required because it appears within the type `LuaContext<'s>`
   = note: required because it appears within the type `rlua::types::LuaRef<'s>`
   = note: required because it appears within the type `LuaFunction<'s>`
   = note: required because of the requirements on the impl of `rlua::value::ToLua<'s>` for `LuaFunction<'s>`
note: required by a bound in `LuaBuilder`
  --> /rlua-build/.cargo/registry/src/github.com-1ecc6299db9ec823/rlua-builders-0.1.4/src/lib.rs:95:29
   |
95 | pub trait LuaBuilder<'s, T: ToLua<'s>>: UserData + Clone {
   |                             ^^^^^^^^^ required by this bound in `LuaBuilder`
   = note: this error originates in the derive macro `LuaBuilder` (in Nightly builds, run with -Z macro-backtrace for more info)

For more information about this error, try `rustc --explain E0277`.
error: could not compile `rlua-build` due to 4 previous errors

Using rlua 0.17.0 or 0.17.1 seems to make the build succeed. Newer, as well as older, rlua versions fail. I have not made any attempts at understanding the cause of the error.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.