aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/lib/khash.h
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2019-03-01 02:30:05 +0100
committerGitHub <noreply@github.com>2019-03-01 02:30:05 +0100
commite7bd49d835e26c96b2ee152e5b697e20ab749650 (patch)
treeb02e91d42c8b8a8ef578076ae8bf8deef26b94b5 /src/nvim/lib/khash.h
parent533d4a36ec03626e9d796ef7e2a9aa3c0e1ce7bf (diff)
parent403922b1b47c1f03272e2bdd600dcc02db481389 (diff)
downloadrneovim-e7bd49d835e26c96b2ee152e5b697e20ab749650.tar.gz
rneovim-e7bd49d835e26c96b2ee152e5b697e20ab749650.tar.bz2
rneovim-e7bd49d835e26c96b2ee152e5b697e20ab749650.zip
Merge #7920 'env: use libuv v1.12 getenv/setenv API'
Diffstat (limited to 'src/nvim/lib/khash.h')
-rw-r--r--src/nvim/lib/khash.h30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/nvim/lib/khash.h b/src/nvim/lib/khash.h
index 8287cb14da..b2994a3159 100644
--- a/src/nvim/lib/khash.h
+++ b/src/nvim/lib/khash.h
@@ -24,24 +24,24 @@
*/
/*
- An example:
+ Example:
#include "nvim/khash.h"
KHASH_MAP_INIT_INT(32, char)
int main() {
- int ret, is_missing;
- khiter_t k;
- khash_t(32) *h = kh_init(32);
- k = kh_put(32, h, 5, &ret);
- kh_value(h, k) = 10;
- k = kh_get(32, h, 10);
- is_missing = (k == kh_end(h));
- k = kh_get(32, h, 5);
- kh_del(32, h, k);
- for (k = kh_begin(h); k != kh_end(h); ++k)
- if (kh_exist(h, k)) kh_value(h, k) = 1;
- kh_destroy(32, h);
- return 0;
+ int ret, is_missing;
+ khiter_t k;
+ khash_t(32) *h = kh_init(32);
+ k = kh_put(32, h, 5, &ret);
+ kh_value(h, k) = 10;
+ k = kh_get(32, h, 10);
+ is_missing = (k == kh_end(h));
+ k = kh_get(32, h, 5);
+ kh_del(32, h, k);
+ for (k = kh_begin(h); k != kh_end(h); ++k)
+ if (kh_exist(h, k)) kh_value(h, k) = 1;
+ kh_destroy(32, h);
+ return 0;
}
*/
@@ -539,7 +539,7 @@ static kh_inline khint_t __ac_Wang_hash(khint_t key)
@param r Extra return code: -1 if the operation failed;
0 if the key is present in the hash table;
1 if the bucket is empty (never used); 2 if the element in
- the bucket has been deleted [int*]
+ the bucket has been deleted [int*]
@return Iterator to the inserted element [khint_t]
*/
#define kh_put(name, h, k, r) kh_put_##name(h, k, r)