Skip to content

Commit

Permalink
Disable delegate support under LDC
Browse files Browse the repository at this point in the history
  • Loading branch information
Bradley Chatha committed May 16, 2022
1 parent 32e49b0 commit 12c5c7c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions source/lumars/state.d
Original file line number Diff line number Diff line change
Expand Up @@ -511,6 +511,7 @@ struct LuaState
lua_pushcfunction(this.handle, value);
else static if(isDelegate!T)
{
version(LDC) static assert(false, "For some reason, delegate support under LDC crashes. See issue: https://github.com/BradleyChatha/lumars/issues/10"); // @suppress(dscanner.style.long_line)
lua_pushlightuserdata(this.handle, value.ptr);
lua_pushlightuserdata(this.handle, value.funcptr);
lua_pushcclosure(this.handle, &luaCWrapperSmart!(T, LuaFuncWrapperType.isDelegate), 2);
Expand Down

0 comments on commit 12c5c7c

Please sign in to comment.