cmake-parser: improve portability

This commit is contained in:
Přemysl Eric Janouch 2024-12-31 06:42:51 +01:00
parent 1930f138d4
commit 7560e8700e
Signed by: p
GPG Key ID: A0420B94F92B9493

View File

@ -75,7 +75,7 @@ function line_ending() {
# it doesn't seem to be worth the effort.
function expand(s, v) {
v = s
while (match(v, /\\*[$](|ENV|CACHE)[{]/)) {
while (match(v, /\\*[$](ENV|CACHE)?[{]/)) {
if (index(substr(v, RSTART), "$") % 2 != 0) {
warning("variable expansion is not supported: " s)
return s