Some perl modules I intend to CPANise

2006-06-29 Thread Paul LeoNerd Evans
be doing in the right direction, or what. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Perl module layout - File::StatCache

2006-07-12 Thread Paul LeoNerd Evans
ule, so the timeouts can suddenly become very large, and the kernel will efficiently inform the program whenever a file changes, rather than the module needing to be checked. This would be of benefit to the read cache as much as the stat cache. -- Paul "LeoNerd" Evans

Re: Perl module layout - File::StatCache

2006-07-16 Thread Paul LeoNerd Evans
is one right... Any more comments from anyone on new version 0.02? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Perl module layout - File::StatCache

2006-07-17 Thread Paul LeoNerd Evans
k as, say, =head3 entries perhaps.. Would that be better? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Test strategy for network IO code

2006-07-18 Thread Paul LeoNerd Evans
nt, but is more complicated, and could break in all other sorts of nasty ways. If anyone has any thoughts on this, I'd appreciate hearing it -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: Test strategy for network IO code

2006-07-24 Thread Paul LeoNerd Evans
; print "And then I send this response\n" } ); Then read and write the handles, and check the child's exit status... I suppose that could be done.. but if I'm doing that, it almost seems just as easy to pipe()/fork() myself anyway. Keeps all the code in the file itself then,

Re: Test strategy for network IO code

2006-07-24 Thread Paul LeoNerd Evans
erated, and the responses are interpreted correctly. Then a smaller set of tests at the end to just ensure that the handle-based IO works. I'm starting to like that idea; though it does still need some test of handle IO... -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 41

Re: Perl module layout - File::StatCache

2006-07-24 Thread Paul LeoNerd Evans
; ); Complete with caching, and checking for changes based on the stat cache. Should this module go here with File::StatCache, or in its own distribution? I don't know how expensive these things are - is it worth having a whole new distribution for one module, or is it best to put them togeth

New module File::SlurpCache - new CPAN distro or merge in existing?

2006-07-26 Thread Paul LeoNerd Evans
ne, as they are likely to be used together Any advice / precident either way? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: New module File::SlurpCache - new CPAN distro or merge in existing?

2006-07-28 Thread Paul LeoNerd Evans
ving a function to return the contents in a bare string cached in memory is a lot faster than bothering the OS with a complete open/read/close cycle. Though ovbviously its use in large files that are rarely accessed is likely to be of little benefit. -- Paul "LeoNerd" Evans [EMAIL PROTECTED]

[EMAIL PROTECTED] mail addresses

2006-08-20 Thread Paul LeoNerd Evans
ks ago, and still nothing. Does anyone know if there's anything else I need to do, or who else I might need to ask about it? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: [EMAIL PROTECTED] mail addresses

2006-08-20 Thread Paul LeoNerd Evans
ceived: from post.hexten.net (HELO post.hexten.net) (65.254.52.58) > by la.mx.develooper.com (qpsmtpd/0.28) with ESMTP; Sun, 20 Aug > 2006 16:13:49 -0700 > > So it /is/ just you :) Hrm... Any suggestions on who I should ask about this? Who maintains the mailer there? -- Paul &

Re: [EMAIL PROTECTED] mail addresses

2006-08-21 Thread Paul LeoNerd Evans
On Mon, 21 Aug 2006 11:21:59 +0200 Johan Vromans <[EMAIL PROTECTED]> wrote: > Paul LeoNerd Evans <[EMAIL PROTECTED]> writes: > > > Any suggestions on who I should ask about this? > > According to the PAUSE administration, everything is set up as it > should. >

Manipulating Time::HiRes values

2006-10-30 Thread Paul LeoNerd Evans
ve had a good search around and can't find anything similar. Before I go uploading this - is anyone aware of anything similar? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Retired modules, still registered

2006-12-12 Thread Paul LeoNerd Evans
I have quite a few modules so far http://search.cpan.org/~pevans/ all of which I currently use in some active, real-world capacity, and am quite willing to maintain in the future. Should I register all of these? What are the general opinions on registration? -- Paul "LeoNerd" Evans [

