| |
| |
| |
|
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 37 38 39 40
Comments:
<0> buu: You can bless into an empty package, I dunno about making a package variable too <1> revdiablo: I'm trying to hard <0> Maybe you can use \0 to do it. <1> Er, so <2> evil <1> eval: *x{PACKAGE}; <3> buu: Return: main <1> eval: *x{PACKAGE} = ''; <3> buu: Error: Can't modify glob elem in scalar ***ignment at (eval 135) line 1, at EOF <1> Hacks and lies. <0> buu: Err, what exactly are you trying to do? <0> I mean what do you expect that code to do? <1> Null package tables! <1> I want a package name of '' <1> eval: *{main}{x} = 1 <3> buu: Error: Can't modify glob elem in scalar ***ignment at (eval 135) line 2, at EOF
<4> eval: package undef;1; <3> Supaplex: Return: 1 <1> eval: *{main}{x} = \1 <3> buu: Error: Can't modify glob elem in scalar ***ignment at (eval 135) line 2, at EOF <0> eval: *{"\0::x"}{PACKAGE} <3> revdiablo: Return: main <0> Dang <0> eval: *{"foo\0bar::x"}{PACKAGE} <3> revdiablo: Return: main <0> eval: $foo=1; $*{"foo\0bar::x"}{PACKAGE} <3> revdiablo: Return: <1> I'm suspecting that perl is going to internally magic <0> eval: $foo=1; ${*{"foo\0bar::x"}} <3> revdiablo: Return: 1 <0> Heh <0> Eat \0! <1> Yeah <2> so \0 = "at joe's"? <0> pravus: Looks like it stops reading at the \0 <0> See I'm setting $foo, and accessing "foo\0bar::x", but it gives me the value I set to $foo <0> eval: $foo=5; ${*{"foo\0bar::x"}} <3> revdiablo: Return: 5 <0> eval: $foo=5; ${"foo\0bar::x"} <3> revdiablo: Return: 5 <2> kind of odd <1> Yeah <0> Perl's written in C after all <4> a snippet for the perl obsification contest! <2> yeah, i guess not <1> Yay C! <2> it would change \0 into nul and then p*** it to some str* function <1> I'm so going to use _$_ in my next perl code <4> eval: _$_ <3> Supaplex: Error: Can't call method "_" on unblessed reference at (eval 135) line 1. <2> the horror <1> Yes. <1> eval: sub _ { cock() } _$_ <3> buu: Error: Undefined subroutine &main::cock called at (eval 135) line 1. <1> Hrm <0> eval: sub _ { 5 } _$_ <3> revdiablo: Return: 5 <0> That's nice <2> did you expect cock() to be defined? <4> :) <0> eval: $_ = 5; sub _ { $_[1] } _$_ <3> revdiablo: Return: <0> eval: $_ = 5; sub _ { $_[0] } _$_ <3> revdiablo: Return: 5 <4> he was daydreaming, thinking it was loaded already <0> eval: $_ = 5; sub _ { $_[1] } _$_(9) <3> revdiablo: Error: syntax error at (eval 135) line 1, near "$_(" <0> Dang <1> Supaplex: I ALWAYS define THE COCK <1> revdiablo: Woah, that didn't work? <1> oh <5> i suppse thats better than splitting the cock <6> I like the style of the perlintro manpage. Is there a way to browse all the manpages (without having to select each one), for example as a single pdf/ps/dvi/html document? <1> useruser_: perltoc and perl; have lists <6> buu: yeah, I want them all catted together in an enourmous document so I can search them easily... preferably with hyperlinks <1> TOO BAD <6> :(
<1> perldoc has searching utilities <7> buu, turn that wc3 up! :P <4> PAGER=cat;find `perl -e 'print join("\n",@INC,"")' | grep ^/` -type f | sort | uniq | while read r ; do perldoc $r; done | tee all-perl-docs.txt 2>/dev/null <1> Amnesiac: whose line > You <7> :/ <6> Supaplex: yeah, i was just thinking along those lines <6> Supaplex: but i was starting with man perltoc | grep '^ {,9}perl' | ... <4> :) <8> hello.. I am trying to print some status messages from a script on to the screen.. however these do not display on screen unless there is a "\n" included.. what can I do to get these to display as they are called, rather than waiting for the first "\n".. any pointers ?? <9> TheRAt: you'll want to turn off buffering on STDOUT <9> perlbot suffering from buffering <10> http://perl.plover.com/FAQs/Buffering.html <9> perlbot paste <10> Paste your code and #perl will be able to view it: http://sial.org/pbot/perl http://dragon.cbi.tamucc.edu:8080 http://erxz.com/pb <8> simcop2387: thanks :) <9> TheRAt: its a fairly common question :) <11> simcop2387: that's a good article on buffering, thank you <9> malchias: no problem, didn't know you were after one <11> I wasn't <9> heh <11> but I didn't know exactly how buffering worked :) <12> how can i get an archive from the internet using perl? <9> Smurf-BR: LWP <12> someone told me that the command is that; perl -e "use LWP: simple; print(get('url/archive'))" > archive <12> but will not <12> simcop2387 can u say me the full command? <1> HEY <1> IT WILL <1> kthx <13> "simcop2387" at 24.74.93.98 pasted "Does this error make any sense to anyone? Error at bottom, code at top" (128 lines, 3.7K) at http://sial.org/pbot/16073 <9> Smurf-BR: honestly i'm not sure how to use it, i haven't used it alot <12> hm <12> simcop2387 u know anybody that can help me with this? <14> ATCHUNG I have refried beans I made myself. <9> Smurf-BR: someone in here probably, could also read the documentation for it too <9> perldoc LWP <12> uhum <9> buubot: hello? <9> perlbot cpan LWP <15> ?Is it possible to "use strict;" and be able to use variable references as well... I'm trying to construct a variable name, then use it in a ${$constructed_name} --- If $constructed_name = \$foo, and I've "my $foo", I still get "Can't use string...as a SCALAR ref..." <10> Documentation for 'LWP' can be found here: http://xrl.us/j8jv <9> Smurf-BR: there use that link <12> yeah im going <9> yukonbob: well first think about why you need softrefs, and will eval work for you? if you really need them then you can turn off strict for softrefs inside that block by doing {no strict 'softrefs'; ...code that uses softrefs...} and encapsulate ONLY the code that directly uses softrefs in there so that strict is working everywhere else <15> simcop2387: thanks for those --- I'll try :) <12> simcop2387 i have problems with the english because im brazilian huuh <9> Smurf-BR: no problem <16> SOFTREF IS STUPID NEVER THE RIGHT ANSWER <9> sili: some people (like integral) insist on using them <16> simcop2387: integral is a noob <16> simcop2387: for what reason? they're stupid <12> i couldnt understand very well what i saw at the url simcop2387 <12> :\ <15> sili_: so you're saying there's never a case for using softrefs, and there's always a better way? <1> There's one <16> yukonbob: that's usually the case. <9> Smurf-BR: ah <17> yukonbob: until you reach a certain level of mastery, that's the case. <9> Smurf-BR: why are you wanting to use perl to do this anyway, why not use wget or some other utility for downloading a file on a command line? wget http://www.example.com/foo/bar/example.zip <9> Smurf-BR: i'm guessing you are using a *nix Operating system for that <5> do I have to use the following to initialize a hash ref that will be p***ed to subs: my $hashref=>{ 'whatever'} = $something; <5> or is there a different way? <16> rabeldable: that's invalid syntax <12> the machine doesnt have wget, curl, GET, lynx, links :O <1> rabeldable: {} <5> = {}; ?? <16> my $hashref = {foo => 1, bar => 2, omglearnperl => 9999999999}; foo($hashref); <9> Smurf-BR: thats really strange <12> huh <9> Smurf-BR: complain to the sysadmin :) <9> PerlJam: i've almost reached that level of mastery, almost <12> :| <5> whats foo($hashref); I'm confused because you used foo as a key in the hash <16> on the lhs of =>
Return to
#perl or Go to some related
logs:
#freedesktop gumby netstorm lebanis model python __getatt__ #lisp i868 gcc #gentoo #kde linux repodata explain gentoo invalid token profile.env
|
|