refactor(api): complete conversion from Dictionary to Dict(opts) (#26365)

This commit is contained in:
Riccardo Mazzarini
2023-12-05 12:33:57 +01:00
committed by GitHub
parent 32c8f951bb
commit 0b74ad0a64
11 changed files with 121 additions and 150 deletions

View File

@@ -126,7 +126,7 @@ void nvim_buf_clear_highlight(Buffer buffer, Integer ns_id, Integer line_start,
/// @param[out] err Error details, if any
/// @return The ns_id that was used
Integer nvim_buf_set_virtual_text(Buffer buffer, Integer src_id, Integer line, Array chunks,
Dictionary opts, Error *err)
Dict(empty) *opts, Error *err)
FUNC_API_SINCE(5)
FUNC_API_DEPRECATED_SINCE(8)
{
@@ -140,11 +140,6 @@ Integer nvim_buf_set_virtual_text(Buffer buffer, Integer src_id, Integer line, A
return 0;
}
if (opts.size > 0) {
api_set_error(err, kErrorTypeValidation, "opts dict isn't empty");
return 0;
}
uint32_t ns_id = src2ns(&src_id);
int width;