NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: PR/36394 CVS commit: src/dist/nawk



 >> > You're absolutely correct.  However, one out of two isn't all bad
 >> > either, as "n" can never go negative. :-)
 >> I know, I know, this was my fault.
 >> I said "especially for this" for this fix exactly ;)

> Heh, OK.

> If you have anything to add to the minimal regression tests I
> committed, we're receptive to it.

> It should be OK to close the PR now?

Patch follows (setting LANG doesn't work properly on NetBSD-4,
so, I've changed it to LC_CTYPE).
It contains cyrillic (actually Russian) text.
As I already said everything works fine for me and this PR can be clsed.

Index: regress/usr.bin/awk/tolower/Makefile
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/tolower/Makefile,v
retrieving revision 1.1
diff -u -r1.1 Makefile
--- regress/usr.bin/awk/tolower/Makefile        25 Oct 2007 14:51:18 -0000      
1.1
+++ regress/usr.bin/awk/tolower/Makefile        3 Apr 2008 18:50:15 -0000
@@ -7,7 +7,7 @@
 CLEANFILES=    result
 
 regress:
-       env LANG=en_US.UTF-8 \
+       env LC_CTYPE=en_US.UTF-8 \
                ${AWK} -f ${.CURDIR}/test.awk ${.CURDIR}/input > result
        @cmp ${.CURDIR}/expected result
 
Index: regress/usr.bin/awk/tolower/expected
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/tolower/expected,v
retrieving revision 1.1
diff -u -r1.1 expected
--- regress/usr.bin/awk/tolower/expected        25 Oct 2007 14:51:18 -0000      
1.1
+++ regress/usr.bin/awk/tolower/expected        3 Apr 2008 18:50:15 -0000
@@ -1 +1,2 @@
 abcæøå
+привет всем разработчикам netbsd!
Index: regress/usr.bin/awk/tolower/input
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/tolower/input,v
retrieving revision 1.1
diff -u -r1.1 input
--- regress/usr.bin/awk/tolower/input   25 Oct 2007 14:51:18 -0000      1.1
+++ regress/usr.bin/awk/tolower/input   3 Apr 2008 18:50:15 -0000
@@ -1 +1,2 @@
 ABCÆØÅ
+Привет всем разработчикам NetBSD!
Index: regress/usr.bin/awk/tolower/test.awk
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/tolower/test.awk,v
retrieving revision 1.1
diff -u -r1.1 test.awk
--- regress/usr.bin/awk/tolower/test.awk        25 Oct 2007 14:51:18 -0000      
1.1
+++ regress/usr.bin/awk/tolower/test.awk        3 Apr 2008 18:50:15 -0000
@@ -1,5 +1,5 @@
 # $Id: test.awk,v 1.1 2007/10/25 14:51:18 he Exp $
 
-END {
+{
        print tolower($0);
 }
Index: regress/usr.bin/awk/toupper/Makefile
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/toupper/Makefile,v
retrieving revision 1.1
diff -u -r1.1 Makefile
--- regress/usr.bin/awk/toupper/Makefile        25 Oct 2007 14:51:19 -0000      
1.1
+++ regress/usr.bin/awk/toupper/Makefile        3 Apr 2008 18:50:15 -0000
@@ -7,7 +7,7 @@
 CLEANFILES=    result
 
 regress:
-       env LANG=en_US.UTF-8 \
+       env LC_CTYPE=en_US.UTF-8 \
                ${AWK} -f ${.CURDIR}/test.awk ${.CURDIR}/input > result
        @cmp ${.CURDIR}/expected result
 
Index: regress/usr.bin/awk/toupper/expected
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/toupper/expected,v
retrieving revision 1.1
diff -u -r1.1 expected
--- regress/usr.bin/awk/toupper/expected        25 Oct 2007 14:51:19 -0000      
1.1
+++ regress/usr.bin/awk/toupper/expected        3 Apr 2008 18:50:15 -0000
@@ -1 +1,2 @@
 ABCÆØÅ
+ПРИВЕТ ВСЕМ РАЗРАБОТЧИКАМ NETBSD!
Index: regress/usr.bin/awk/toupper/input
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/toupper/input,v
retrieving revision 1.1
diff -u -r1.1 input
--- regress/usr.bin/awk/toupper/input   25 Oct 2007 14:51:19 -0000      1.1
+++ regress/usr.bin/awk/toupper/input   3 Apr 2008 18:50:15 -0000
@@ -1 +1,2 @@
 abcæøå
+Привет всем разработчикам NetBSD!
Index: regress/usr.bin/awk/toupper/test.awk
===================================================================
RCS file: /pub/NetBSD-CVS/src/regress/usr.bin/awk/toupper/test.awk,v
retrieving revision 1.1
diff -u -r1.1 test.awk
--- regress/usr.bin/awk/toupper/test.awk        25 Oct 2007 14:51:19 -0000      
1.1
+++ regress/usr.bin/awk/toupper/test.awk        3 Apr 2008 18:50:15 -0000
@@ -1,5 +1,5 @@
 # $Id: test.awk,v 1.1 2007/10/25 14:51:19 he Exp $
 
-END {
+{
        print toupper($0);
 }
-- 
Best regards, Aleksey Cheusov.


Home | Main Index | Thread Index | Old Index