aboutsummaryrefslogtreecommitdiff
path: root/scripts/gendispatch.lua
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2017-04-23 19:58:13 +0200
committerJustin M. Keyes <justinkz@gmail.com>2017-04-23 23:44:32 +0200
commit2ed91f222f1dddda10fbdc9cb80df2be7d4c2da3 (patch)
treea5448dfc1bd0440167cdfad4e3041ca1548bbf52 /scripts/gendispatch.lua
parent62c3f436a96e2102ec5c1e3af974c8e57fe4e76c (diff)
downloadrneovim-2ed91f222f1dddda10fbdc9cb80df2be7d4c2da3.tar.gz
rneovim-2ed91f222f1dddda10fbdc9cb80df2be7d4c2da3.tar.bz2
rneovim-2ed91f222f1dddda10fbdc9cb80df2be7d4c2da3.zip
api/internal: Remove `set` field from Error type.
Diffstat (limited to 'scripts/gendispatch.lua')
-rw-r--r--scripts/gendispatch.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/gendispatch.lua b/scripts/gendispatch.lua
index 683962aa60..53af67cce4 100644
--- a/scripts/gendispatch.lua
+++ b/scripts/gendispatch.lua
@@ -225,7 +225,7 @@ for i = 1, #functions do
end
output:write('\n')
output:write('\n if (args.size != '..#fn.parameters..') {')
- output:write('\n _api_set_error(error, error->type, "Wrong number of arguments: expecting '..#fn.parameters..' but got %zu", args.size);')
+ output:write('\n _api_set_error(error, kErrorTypeException, "Wrong number of arguments: expecting '..#fn.parameters..' but got %zu", args.size);')
output:write('\n goto cleanup;')
output:write('\n }\n')
@@ -250,7 +250,7 @@ for i = 1, #functions do
output:write('\n '..converted..' = (handle_T)args.items['..(j - 1)..'].data.integer;')
end
output:write('\n } else {')
- output:write('\n _api_set_error(error, error->type, "Wrong type for argument '..j..', expecting '..param[1]..'");')
+ output:write('\n _api_set_error(error, kErrorTypeException, "Wrong type for argument '..j..', expecting '..param[1]..'");')
output:write('\n goto cleanup;')
output:write('\n }\n')
else
@@ -290,7 +290,7 @@ for i = 1, #functions do
output:write('error);\n')
end
-- and check for the error
- output:write('\n if (error->set) {')
+ output:write('\n if (ERROR_SET(error)) {')
output:write('\n goto cleanup;')
output:write('\n }\n')
else