int parse_ulong(const char *str, unsigned long *ul);
int parse_ullong(const char *str, unsigned long long *ul);
int parse_ulong(const char *str, unsigned long *ul);
int parse_ullong(const char *str, unsigned long long *ul);
-#define DEFINE_PARSE_ULONG(name, type, max) \
+#define DEFINE_PARSE_NUM_WRAP(name, type, max, functype, funcname) \
+
+#define DEFINE_PARSE_ULONG(name, type, max) \
+ DEFINE_PARSE_NUM_WRAP(name, type, max, unsigned long, _ulong)
DEFINE_PARSE_ULONG(uint, unsigned, UINT_MAX)
DEFINE_PARSE_ULONG(u32, uint32_t, UINT32_MAX)
DEFINE_PARSE_ULONG(u16, uint16_t, UINT16_MAX)
DEFINE_PARSE_ULONG(u8, uint8_t, UINT8_MAX)
DEFINE_PARSE_ULONG(uint, unsigned, UINT_MAX)
DEFINE_PARSE_ULONG(u32, uint32_t, UINT32_MAX)
DEFINE_PARSE_ULONG(u16, uint16_t, UINT16_MAX)
DEFINE_PARSE_ULONG(u8, uint8_t, UINT8_MAX)