This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[libgo PATCH 1/1] mksyscalls.awk: make split ERE more portable


awk's split() ERE was splitting on (essentially) .
Double checked with mawk 1.3.3, GNU Awk 4.0.1, busybox awk
that they still produce identical output.

libgo/ChangeLog (???)

2013-08-01  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>

	* go/syscall/mksyscall.awk (split): Fix ere argument.

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
---
 libgo/go/syscall/mksyscall.awk |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libgo/go/syscall/mksyscall.awk b/libgo/go/syscall/mksyscall.awk
index 74f0e28..829b6fe 100644
--- a/libgo/go/syscall/mksyscall.awk
+++ b/libgo/go/syscall/mksyscall.awk
@@ -53,7 +53,7 @@ BEGIN {
     }
 
     # Sets a[1] = //sysnb, a[2] == function name.
-    split(line, a, "[ 	(]*")
+    split(line, a, "[ 	(]")
     gofnname = a[2]
 
     off = match(line, "\\([^()]*\\)")
@@ -78,7 +78,7 @@ BEGIN {
 	next
     }
 
-    split(line, a, "[ 	(]*")
+    split(line, a, "[ 	(]")
     cfnname = substr(a[1], 3, length(a[1]) - 2)
 
     off = match(line, "\\([^()]*\\)")
-- 
1.7.10.4


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]