From 8366da01fb62f7c860e86831642b99cfa6e60712 Mon Sep 17 00:00:00 2001 From: Nick Mathewson Date: Wed, 6 Feb 2008 05:31:15 +0000 Subject: r17935@catbus: nickm | 2008-02-05 20:54:54 -0500 Add typechecking cast functions for typed digestmap variants. svn:r13396 --- src/common/container.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/common') diff --git a/src/common/container.h b/src/common/container.h index 305dc0ea0..e4364109d 100644 --- a/src/common/container.h +++ b/src/common/container.h @@ -260,6 +260,10 @@ void* strmap_remove_lc(strmap_t *map, const char *key); { \ return (maptype*)digestmap_new(); \ } \ + static INLINE digestmap_t* prefix##to_digestmap(maptype *map) \ + { \ + return (digestmap_t*)map; \ + } \ static INLINE valtype* prefix##get(maptype *map, const char *key) \ { \ return (valtype*)digestmap_get((digestmap_t*)map, key); \ -- cgit v1.2.3