Benefits of Test::Exception

2006-12-30 Thread Paul LeoNerd Evans
ion provide me with some greater functionallity I haven't yet observed? Or should I just not bother using it? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: Benefits of Test::Exception

2006-12-31 Thread Paul LeoNerd Evans
a runtime dependecy and > a test-time one though, EU::MM can't, but I believe Module::Build can. That said, the consensus on #perl/Freenode is that the latter isn't really ready yet, so just use the former. Ho hum.. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] I

Re: Benefits of Test::Exception

2006-12-31 Thread Paul LeoNerd Evans
Well, that looks a good start; but maybe we can go one better: BEGIN { unless( eval "use Test::Exception; 1" ) { *dies_ok = sub(&$) { my ( $code, $msg ) = @_; eval { $code->(); 1 } and fail( $msg ); }; } } Is this "as good" as T::E

Re: Benefits of Test::Exception

2006-12-31 Thread Paul LeoNerd Evans
way of hiding the internal functions from caller(), perhaps to neaten up error messages or the like...? I can't see why a simple implementation inline in the test script (see some of my other mails) would need to use that, as long as the user was aware of the extra lines. -- Paul "LeoNerd"

Re: Benefits of Test::Exception

2006-12-31 Thread Paul LeoNerd Evans
encies that don't turn into runtime dependencies. I have in fact reported a bug/wishlist/"I'll patch it if you think this is good" ticket on it: http://rt.cpan.org//Ticket/Display.html?id=24159 but until that's fixed, I'd rather not declare Test::Exception as a runtime dependen

Re: Benefits of Test::Exception

2006-12-31 Thread Paul LeoNerd Evans
ency tracking in EU::MM; which I have suggested here: http://rt.cpan.org//Ticket/Display.html?id=24159 Maybe I might even get around to fixing it... -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: Benefits of Test::Exception

2006-12-31 Thread Paul LeoNerd Evans
>without declaring it, so maybe it would work. > [snip] > > Erm... Test::More has been core since 5.007003 Ah yes. In that case, it just makes this look trickier - given as T::E isn't core, I can't rely it being installed on test boxes. See above. -- Paul "LeoNerd" E

Re: Benefits of Test::Exception

2007-01-01 Thread Paul LeoNerd Evans
What do you mean there..? Perhaps an example? Mine's as simple as perl -MO=LintSubs file.pm -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: EU::MM vs Module::Build

2007-01-01 Thread Paul LeoNerd Evans
On Sun, Dec 31, 2006 at 02:25:49PM -0800, Eric Wilhelm wrote: > # from Paul LeoNerd Evans > # on Sunday 31 December 2006 03:14 am: > > >EU::MM can't, but I believe Module::Build can. That said, the > > consensus on #perl/Freenode is that the latter isn't really

Looking for a module name

2007-01-18 Thread Paul LeoNerd Evans
I can come up with is Class::SomethingFactory Does anyone have any better ideas? I'm not sure of the "Something" part there, it doesn't really convey the generic "magic"ness of the code. But I can't think up anything else -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: Looking for a module name

2007-01-18 Thread Paul LeoNerd Evans
On Thu, 18 Jan 2007 16:18:13 -0600 "David Nicol" <[EMAIL PROTECTED]> wrote: > but the gist I got was that you are comfortable with design patterns > nomenclature. Heh. Not really. The limit of my knowledge is that Java people call "an object that makes new objects"

Re: Looking for a module name

2007-01-18 Thread Paul LeoNerd Evans
:Wonka, and Class::Elevator::Glass::Great. > BTW, before this goes on CPAN, I would like to cast my vote against the > dromedaryCased methodNames. Please, use lowercase_with_underscores. Sorry; been arguing with too many Java programmers today. underscore is probably what I'll do wi

Re: Looking for a module name

2007-01-18 Thread Paul LeoNerd Evans
around to > writing it :) That doesn't look very portable to me, though... Don't some OSes have crazy limits on the length of directory path components? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: Looking for a factory name

