例1:
\{ 和 \} 分别代表 { 和 }
[^
\{\}
]匹配 除了 { 和 } 之外的一个字符
* 尽可能多得匹配它前面的那种字符,至少匹配0个
+ 尽可能多得匹配它前面的那种字符,至少匹配1个
这样合起来:
\{[^\{\}]*\} 匹配最里层的花括号
例2:
\( 和 \) 分别代表 ( 和 )
. 匹配任意一个字符
*?
Zero or more of the previous group, but minimally: the shortest matching string, rather than the longest string as with the "greedy" * operator. Thus, m.*?o applied to the text margin-bottom: 0; will match margin-bo, whereas m.*o will match margin-botto.
则 \(typedef_.*?; 匹配(一次匹配一个)
(typedef_XXXFunctionPtr)GetProcAddress(DllHandle, "XXXFunction");
(typedef_YYYFunctionPtr)GetProcAddress(DllHandle, "YYYFunction");