4.036 Bug using $: and ^<<<~~ fields 
Author Message
 4.036 Bug using $: and ^<<<~~ fields

The following Perl script behaves unexpectedly under 4.036 (in several MS-DOS
ports and one SunOS port I have tried); The difficulty is coded away, it seems,
in Perl 5.0, but unfortunately, 5.0 is still too unstable in other ways for us
to utilize it.
   #!bin/perl
   format STDOUT=
   0123456789
   ^<<<<<<<<<~~
   $_
   .
   $: = '- ';  # Allow breaks after hyphens or spaces only
   while ( <> ) {
      write;
   }

If the above script is fed the line 'abc defghi- jkl', then the output will
be broken up improperly as follows:
    0123456789
    abc defghi
    - jkl
rather than as expected (and as when run under Perl 5.0):
    0123456789
    abc
    defghi-
    jkl

I should like to know if anyone who has ported Perl 4.036, or monkeyed around
with its source, knows where repairs of this wrapping problem may be effected,
or if anyone has already patched this problem.  It occurs ONLY when the break
character falls PRECISELY one column beyond the field's rightmost position,
and occurs regardless of the justification of the field.

If anyone has any comments about this problem, I'm anxious to hear them, and
please forgive my naivete if this is a well-known problem that more seasoned
Perl hackers have known about for ages.

Robert S. Kissel



Mon, 01 Jun 1998 03:00:00 GMT  
 4.036 Bug using $: and ^<<<~~ fields
 [courtesy cc of this posting sent to cited author via email]

In comp.lang.perl.misc,

:The following Perl script behaves unexpectedly under 4.036 (in several MS-DOS
:ports and one SunOS port I have tried);

We're not going to fix perl4 bugs.

:The difficulty is coded away, it seems,
:in Perl 5.0, but unfortunately, 5.0 is still too unstable in other ways for us
:to utilize it.

Name them.

--tom
--

        "There is no reason for any individual to have a computer in their
                 home."  (Ken Olson, President, Digital Equipment, 1977)



Tue, 02 Jun 1998 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. ^<<<<<<<<<<<~~ with \n

2. How can grep the 8th of Field <<<<<<<<

3. ^<<<<<<<<<<< ~~ format question

4. Using $: and ^<<<<~~~ in formatting

5. How can I make @<<<<<<<<< variable ?

6. Question on Cutting and Paste things in a File <<<<<<<<

7. <<<<<< HELP >>>>>>>>

8. format @<<<

9. >>>> A Singaporean Girl looking for more penpals!!<<<<<

10. program interaction using <<HERE docs

11. Using the print << command

12. >>>Please add your Perl Script to the Perlcoders Archive of free scripts <<<<

 

 
Powered by phpBB® Forum Software