正则表达式实例 -- 匹配Windows消息宏

时间:2014-08-10 21:30:00   收藏:0   阅读:285

Windows消息宏,定义在winuser.h里,消息编号从 0x0000 到 0x0400,下面给出一部分:

1 #define WM_NULL                         0x0000
2 #define WM_CREATE                       0x0001
3 #define WM_DESTROY                      0x0002
4 #define WM_MOVE                         0x0003
5 #define WM_SIZE                         0x0005

正则表达式:

1 #define (.+?) (0x[0-9a-fA-F]{1,4})

在线测试工具:

http://tool.chinaz.com/regex/

正则表达式实例 -- 匹配Windows消息宏,布布扣,bubuko.com

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!