2007-01-19 Thread Paul LeoNerd Evans
ry" part of the name, and go for something like finder, or chooser. Thinking some more - if it does support a ->class_for() method, there's no actual requirement that the class we've found be a class that can be ->new()ed, maybe it just has some static methods in it. At which point, a

Variations on a theme

2007-02-05 Thread Paul LeoNerd Evans
t; my ( $key, $newvalue ) = @_; # some code to check $key and $newvalue and throw a wobbly if # not of the right form $self->{mappings}->{$key} = $newvalue; } Before I start writing any code in this direction - are there any thoughts on this? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: Module proposal: Test::Timer

2007-03-02 Thread Paul LeoNerd Evans
onds or so. Be slightly careful of timing imprecision though - I decided to pull in Time::HiRes for my specific test, but I don't know whether a generic "Test::Time" module could justify that. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: Module proposal: Test::Timer

2007-03-03 Thread Paul LeoNerd Evans
better: my $pid = $$; my $kid; if( ( $kid = fork() ) == 0 ) { # child sleep( $timeout ); kill SIGTERM, $pid; exit( 0 ); } $code->(); kill SIGKILL, $kid; This way, $code->() isn't affected by SIGALRM. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: Module proposal: Test::Timer

2007-03-08 Thread Paul LeoNerd Evans
interface in the documentation seems just what I had imagined. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

CPAN testers machines that lack Module::Build

2007-03-10 Thread Paul LeoNerd Evans
ing a report if it tried to hack up a Makefile.PL anyway and failed it, my current best plan is just to ignore them. Which doesn't seem very helpful, and makes it hard for me to see what the genuine bugs are. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: CPAN testers machines that lack Module::Build

2007-03-13 Thread Paul LeoNerd Evans
iven as it's Module::Build that runs the Build.PL in the first place? > (c) Ignore test reports from CPANPLUS It's an option... :/ -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: CPAN testers machines that lack Module::Build

2007-03-13 Thread Paul LeoNerd Evans
_requires' lines. I previously had a long discussion about using Test::Exception, my hesiation centring around the problem that it isn't a core module, so how to guarantee testing against it. The suggestion was to use M::B and 'build_require' it. So I don't really want to ba

Re: CPAN testers machines that lack Module::Build

2007-03-13 Thread Paul LeoNerd Evans
a bit > over time. Which I suppose is built by my own local Build.PL, so that's probably a good start... -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/

Re: CPAN testers machines that lack Module::Build

2007-03-15 Thread Paul LeoNerd Evans
On Thu, 15 Mar 2007 08:56:16 +0100 Johan Vromans <[EMAIL PROTECTED]> wrote: > IMNSHO, M::I should be renamed to something else, and then there's > room for a real Module::Install, one that installs a previously > prepared module. How about Module::Install::JustDoIt --

Hash::Util::lock_keys and objects

2007-03-27 Thread Paul LeoNerd Evans
class; $self->_init( @_ ); lock_keys( %$self ); return $self; } Then actually do all of the object initialisation in a subclass chain of sub _init { ... } methods. Anyone have anything better? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http:/

Re: echo die > Makefile.PL

2007-04-17 Thread Paul LeoNerd Evans
efile as well. So at least M::B-deprived systems might have a good go. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Module Proposal: Parse::Reversible

2007-04-20 Thread Paul LeoNerd Evans
n this; specifically, if this functionallity would be useful enough to put on CPAN, or if it seems a quite specialised solution to a specific problem and not worth doing. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ packa

Re: Module Proposal: Parse::Reversible

2007-04-20 Thread Paul LeoNerd Evans
ive in the config file specifies both parsing and rebuilding, rather than your example there requiring two separate strings. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Module Proposal: Parse::Reversible

2007-04-20 Thread Paul LeoNerd Evans
al case? In most cases, we couldn't do anything special like zero-pad the numbers. For example, if we had users in groups: '/groups/${GROUP:\w+}/users/${USER:\w+}.html' There's no other printf format of any interest that comes to mind, other than %s. -- Paul "

Re: Module Proposal: Parse::Reversible

