develooper Front page | perl.perl6.language | Postings from August 2001

Qouting and white-space etc..

Thread Next
From:
raptor
Date:
August 15, 2001 04:36
Subject:
Qouting and white-space etc..
Message ID:
000701c1256d$c231a160$0500a8c0@xxx
hi,

I was wondering if there was some way when using qouting to specify triming
of white space or other type of charachters we may need ... say like TT or
may be ...one example..


my $javascripCode = qq{
    |<script>
    |    function blah()

    |        if ( ) ....
    |    };
    |</script>
};

    |<-inner spaces/tabs preserved

and I want to have some syntax so I can specify that First and Last "\n" be
removed, plus the whole script body goes one tab to left... i.e. removed
first X \t (the number of tabs/spaces removed depends on the position of
<script>, u gottcha)
Yes I know I can use regex...

Similar like :
<snip Perl6-notes>
Here docs
. RFC 111: Here doc Terminators
. RFC 162: Here doc contents
. Whitespace no longer significant before here doc identifier
. Whitespace no longer significant before or after here doc
terminator (nor are semicolons)
. Identifier must be quoted
. Here doc contents left-shifted according to whitespace before
terminator
.... example....
</snip>

but inner space/tabs are preserved..
=====
iVAN
raptor@unacs.bg
=====


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About