diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-11-11 15:21:05 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-11-11 15:21:05 +0100 |
commit | f49cc60aa802862c595ff619dccc11271633a94b (patch) | |
tree | e8f01a0c236f2910f117c858f7236b8919e33b93 /src/list.c | |
parent | 8617b401599451187fa0c0561a84944978536a90 (diff) | |
download | vim-git-f49cc60aa802862c595ff619dccc11271633a94b.tar.gz |
patch 8.1.0519: cannot save and restore the tag stackv8.1.0519
Problem: Cannot save and restore the tag stack.
Solution: Add gettagstack() and settagstack(). (Yegappan Lakshmanan,
closes #3604)
Diffstat (limited to 'src/list.c')
-rw-r--r-- | src/list.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/list.c b/src/list.c index 9a348a8a6..3cf6dff76 100644 --- a/src/list.c +++ b/src/list.c @@ -86,6 +86,19 @@ list_alloc(void) } /* + * list_alloc() with an ID for alloc_fail(). + */ + list_T * +list_alloc_id(alloc_id_T id UNUSED) +{ +#ifdef FEAT_EVAL + if (alloc_fail_id == id && alloc_does_fail((long_u)sizeof(list_T))) + return NULL; +#endif + return (list_alloc()); +} + +/* * Allocate an empty list for a return value, with reference count set. * Returns OK or FAIL. */ |