diff options
author | Soumith Chintala <soumith@gmail.com> | 2016-08-27 17:44:19 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-27 17:44:19 +0300 |
commit | 65255bae65c1bba69ee45c7c88e49bc241c8d361 (patch) | |
tree | ea1ec94efd1257a4fe92eac1b920fcbc99b37f82 | |
parent | 9b1aeb13fa0786022843ea157b6d82a4d8a336f0 (diff) | |
parent | 69fd462f3c9f1f961b9599b3f26136d252b949bd (diff) |
Merge pull request #748 from torch/funcload
changing function load errors to warnings
-rw-r--r-- | File.lua | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -275,7 +275,7 @@ function File:readObject() local dumped = self:readChar(size):string() local func, err = loadstring(dumped) if not func then - error(string.format('Failed to load function from bytecode: %s', err)) + io.stderr:write(string.format('Warning: Failed to load function from bytecode: %s', err)) end local upvalues = self:readObject() for index,upvalue in ipairs(upvalues) do @@ -298,7 +298,7 @@ function File:readObject() local dumped = self:readChar(size):string() local func, err = loadstring(dumped) if not func then - error(string.format('Failed to load function from bytecode: %s', err)) + io.stderr:write(string.format('Warning: Failed to load function from bytecode: %s', err)) end if not force then objects[index] = func |