mirror of https://gitlab.com/ita1024/waf.git
re_cpp matches are never empty
This commit is contained in:
parent
51b68cf13b
commit
6579592065
|
@ -1,7 +1,11 @@
|
||||||
|
|
||||||
#if A
|
#if A
|
||||||
|
const char* c = "foo /*";
|
||||||
#if B
|
#if B
|
||||||
|
const char* d = " bar */";
|
||||||
|
// /*
|
||||||
#if C
|
#if C
|
||||||
|
// */
|
||||||
#include "a.h"
|
#include "a.h"
|
||||||
#else
|
#else
|
||||||
#include "b.h"
|
#include "b.h"
|
||||||
|
|
|
@ -138,7 +138,7 @@ skipped = 's'
|
||||||
def repl(m):
|
def repl(m):
|
||||||
"""Replace function used with :py:attr:`waflib.Tools.c_preproc.re_cpp`"""
|
"""Replace function used with :py:attr:`waflib.Tools.c_preproc.re_cpp`"""
|
||||||
s = m.group(0)
|
s = m.group(0)
|
||||||
if s.startswith('/'):
|
if s[0] == '/':
|
||||||
return ' '
|
return ' '
|
||||||
return s
|
return s
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue