diff options
Diffstat (limited to 'Objects/dictobject.c')
-rw-r--r-- | Objects/dictobject.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Objects/dictobject.c b/Objects/dictobject.c index 2a51d51..b89b7b2 100644 --- a/Objects/dictobject.c +++ b/Objects/dictobject.c @@ -566,6 +566,17 @@ mapping_items(mp, args) return v; } +int +getmappingsize(mp) + object *mp; +{ + if (mp == NULL || !is_mappingobject(mp)) { + err_badcall(); + return NULL; + } + return ((mappingobject *)mp)->ma_used; +} + object * getmappingkeys(mp) object *mp; |