2007-04-20 Thread Paul LeoNerd Evans
Are we sure on the notation format though? It gets quite hard to parse by this stage if we have ${NAME:pattern:format} if only that, what happens if we want a literal : in our pattern - do we need to escape it? Or maybe to make it look more like a pattern, we might try ${NAME/pat

Re: Module Proposal: Parse::Reversible

2007-04-21 Thread Paul LeoNerd Evans
On Sat, 21 Apr 2007 01:09:51 +0200 "A. Pagaltzis" <[EMAIL PROTECTED]> wrote: > * Paul LeoNerd Evans <[EMAIL PROTECTED]> [2007-04-20 19:55]: > > The requirement for this module came about intially because I > > was thinking about how to handle virtual U

Re: Module Proposal: Parse::Reversible

2007-04-22 Thread Paul LeoNerd Evans
a string into variables, or interpolating the variables back into a string. Both can be done within one object, symmetrically. To introduce something that breaks that symmetry effectively removes the requirement that it be done within one object, at which point one might as well use two separat

Re: Module Proposal: Parse::Reversible

2007-04-24 Thread Paul LeoNerd Evans
On Fri, Apr 20, 2007 at 06:50:03PM +0100, Paul LeoNerd Evans wrote: > package Parse::Reversable; I'm suddenly not so sure on the name any more... It's not just parsing, it's not just interpolation. It's both. To name it after one of these operations ignores the other. So

Re: Module Proposal: Parse::Reversible

2007-04-24 Thread Paul LeoNerd Evans
On Tue, Apr 24, 2007 at 01:31:02PM +0100, Paul LeoNerd Evans wrote: > String::ParsableInterpolable > > Surely we can do better than that? Actually, I'm not even sure on the "parsable" part now. Parsing would imply some sort of possibly-recursive, context-aware gram

Re: Module Proposal: Parse::Reversible

2007-04-24 Thread Paul LeoNerd Evans
anted to leave it generic at a string level. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: Module Proposal: Parse::Reversible

2007-04-24 Thread Paul LeoNerd Evans
On Tue, Apr 24, 2007 at 04:01:10PM +0100, Andy Armstrong wrote: > Text::Transform::Reversible ? "Transform" is too generic.. text goes in, other text goes out... That doesn't capture the essence of pattern matching (no pun intended :) ). -- Paul "LeoNerd" Evans [E

Re: Module Proposal: Parse::Reversible

2007-04-24 Thread Paul LeoNerd Evans
totally different idea. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: Module Proposal: Parse::Reversible

2007-04-24 Thread Paul LeoNerd Evans
ace; as A. Pagaltzis points out below; "string" is just a sequence of characters, which is what we have here, whereas "text" would imply some higher-level human meaning. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Module Proposal: Parse::Reversible

2007-04-25 Thread Paul LeoNerd Evans
erpolate-0.01/ An initial version :) I'm still inviting comment on its behaviour though... -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Test failures - I can't work out why

2007-04-28 Thread Paul LeoNerd Evans
home I tested it on). Does anyone have any ideas? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Test failures - I can't work out why

2007-04-29 Thread Paul LeoNerd Evans
to use $^X, indeed. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

"obvious" behavior for .pm.PL files using EU::MM

2007-04-30 Thread Paul LeoNerd Evans
. Can anyone suggest what manner of magic is needed in the Makefile.PL to achieve all this? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Module::Install reporting ARRAY(0x82c3dd8) ...missing

2007-06-18 Thread Paul LeoNerd Evans
onsider this to be a flaw in the tool itself; simply in people's use of it. It's ultimately chicken/egg. Plus, I believe the intention is that Module::Build will be core in perl 5.10 anyway, so that problem should go away. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350

RFC: Socket::GetAddrInfo

2007-11-12 Thread Paul LeoNerd Evans
ated vs. real output though, because these might legitimately differ (e.g. if the system defines that "localhost" also be IPv6 address "::1"). -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ Socket-GetAddr

Testers required for less-common platforms [was: RFC: Socket::GetAddrInfo]

