From 27ec22668ffe96569b1860008e398d29f08ebd6c Mon Sep 17 00:00:00 2001 From: Jakub Jelinek Date: Mon, 12 Dec 2016 23:01:41 +0100 Subject: [PATCH] re PR other/78766 (GCC Awk scripts use the non-POSIX /^{/ regex) PR other/78766 * opt-functions.awk (opt_args): Use [{] instead of { in regexps. Formatting fix. From-SVN: r243583 --- gcc/ChangeLog | 6 ++++++ gcc/opt-functions.awk | 6 +++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index efc8bdd5b85..50a9cf75376 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2016-12-12 Jakub Jelinek + + PR other/78766 + * opt-functions.awk (opt_args): Use [{] instead of { in regexps. + Formatting fix. + 2016-12-12 Martin Sebor PR middle-end/78622 diff --git a/gcc/opt-functions.awk b/gcc/opt-functions.awk index 7cf50256558..43e223c3cc7 100644 --- a/gcc/opt-functions.awk +++ b/gcc/opt-functions.awk @@ -61,10 +61,10 @@ function opt_args(name, flags) if (flags !~ " " name "\\(") return "" sub(".* " name "\\(", "", flags) - if (flags ~ "^{") + if (flags ~ "^[{]") { - sub ("^{", "", flags) - sub("}\\).*", "", flags) + sub ("^[{]", "", flags) + sub ("}\\).*", "", flags) } else sub("\\).*", "", flags) -- 2.30.2