[comp.lang.perl] g2p

rlk@think.com (Robert Krawitz) (04/10/91)

Is there a converter from gawk to perl?  I prefer using gawk to awk
because of functions and (particularly) because of multidimensional
arrays.
-- 
ames >>>>>>>>>  |	Robert Krawitz <rlk@think.com>	245 First St.
bloom-beacon >  |think!rlk	(postmaster)		Cambridge, MA  02142
harvard >>>>>>  .	Thinking Machines Corp.		(617)234-2116

tchrist@convex.COM (Tom Christiansen) (04/10/91)

From the keyboard of rlk@think.com (Robert Krawitz):
:Is there a converter from gawk to perl?  I prefer using gawk to awk
:because of functions and (particularly) because of multidimensional
:arrays.

a2p should work just fine.

--tom

purtill@morley.rutgers.edu (Mark Purtill) (04/11/91)

tchrist@convex.COM (Tom Christiansen) writes:
>From the keyboard of rlk@think.com (Robert Krawitz):
>:Is there a converter from gawk to perl?  I prefer using gawk to awk
>:because of functions and (particularly) because of multidimensional
>:arrays.
>a2p should work just fine.

	Well, not quite.  gawk has a different command line convension
for reading variables (`-v A=B' rather than just `A=B') and a2p
doesn't know about gawk's special "/dev/std..." files, so it tries to
open "/dev/stderr" and so on.  Easy to fix by hand, tho. (This is the
a2p with perl 3.0 patch-level 41).

^.-.^ Mark Purtill         purtill@dimacs.rutgers.edu         (908)932-4580 (O)
((")) DIMACS, P.O. Box 1179, Rutgers U., Piscataway, NJ 08855 (908)220-6905 (H)
********** Note new area code!  We are now (908) rather than (201)!  **********

rlk@think.com (Robert Krawitz) (04/11/91)

In article <1991Apr09.193024.19792@convex.com>, tchrist@convex (Tom Christiansen) writes:
]From the keyboard of rlk@think.com (Robert Krawitz):
]:Is there a converter from gawk to perl?  I prefer using gawk to awk
]:because of functions and (particularly) because of multidimensional
]:arrays.
]
]a2p should work just fine.

No, it blew up on a function (subroutine) definition.
-- 
ames >>>>>>>>>  |	Robert Krawitz <rlk@think.com>	245 First St.
bloom-beacon >  |think!rlk	(postmaster)		Cambridge, MA  02142
harvard >>>>>>  .	Thinking Machines Corp.		(617)234-2116

tchrist@convex.COM (Tom Christiansen) (04/11/91)

From the keyboard of rlk@think.com (Robert Krawitz):
:]a2p should work just fine.
:
:No, it blew up on a function (subroutine) definition.

Sounds like a bug.

--tom