2007-11-14 Thread Paul LeoNerd Evans
er reports from other operating systems; the helper script t/10compare-getaddrinfo.pm will generate some useful output to compare the real and emulated versions. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

autoconf-like work in Build.PL - detecting OS features

2007-11-22 Thread Paul LeoNerd Evans
S ever picks up the call, it will JustWork there...? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ use strict; use warnings; use Module::Build; use Config; print "ppoll() only works on Linux >= 2.6.16, wit

Re: Namespace question: ok if I use Text::Locale

2007-11-27 Thread Paul LeoNerd Evans
rintf("Hello, %1$s %2$s", given_name, surname); Which I observe Perl supports: $ perl -e 'printf q{Strings are %2$s and %1$s}, "first", "second";' Strings are second and first -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 41353

Re: Naming convention for thin wrappers around C lib.so ?

2007-12-11 Thread Paul LeoNerd Evans
e called libmemcached.so is purely a convention of the environment; namely, dynamically linked ELF libraries. Similarly here, the fact it lives in the Lib:: namespace is a convention of the perl environment. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux

Re: Naming convention for thin wrappers around C lib.so ?

2007-12-11 Thread Paul LeoNerd Evans
g to argue against "Lib::libmemcached", on the grounds of the 'lib' not really being part of the name. Yes; CamelCased names do seem the convention around here, except the pragmata, so I guess that's the way forward. -- Paul "LeoNerd" Evans [EMAIL PROTECTED

XS wrapper around system - how to test the wrapper but not the system?

2008-01-28 Thread Paul LeoNerd Evans
ux (where I develop), probably because of assumptions the tests make that don't hold there any more. E.g. one problem I had was BSD4.4-based systems, whose struct sockaddr_in includes the sin_len field. http://cpantesters.perl.org/show/Socket-GetAddrInfo.html Does anyone have any strategy sugge

Any contact with BRUCEK?

2008-01-31 Thread Paul LeoNerd Evans
ncontactable, and invoke some sort of missing-in-action procedure? Is it possible I might be able to take ownership of it, if contact cannot be made? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

cpantesters.org stalled?

2008-02-07 Thread Paul LeoNerd Evans
m got CCed to my email address. Perhaps the system that updates these pages has stalled somehow? How would I go about getting it looked into? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: cpantesters.org stalled?

2008-02-09 Thread Paul LeoNerd Evans
On Thu, 7 Feb 2008 14:04:29 + Paul LeoNerd Evans <[EMAIL PROTECTED]> wrote: > This page was generated by CPAN::WWW::Testers 0.33 at 2008-01-29 > 15:38:43 Ah; it's now been updated. Either false alarm, or someone's managed to fix it. In any case, all is happy now.

Re: RFC: URI::cpan

2008-03-26 Thread Paul LeoNerd Evans
odd things, and whatever is left must be IDs. cpan://dist/Foo-Bar cpan://module/Foo::Bar cpan://FRED I'd easily go for the former. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: How to challenge a cpan-testers test result?

2008-05-26 Thread Paul LeoNerd Evans
with an > outdated (they call it "stock" toolchain), so the signal/noise ratio is > roughly zero. This should largely become a non-issue now. 5.10 is the current "stable" perl, and comes with Module::Build. It's only the older testers on 5.8.8 or below t

Re: How to challenge a cpan-testers test result?

2008-05-26 Thread Paul LeoNerd Evans
BSD from considering them > for their own use. die "OS unsupported" unless $^O eq "freebsd"; in Build.PL should fix that. It'll turn your FAILs into NAs when run on non-FreeBSD boxen. I have two dists (IO-Ppoll and Solaris-SysInfo) which need that trick. -- Paul

Finding "the best" concrete subclass for an abstract base class

2008-05-27 Thread Paul LeoNerd Evans
han Foo? I suspect approach a may end up being better in practice, even if it involves a bit more coordination between the authors. How's anyone else go about this problem? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Module proposal: event hook lists

