2 ''' $RCSfile: s2p.man,v $$Revision: 4.1 $$Date: 92/08/07 18:29:24 $
23 ''' Set up \*(-- to give an unbreakable dash;
24 ''' string Tr holds user defined translation string.
25 ''' Bell System Logo is used as a dummy character.
30 .if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
31 .if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
47 s2p - Sed to Perl translator
49 .B s2p [options] filename
52 takes a sed script specified on the command line (or from standard input)
53 and produces a comparable
55 script on the standard output.
63 specifies that this sed script was always invoked with a sed -n.
64 Otherwise a switch parser is prepended to the front of the script.
67 specifies that this sed script was never invoked with a sed -n.
68 Otherwise a switch parser is prepended to the front of the script.
70 The perl script produced looks very sed-ish, and there may very well be
71 better ways to express what you want to do in perl.
72 For instance, s2p does not make any use of the split operator, but you might
75 The perl script you end up with may be either faster or slower than the original
77 If you're only interested in speed you'll just have to try it both ways.
78 Of course, if you want to do something sed doesn't do, you have no choice.
79 It's often possible to speed up the perl script by various methods, such
80 as deleting all references to $\e and chop.
82 S2p uses no environment variables.
84 Larry Wall <lwall@jpl-devvax.Jpl.Nasa.Gov>
87 perl The perl compiler/interpreter
89 a2p awk to perl translator