mirror of
https://github.com/neovim/neovim.git
synced 2025-09-29 22:48:34 +00:00
refactor(autocmd): simplify check for freed callback
When a callback is freed the type is always set to kCallbackNone.
This commit is contained in:
@@ -2473,7 +2473,7 @@ bool aucmd_exec_is_deleted(AucmdExecutable acc)
|
||||
case CALLABLE_EX:
|
||||
return acc.callable.cmd == NULL;
|
||||
case CALLABLE_CB:
|
||||
return callback_is_freed(acc.callable.cb);
|
||||
return acc.callable.cb.type == kCallbackNone;
|
||||
case CALLABLE_NONE:
|
||||
return true;
|
||||
}
|
||||
|
Reference in New Issue
Block a user