Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-11-19 09:50:45

0001 #ifndef Py_INTERNAL_DICT_STATE_H
0002 #define Py_INTERNAL_DICT_STATE_H
0003 #ifdef __cplusplus
0004 extern "C" {
0005 #endif
0006 
0007 #ifndef Py_BUILD_CORE
0008 #  error "this header requires Py_BUILD_CORE define"
0009 #endif
0010 
0011 #define DICT_MAX_WATCHERS 8
0012 #define DICT_WATCHED_MUTATION_BITS 4
0013 
0014 struct _Py_dict_state {
0015     /*Global counter used to set ma_version_tag field of dictionary.
0016      * It is incremented each time that a dictionary is created and each
0017      * time that a dictionary is modified. */
0018     uint64_t global_version;
0019     uint32_t next_keys_version;
0020     PyDict_WatchCallback watchers[DICT_MAX_WATCHERS];
0021 };
0022 
0023 #define _dict_state_INIT \
0024     { \
0025         .next_keys_version = 2, \
0026     }
0027 
0028 
0029 #ifdef __cplusplus
0030 }
0031 #endif
0032 #endif   /* !Py_INTERNAL_DICT_STATE_H */