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

Struct binding with empty constructor fail #101

Open
SrMordred opened this issue Apr 6, 2016 · 0 comments
Open

Struct binding with empty constructor fail #101

SrMordred opened this issue Apr 6, 2016 · 0 comments

Comments

@SrMordred
Copy link

Minimal example (without the imports)

class MyClass{
    this(){  }
};
struct MyStruct{
};
void main(){
    auto lua = new LuaState;
    lua.openLibs();
    lua["MyClass"]  = lua.registerType!MyClass();
    lua["MyStruct"] = lua.registerType!MyStruct();
    lua.doString("local x  = MyClass();"); //work
    lua.doString("local y  = MyStruct();"); //fail
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant