Don't bother with a feature, just disable LUA_USE_APICHECK in release
This commit is contained in:
parent
60743d45cd
commit
f785a3abe4
|
@ -22,12 +22,6 @@ default = ["builtin-lua"]
|
||||||
# * LUA_NUMBER as double
|
# * LUA_NUMBER as double
|
||||||
# * LUA_EXTRASPACE is sizeof(void*)
|
# * LUA_EXTRASPACE is sizeof(void*)
|
||||||
builtin-lua = ["gcc"]
|
builtin-lua = ["gcc"]
|
||||||
# Don't define LUA_USE_APICHECK if we are in release mode. When
|
|
||||||
# debug_assertions are enabled, LUA_USE_APICHECK is enabled regardless. There
|
|
||||||
# are still a few known ways to trigger LUA_USE_APICHECK checks with rlua, but
|
|
||||||
# when these bugs are fixed, this option will go away and this behavior will be
|
|
||||||
# the default.
|
|
||||||
disable-lua-apicheck = []
|
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
libc = { version = "0.2" }
|
libc = { version = "0.2" }
|
||||||
|
|
2
build.rs
2
build.rs
|
@ -21,7 +21,7 @@ fn main() {
|
||||||
config.define("LUA_USE_WINDOWS", None);
|
config.define("LUA_USE_WINDOWS", None);
|
||||||
}
|
}
|
||||||
|
|
||||||
if cfg!(debug_assertions) || !cfg!(feature = "disable-lua-apicheck") {
|
if cfg!(debug_assertions) {
|
||||||
config.define("LUA_USE_APICHECK", None);
|
config.define("LUA_USE_APICHECK", None);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue