Re: Emergency Social: Sunday 9th August

2009-08-05 Thread Dave Cross

On 03/08/09 22:39, James Laver wrote:

On Mon, Aug 3, 2009 at 6:56 PM, Dave Crossd...@dave.org.uk  wrote:

As previously discussed, David Adler will be passing through London on his
way home this weekend. Having spoken to him in Lisbon today we've decided
that the best approach is just to tell you all where to be and when.

So an executive decision was made and we'll be in the Anchor, Bankside from
about 2pm on Sunday.

  http://london.randomness.org.uk/wiki.cgi?Anchor%2C_SE1_9EF

Hope to see you there.


Last I was there, I ended up drinking strongbow because I couldn't
stand to drink their awful, awful beer.

I suggest moving it further along to either the founders, the bridge
house, or slightly further away, the miller.


Ok, as you asked so nicely, we'll go to the Founders Arms instead. All 
other details remain unchanged.


Dave...


Re: [Gllug-Social] [ANNOUNCE] Reminder: London.pm social meet, Thursday evening

2009-08-05 Thread David Cantrell
On Tue, Aug 04, 2009 at 05:47:32PM +0100, Joel Bernstein wrote:
 On 4 Aug 2009, at 15:42, David Cantrell wrote:
 The Glorious Leader is, however, in Lisbon.
 Naively I assumed that somebody would don an orange t-shirt for the  
 evening and play acting leader.

The orange T-shirt I still have from YAPC::Europe 19100 is, umm,
unflatteringly tight now.  It would be nice if someone who's getting to
the Founders' Arms early had something perlish with them to help the
GLLUG visitors find us.  I won't be there until something like 7
o'clock.

-- 
David Cantrell | Enforcer, South London Linguistic Massive

EINE KIRCHE! EIN KREDO! EIN PAPST!


Re: [Gllug-Social] [ANNOUNCE] Reminder: London.pm social meet, Thursday evening

2009-08-05 Thread Smylers
David Cantrell writes:

 On Tue, Aug 04, 2009 at 03:11:38PM +0100, Joel Bernstein wrote:
 
  You should go along, it's absolutely not a requirement to have  
  anything really to do with Perl. In fact, there's a nice tradition  
  that new people are bought a beer by the London.pm leader and  
  introduced to people to talk to. Hope you have fun.
 
 The Glorious Leader is, however, in Lisbon.

I am currently in Lisbon with your Glorious Leader and will also be in
London tomorrow evening.

The Glorious Leader is welcome to hand me some money to take to the
meeting.

Smylers


Sub-refs in @INC screwing with your modules

2009-08-05 Thread David Cantrell
As part of an Evil Plan, I am putting a sub-ref into @INC that will
screw around with modules as they're loaded.  Or at least, I'm trying
to.  I can't seem to get this to work:

perl -MIO::Scalar -e '
unshift @INC, sub {
print q{wibble};
return IO::Scalar-new(\q{print q{wobble}})
};
eval use foo
'

which *should*, if I've RTFM correctly, print wibblewobble.  But the
wobble never appears.  What am I doing wrong?

-- 
David Cantrell | Hero of the Information Age

  Sobol's Law of Telecom Utilities:
Telcos are malicious; cablecos are simply clueless.


Re: Sub-refs in @INC screwing with your modules

2009-08-05 Thread Uri Guttman
 DC == David Cantrell da...@cantrell.org.uk writes:

  DC As part of an Evil Plan, I am putting a sub-ref into @INC that will
  DC screw around with modules as they're loaded.  Or at least, I'm trying
  DC to.  I can't seem to get this to work:

  DC perl -MIO::Scalar -e '
  DC unshift @INC, sub {
  DC print q{wibble};
  DC return IO::Scalar-new(\q{print q{wobble}})
  DC };
  DC eval use foo
  DC '

  DC which *should*, if I've RTFM correctly, print wibblewobble.  But the
  DC wobble never appears.  What am I doing wrong?

this works:

 perl -le 'open my $fh, q{}, \q{print q{bar}}; unshift @INC, sub {print 
q{foo}; $fh }; require baz'
foo
bar

i tried putting the open inside the sub and i get this error:

perl -le 'unshift @INC, sub {print q{foo}; open my $fh, q{}, \q{bar}; $fh }; 
require bar'
foo
foo
Recursive call to Perl_load_module in PerlIO_find_layer at -e line 1.
BEGIN failed--compilation aborted.

why would it recurse on the sub in @INC? it prints foo twice which shows
that.

uri

-- 
Uri Guttman  --  u...@stemsystems.com    http://www.sysarch.com --
-  Perl Code Review , Architecture, Development, Training, Support --
- Free Perl Training --- http://perlhunter.com/college.html -
-  Gourmet Hot Cocoa Mix    http://bestfriendscocoa.com -


Re: Sub-refs in @INC screwing with your modules

2009-08-05 Thread Adriano Ferreira
On Wed, Aug 5, 2009 at 4:48 PM, David Cantrell da...@cantrell.org.ukwrote:

 As part of an Evil Plan, I am putting a sub-ref into @INC that will
 screw around with modules as they're loaded.  Or at least, I'm trying
 to.  I can't seem to get this to work:

 perl -MIO::Scalar -e '
unshift @INC, sub {
print q{wibble};
return IO::Scalar-new(\q{print q{wobble}})
};
eval use foo
 '


I don't remember the details if I tried to use IO::Scalar/IO::String to do a
similar thing in Devel::Hide and couldn't (or if I just got lazy), but the
fact is that the current Devel::Hide code uses in-memory handles (which we
got withopen(my $io, '', \$string)  for Perl 5.8+) and File::Temp for
older perls.

Best,
Adriano



 which *should*, if I've RTFM correctly, print wibblewobble.  But the
 wobble never appears.  What am I doing wrong?

 --
 David Cantrell | Hero of the Information Age

  Sobol's Law of Telecom Utilities:
Telcos are malicious; cablecos are simply clueless.