mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2025-02-02 10:31:02 +00:00
ECDH: Add #ifdef filter to tests/scripts/list-enum-consts.pl
This allows the use of #ifdef ... #endif in enum definitions (e.g., mbedtls_ecdh_variant in ecdh.h).
This commit is contained in:
parent
0bc9c693ce
commit
e0e8eb3114
|
@ -22,7 +22,7 @@ while (<>)
|
||||||
$state = 'in';
|
$state = 'in';
|
||||||
} elsif( $state eq 'in' and /}/ ) {
|
} elsif( $state eq 'in' and /}/ ) {
|
||||||
$state = 'out';
|
$state = 'out';
|
||||||
} elsif( $state eq 'in' ) {
|
} elsif( $state eq 'in' and not (/^#if/ or /#endif/)) {
|
||||||
s/=.*//; s!/\*.*!!; s/,.*//; s/\s+//g; chomp;
|
s/=.*//; s!/\*.*!!; s/,.*//; s/\s+//g; chomp;
|
||||||
push @consts, $_ if $_;
|
push @consts, $_ if $_;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue