Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: The most annoying common way to get a string literal in Perl is...

by beppu (Hermit)
on Jul 05, 2004 at 13:28 UTC ( [id://371872]=note: print w/replies, xml ) Need Help??


in reply to The most annoying common way to get a string literal in Perl is...

I don't get the difference between "here doc" and 'there doc' except that one uses double quotes for the terminator and the other uses single quotes. (Is that the only difference or is there something more subtle to be aware of?)
  • Comment on Re: The most annoying common way to get a string literal in Perl is...

Replies are listed 'Best First'.
Re^2: The most annoying common way to get a string literal in Perl is... (the "t")
by tye (Sage) on Jul 07, 2004 at 01:32 UTC

    Same as the difference between 'single' and "double": one interprets and one doesn't. Though <<'there docs' are unique in Perl for never treating \ as anything other than just \.

    If you thought "there doc" was some official term, then perhaps you didn't notice that most of the names used aren't names you'll find often used (never in the standard docs, for example).

    - tye        

Re^2: The most annoying common way to get a string literal in Perl is...
by hardburn (Abbot) on Jul 06, 2004 at 21:17 UTC

    Both examples are really "here" docs. The poll author was just being silly.

    ----
    send money to your kernel via the boot loader.. This and more wisdom available from Markov Hardburn.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://371872]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2024-04-20 00:43 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found