Commit 08aa87fb authored by Peter Berg Larsen's avatar Peter Berg Larsen Committed by Alexandre Julliard

Currently a '//****' is matched as an /* comment - disallow a '/' in

front of the '/*' match. An 'extern "C" {' can be split in several lines - allow '\n' as space, and lookout for the rest if partial found.
parent 6beae245
......@@ -75,7 +75,7 @@ foreach my $file (@files) {
}
# remove C comments
if(s/^(.*?)(\/\*.*?\*\/)(.*)$/$1 $3/s) {
if(s/^(|.*?[^\/])(\/\*.*?\*\/)(.*)$/$1 $3/s) {
$again = 1;
next;
} elsif(/^(.*?)\/\*/s) {
......@@ -101,10 +101,13 @@ foreach my $file (@files) {
}
# Remove extern "C"
if(s/^\s*extern\s+"C"\s+\{//m) {
if(s/^\s*extern[\s\n]+"C"[\s\n]+\{//m) {
$extern_c = 1;
$again = 1;
next;
} elsif(m/^\s*extern[\s\n]+"C"/m) {
$lookahead = 1;
next;
}
if($level > 0)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment