diff options
author | kyren <kerriganw@gmail.com> | 2017-12-03 23:45:00 -0500 |
---|---|---|
committer | kyren <kerriganw@gmail.com> | 2017-12-03 23:45:00 -0500 |
commit | d0ff10b528ca071d94ab92440a2328df5082ceb0 (patch) | |
tree | a36af8d487ad608af887e59d220f2ad98781f2cf /src/table.rs | |
parent | e80e7d45405fec6a1ce57dfa567199f7f592bbb6 (diff) | |
download | mlua-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.rs | 8 |
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"); |