I am not very smart.

This commit is contained in:
ThePhD 2019-07-04 14:48:10 -04:00
parent 0e9bb67576
commit 56c71502b3
No known key found for this signature in database
GPG Key ID: 1509DB1C0F702BFA

View File

@ -10,10 +10,10 @@ int main() {
sol::optional<int> x = lua["bark"]; sol::optional<int> x = lua["bark"];
// x will have a value // x will have a value
if (x) { if (x) {
return -1; std::cout << "x has no value, as expected" << std::endl;
} }
else { else {
std::cout << "x has no value, as expected" << std::endl; return -1;
} }
lua["bark"] = sol::lua_nil; lua["bark"] = sol::lua_nil;