summaryrefslogtreecommitdiff
path: root/src/table.rs
diff options
context:
space:
mode:
authorkyren <kerriganw@gmail.com>2017-12-03 23:45:00 -0500
committerkyren <kerriganw@gmail.com>2017-12-03 23:45:00 -0500
commitd0ff10b528ca071d94ab92440a2328df5082ceb0 (patch)
treea36af8d487ad608af887e59d220f2ad98781f2cf /src/table.rs
parente80e7d45405fec6a1ce57dfa567199f7f592bbb6 (diff)
downloadmlua-d0ff10b528ca071d94ab92440a2328df5082ceb0.zip
I believe this is all the external API changes necessary for 'm' safety
Diffstat (limited to 'src/table.rs')
-rw-r--r--src/table.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/table.rs b/src/table.rs
index 2717013..f4339b2 100644
--- a/src/table.rs
+++ b/src/table.rs
@@ -452,7 +452,7 @@ mod tests {
let lua = Lua::new();
let globals = lua.globals();
- globals.set("table", lua.create_table()).unwrap();
+ globals.set("table", lua.create_table().unwrap()).unwrap();
let table1: Table = globals.get("table").unwrap();
let table2: Table = globals.get("table").unwrap();
@@ -588,10 +588,10 @@ mod tests {
fn test_metatable() {
let lua = Lua::new();
- let table = lua.create_table();
- let metatable = lua.create_table();
+ let table = lua.create_table().unwrap();
+ let metatable = lua.create_table().unwrap();
metatable
- .set("__index", lua.create_function(|_, ()| Ok("index_value")))
+ .set("__index", lua.create_function(|_, ()| Ok("index_value")).unwrap())
.unwrap();
table.set_metatable(Some(metatable));
assert_eq!(table.get::<_, String>("any_key").unwrap(), "index_value");