@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36



Comments:

<0> no - I'm pretty sure it's defined, as of perl 5.6
<1> and $_ is the default argument for many operations, including m//, s///, y///, print, pos, lc, uc, lcfirst. ucfirst, sin, cos, exp, log, abs, eval,
<0> it got "fixed"
<0> before 5.6 (from 2.0 to 5.5) it was just truth, yes.
<2> What's the difference though? <> in scalar context returns a line from the file, including the trailing linefeed...
<0> think of the last line of the file
<2> defined and [truth] should give the same test..
<0> it could be "0" without a newline
<0> and you can set $/ to "X", and then file containing 0X would also be false
<2> Ohh.. depending on fiddling with the variable that controls input separation..
<0> Oh scratch that
<2> Yeah.. that's true.
<0> no, just the other case
<0> last line contains just 0 without newline
<0> too early int he morning here. trying to wake up
<0> and apparently I have to teach today at YAPC and didn't know it



<1> merlyn: but it's almost ok, if you set $/ to 0 and the file contains 00, wouldn't that happen?
<0> so the caffiene is oging in quickly
<0> no beacuse $/ is include in the input
<0> oh wait yes
<0> you'd get a series of false lines. :)
<0> for 00000 you'd get 5 0's ina row!
<0> so yes, it has to be defined, not truth
<1> also, if $/ is set to undef (slurp) and you slurp an empty file, you get an empty string, but you probably don't use a while loop in that case
<3> Quick question - "foo" x 2 gives me a scalar which contains "foofoo", is there a similar way to get an array which contains "foo", "foo"?
<0> ("foo" x 2
<0> ("foo") x 2
<0> stupid hotel wifi :)
<3> Ah, great.
<3> Thanks very much, that seems obvious now you've pointed it iout.
<2> Much of perl is.. :)
<0> actually it's a special case on the syntax
<0> nothing expected about it
<1> I call it magical
<1> like eof() and eof
<0> or while(<>) { ... } :)
<0> yeay... episode 6 of geek cruises newses podcast is up. podcast.geekcruises.com
<4> I have a hash like this %hash = { "foo" => \&bar }; How can I call the function bar with this?
<2> $hash{foo}->();
<5> balony: Your hash is useless.
<5> balony: Use (), not {}, when ***igning to a pure hash.
<4> yeah, me mixing languages..
<6> balony if you want to ***ign like that use $hashref = {"foo" => \&bar}
<4> and I still do $hash{foo}->() ?
<1> no, $$hash{foo}->() in that case
<2> Yup... or ->( $args, $here )... if there are any
<1> I mean $$hashref{foo}->()
<6> or $hash->{foo}->{}
<6> oops
<6> $hash->{foo}->()
<4> thanks
<7> The insulting / remote insult works
<7> who wants to be insulted? ^_^
<8> BinGOs: Your birth was an unnatural... you came from a human being.
<9> BinGOs: there there
<7> ^_^
<7> okay that wasn't really an insult ...
<8> BinGOs: I heard you went to see the doctor and told him that you wanted a little wart removed; so he had you thrown out of his office.
<7> Lol
<10> heh
<7> Just kidding ;)
<10> oops
<9> anyone know what the meta key is by default on netBsd vt's?
<7> :p
<7> Anyway, I need think of some more functions to give my bot.
<7> It can even gracefully restart itself!
<7> Dazbot, restart
<8> Okay, restarting.
<3> Ah, bloat-led design ;)
<7> Oh, I know
<7> it doesn't react to privmsgs yet
<7> gotta do that too
<9> dazjorz: perhaps you could run him in a while true, with an eval, so to die is to restart
<9> and simply have it send itself a signal when it has to exit
<9> kill $$, TERM
<7> f00li5h: It can already restart :)



<7> Look in #perlbot
<7> it rejoined
<0> the birth of Yet Another Bot
<7> Yup :)
<9> merlyn: i for one think we need more bots
<7> but not Just A Bot, it's the Dazbot
<7> Welcome, Dazbot.
<7> I'll make it respond to msgs too
<0> Wait until I finish the Generic Yahoo Search bot!
<0> it will be my greatest achievement!
<9> merlyn: have a bot that trawls the whole internet on demand?
<7> I should check out Bot::BasicBot sometime - is it something?
<7> I saw it worked a lot like OOP thing
<10> f00li5h: CTRL-ALT-Fn
<9> BinGOs: thanks, but that's to switch, i want meta
<9> you know, the <> on a sun keyboard, or alt for a linux box
<10> I thought that was what you wanted.
<10> man wsdisplay
<9> BinGOs: that's why i appreciated the help
<9> BinGOs: ws display... right
<9> that's quite a long man page
<10> anyways.
<10> I have GLINE working in PoCo-Server-IRC
<10> \o/
<9> BinGOs: horray
<9> i don't find meta in the page anywhere, would it be called something else?
<10> since I got my test hybrid ircds not segfaulting whenever I issued a gline command =[
<6> what would be good way to check multiple options like this
<6> if($opt eq 'this' || $opt eq 'that' || $opt eq 'anotherone')
<0> that's a faq, jack
<0> perldoc -q contains
<0> that's not it
<0> something like that
<11> merlyn: Sounds complicated
<11> merlyn: and why on earth are you awake
<0> Why wouldn't I be?
<11> It's early pain
<0> I'm teaching in an hour, apparently
<11> Who the **** made the conference so early
<0> So I'm about to head out the door to look for the green
<9> BinGOs: help me over here, i can't even chat efficently wihtout the meta key
<11> merlyn: Are you doing any talks and stuff or just the cl***es?
<0> damn - should I take my 20d? I'm already packing a lot of gear.
<7> Dazbot restart
<8> Okay, restarting.
<9> merlyn: sure you should
<6> I am doing it like this for now if($opt =~ /^(this|that|anotherone)$/) but is there another way?
<0> well - I can bringit tomorrow
<0> I'll bring my pocket cam today
<0> realmerx - FAQ
<9> realmerx: that's not a fast way to do it
<10> f00li5h: I still don't get what you mean by 'meta key'
<9> BinGOs: alt
<0> see the FAQ pease
<7> ouch
<7> I can't invite people?
<7> :(
<6> merlyn: ok
<7> Dazbot restart
<7> oh he's not here
<12> realmerx: check out sub any in List::Util
<9> merlyn: if i have a linux shell, the alt is p***ed on, in the bsd shell, the alt key is used to produce `silly' characters
<0> perldoc -q contain
<9> s/merlyn/ BinGOs/
<0> Yeah, I was gonna say... :)
<9> merlyn: although, if you know how to send meta on a BSD vt, it'd be appreciated
<10> hang on, irssi ?
<0> "send meta"?
<10> heh
<11> merlyn: You never answered me =[
<9> merlyn: yes, the meta modifier, linux uses alt.
<9> BinGOs: yes!
<0> just utf8 your stdout, and print the chars
<0> buu - I'm teaching a cl***


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #perl
or
Go to some related logs:

#fluxbox
#suse
e1000 no ebuilds gentoo
fglrx xine crash X
novicat free
spt-get mysql ubuntu
adduser ipcop
#gentoo
hing fudges
gaim 2 apt-get install configure make install



Home  |  disclaimer  |  contact  |  submit quotes