diff options
author | Eliseo Martínez <eliseomarmol@gmail.com> | 2014-05-24 01:17:51 +0200 |
---|---|---|
committer | Eliseo Martínez <eliseomarmol@gmail.com> | 2014-05-24 01:17:51 +0200 |
commit | f179081fc84c4f8b2bb80d731ee3936fbc075a32 (patch) | |
tree | 275aa1973336b74c4a95e09f26f873b563fed6d4 /src | |
parent | ffed9bfae92d2fed0fa7af41186b948de8d51256 (diff) | |
download | rneovim-f179081fc84c4f8b2bb80d731ee3936fbc075a32.tar.gz rneovim-f179081fc84c4f8b2bb80d731ee3936fbc075a32.tar.bz2 rneovim-f179081fc84c4f8b2bb80d731ee3936fbc075a32.zip |
Remove long_u: hashtab: Enable clint: Add to clint.
- Add hashtab.[ch] to clint file.
- Fix clint errors.
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/hashtab.c | 6 | ||||
-rw-r--r-- | src/nvim/hashtab.h | 10 |
2 files changed, 8 insertions, 8 deletions
diff --git a/src/nvim/hashtab.c b/src/nvim/hashtab.c index f31d2f2cbd..4e4274bfa1 100644 --- a/src/nvim/hashtab.c +++ b/src/nvim/hashtab.c @@ -67,7 +67,7 @@ void hash_clear_all(hashtab_T *ht, unsigned int off) hash_clear(ht); } -/// Find item for given "key" in hashtable "ht". +/// Find item for given "key" in hashtable "ht". /// /// @param key The key of the looked-for item. Must not be NULL. /// @@ -210,7 +210,7 @@ int hash_add_item(hashtab_T *ht, hashitem_T *hi, char_u *key, hash_T hash) } /// Remove item "hi" from hashtable "ht". -/// +/// /// Caller must take care of freeing the item itself. /// /// @param hi The hash item to be removed. @@ -222,7 +222,7 @@ void hash_remove(hashtab_T *ht, hashitem_T *hi) hash_may_resize(ht, 0); } -/// Lock hashtable (prevent changes in ht_array). +/// Lock hashtable (prevent changes in ht_array). /// /// Don't use this when items are to be added! /// Must call hash_unlock() later. diff --git a/src/nvim/hashtab.h b/src/nvim/hashtab.h index dbb7fd9181..bd64984ac8 100644 --- a/src/nvim/hashtab.h +++ b/src/nvim/hashtab.h @@ -5,10 +5,10 @@ #include "nvim/vim.h" /// Type for hash number (hash calculation result). -typedef size_t hash_T; +typedef size_t hash_T; /// The address of "hash_removed" is used as a magic number -/// for hi_key to indicate a removed item. +/// for hi_key to indicate a removed item. #define HI_KEY_REMOVED &hash_removed #define HASHITEM_EMPTY(hi) ((hi)->hi_key == NULL \ || (hi)->hi_key == &hash_removed) @@ -34,7 +34,7 @@ typedef struct hashitem_S { hash_T hi_hash; /// Item key. - /// + /// /// Possible values mean the following: /// NULL : Item was never used. /// HI_KEY_REMOVED : Item was removed. @@ -44,7 +44,7 @@ typedef struct hashitem_S { /// Initial size for a hashtable. /// Our items are relatively small and growing is expensive, thus start with 16. -/// Must be a power of 2. +/// Must be a power of 2. #define HT_INIT_SIZE 16 /// An array-based hashtable. @@ -80,4 +80,4 @@ void hash_lock(hashtab_T *ht); void hash_unlock(hashtab_T *ht); hash_T hash_hash(char_u *key); -#endif /* NVIM_HASHTAB_H */ +#endif // NVIM_HASHTAB_H |