2008-06-03 Thread Paul LeoNerd Evans
lute numbers, into one of managing names. Hopefully less chance of collisions and mistaken behaviour, but it's more complex to implement and handle. Also harder for the "end user" to picture the behaviour. But maybe it's worth it? Another interesting question - if two async.

Re: Module proposal: event hook lists

2008-06-03 Thread Paul LeoNerd Evans
On Tue, Jun 03, 2008 at 12:49:57PM +0100, Paul LeoNerd Evans wrote: > Of course, now we have the simplest of hooklist aggregations - the > "repeat while false" one. What if we wanted something else? Suppose we > wanted to sum some quantity? > my $hooklist = Hooklist-

Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
# Synonym for has_refcount( $object, 1, '$object has only 1 reference' ); There's a very simple implementation for this I can think of; using: use B qw( svref_2object ); sub refcount { my $sv = svref_2object( $_[0] ); return $sv->REFCNT - 1; # Because @_ refers

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
cond reference, so you have to subtract 1, whereas the @_ array seems special and doesn't have that side-effect. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
t; will wait and see some comments on it first. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ Test-Refcount-0.01.tar.gz Description: GNU Zip compressed data signature.asc Description: PGP signature

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
On Mon, 14 Jul 2008 20:59:34 +0100 David Cantrell <[EMAIL PROTECTED]> wrote: > Can't you use Devel::Peek to get the refcount? I use B: use B qw( svref_2object ); my $SV = svref_2object($ref); my $refcount = $SV->REFCNT; -- Paul "LeoNerd" Evans [EM

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
use ->REFCNT - 1 -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
c $_[1] } 1; as a module, for example? When the module starts to get this small, I begin to wonder if it's more of a documentation issue. Perhaps somewhere in the documentation about objects and reference counts: The reference count of an object can be obtained by use B qw( svre

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
to use a normal lexical $object, then subtract 1 from the refcount, rather than rely on @_ not incrementing the count. Perhaps that'll be more portable. Try again attached... -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
On Mon, 14 Jul 2008 21:42:23 +0100 Paul LeoNerd Evans <[EMAIL PROTECTED]> wrote: > OK; I've changed it to use a normal lexical $object, then subtract 1 from > the refcount, rather than rely on @_ not incrementing the count. Perhaps > that'll be more portable. Actually

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
ble, but these are pure guesses. I also cannot explain the SCALAR one. This behaviour seems to complicate the idea of simply asserting REFCNT == 1. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ #!/usr/bin/perl -w

Re: Proposal: Test::Refcount

2008-07-14 Thread Paul LeoNerd Evans
On Tue, 15 Jul 2008 00:44:12 +0100 Paul LeoNerd Evans <[EMAIL PROTECTED]> wrote: >SCALAR => do { \my $var }, It seems I can make the SCALAR ref have refcount 1 by changing this to SCALAR => do { my $var; \$var }, Various initialisations {e.g my $var = 1} also keep it h

Re: Proposal: Test::Refcount

2008-07-15 Thread Paul LeoNerd Evans
On Tue, 15 Jul 2008 00:44:12 +0100 Paul LeoNerd Evans <[EMAIL PROTECTED]> wrote: >GLOB => \*SomeNewName, Also, this one isn't a fair test. Any real object code in a module would probably just pass out a new IO handle (as from socket(), socketpair(), pipe(), etc...) or

Re: Proposal: Test::Refcount

2008-07-15 Thread Paul LeoNerd Evans
in favour of better docs, or a wrapper module to hide the magicness? -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: Proposal: Test::Refcount

2008-07-15 Thread Paul LeoNerd Evans
#x27;s suggestion. return SvREFCNT(SvRV(ref)); I'll give that a while for comments and initial smoketests to settle, then see about uploading my Test::Refcount, now changed to use this instead. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 17946

Re: Proposal: Test::Refcount

2008-07-16 Thread Paul LeoNerd Evans
of any referent (i.e. ARRAY, HASH, CODE, GLOB and Regex types) as well. Consider: my $array = []; my $otherref = $array; Devel::Peek::SvREFCNT($array) => 1 Devel::Refcount::refcount($array) => 2 -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Regist

