diff options
| author | ruki <[email protected]> | 2019-05-23 00:46:44 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2019-05-22 22:40:27 +0800 |
| commit | 744ce235235533e695430daa1f96cbd35c69ac01 (patch) | |
| tree | 8ed3e616bbc31655eb6d8a369c5eafcba187a528 /xmake/core/base/os.lua | |
| parent | b91f9e89bed5bf3db0f7a0e78b6c69666eab21eb (diff) | |
add ndk_stdcxx option for ndk
Diffstat (limited to 'xmake/core/base/os.lua')
| -rw-r--r-- | xmake/core/base/os.lua | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/xmake/core/base/os.lua b/xmake/core/base/os.lua index 3daebd280..09274450d 100644 --- a/xmake/core/base/os.lua +++ b/xmake/core/base/os.lua @@ -711,8 +711,15 @@ function os.raise(msg, ...) io.flush() -- raise it - if msg then + if type(msg) == "string" then error(string.tryformat(msg, ...)) + elseif type(msg) == "table" then + local errobjstr, errors = string.serialize(msg, true) + if errobjstr then + error("[@encode(error)]: " .. errobjstr) + else + error(errors) + end else error() end |