Re: Integrating license related things of CPAN

2008-10-22 Thread Paul LeoNerd Evans
tp://www.opensource.org/licenses as the official > list of open source licenses the short names should be coordinated > with them. Unified agreement with the wider community is good. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: Integrating license related things of CPAN

2008-10-22 Thread Paul LeoNerd Evans
a fair point. I'm just thinking of the case where someone will just put "anything" in the field to "shut up" the tool because they just want to get on with it. -- Paul "LeoNerd" Evans [EMAIL PROTECTED] ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: RFC: Attribute::Storage

2008-10-22 Thread Paul LeoNerd Evans
On Mon, Oct 20, 2008 at 11:49:58PM +0100, Paul LeoNerd Evans wrote: > Thoughts, anyone? On the name, the implementation, the idea,.. anything > else that comes to mind? Nothing; anybody? In that case perhaps I'll shove it up on CPAN then. -- Paul "LeoNerd" Evans [EMAIL PR

FAILs with "undefined symbol: setup_constants

2008-10-27 Thread Paul LeoNerd Evans
ux) http://nntp.x.perl.org/group/perl.cpan.testers/2028293 (5.10 / netbsd) http://nntp.x.perl.org/group/perl.cpan.testers/2149637 (5.10 / darwin) Before I go looking too deeply into it; is anyone aware of the reason behind this? Anything I can do about it? -- Paul "LeoNerd" Evans [

Re: FAILs with "undefined symbol: setup_constants

2008-10-29 Thread Paul LeoNerd Evans
for Devel-Refcount up to now. ... > These are written by CPANPLUS::Dist::YACSmoke 0.02 and 0.04 by the > same tester, this time known as chris. Like a cheetah who's just won Best Coat Award in the annual Serengeti "Miss Africa" contest; well spotted. > Maybe chris knows someth

RFC: String::Tagged

2009-01-29 Thread Paul LeoNerd Evans
tagged strings. Consider whether the behaviour of modification is chosen per-method, per-tag, or per-string. AUTHOR Paul Evans perl v5.10.0 2009-01-30 String::Tagged(3pm) - -- Paul "LeoNerd" Evans leon...@leonerd.org.uk ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: Digital signature

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
ositions of that string. The type of the tag values is not restricted - any scalar will do. Could even be a CODE ref, for "what to do if someone clicks here". Perhaps I should explain that clearer in the docs... -- Paul "LeoNerd" Evans leon...@leonerd.org.uk ICQ# 41353

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
for stringification, so I guess if that helps debugging etc.. I could do that. -- Paul "LeoNerd" Evans leon...@leonerd.org.uk ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
) before it's even called. -- Paul "LeoNerd" Evans leon...@leonerd.org.uk ICQ# 4135350 | Registered Linux# 179460 http://www.leonerd.org.uk/ signature.asc Description: PGP signature

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
g like these? String::Overlay String::Overlaid String::Overlays -- Paul "LeoNerd" Evans leon...@leonerd.org.uk |CPAN ID: PEVANS srand($,=" ");print sort{rand>0.5}grep{0.8>rand}qw(another Just hacker of Perl) signature.asc Description: Digital signature

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
hat to be the case. -- Paul "LeoNerd" Evans leon...@leonerd.org.uk |CPAN ID: PEVANS srand($,=" ");print sort{rand>0.5}grep{0.8>rand}qw(another Just hacker of Perl) signature.asc Description: Digital signature

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
tree, or a linked list of substrings. That isn't the case here - in fact, the string data itself is just stored in here as a single perl string. The tags are stored in as a list of [start, length, name, value] objects beside it. -- Paul "LeoNerd" Evans leon...@leonerd.org.uk |

Re: RFC: String::Tagged

2009-01-30 Thread Paul LeoNerd Evans
27;t help thinking we're getting a bit side-tracked by the name here. There's a lot of interesting API in the code, I feel the name is somewhat overshadowing any other discussion on the API design or other details... -- Paul "LeoNerd" Evans leon...@leonerd.org.uk |CPAN

  1   2   >