Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight

Re: Simple regex should match number

by repellent (Priest)
on Feb 01, 2012 at 07:41 UTC ( #951139=note: print w/replies, xml ) Need Help??

in reply to Simple regex should match number

Really weird, looks like a bug:
use Test::More; ok( 1 =~ m/\p{Nd}/ ); ok( 1 =~ m/^-?\p{Nd}/ ); ok( 1 =~ m/-?\p{Nd}+/ ); ok( 1 =~ m/-?\p{Nd}/ ); ok( 1 =~ m/-*\p{Nd}/ ); ok( 1 =~ m/x?\p{Nd}/ ); ok( 1 =~ m/x?y?\p{Nd}/ ); done_testing(); __END__ ok 1 ok 2 ok 3 not ok 4 # Failed test at ./ line 16. not ok 5 # Failed test at ./ line 17. not ok 6 # Failed test at ./ line 18. not ok 7 # Failed test at ./ line 19. 1..7 # Looks like you failed 4 tests of 7.

$ perl -v This is perl, v5.10.0 built for darwin-thread-multi-2level

Replies are listed 'Best First'.
Re^2: Simple regex should match number
by JavaFan (Canon) on Feb 01, 2012 at 11:51 UTC
    That's a known bug, and, AFAIK, fixed in 5.14.0. It's certainly fixed in 5.14.2.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://951139]
[Discipulus]: to eat, no? grin
[Eily]: hu, don't tell the other French people I never tried it, I might get kicked out :P
choroba . o O ( The Czech at-sign is also edible )
[Eily]: the French @ is a mouthful I guess...
[Eily]: choroba Wikipedia gives me Zavináč which doesn't seem to translate to something edible?
[Eily]: (yes I'm very good at using question marks, thank you)
[Discipulus]: O_O frexit for you! even me i tried. it was in the arabic quarter in Granada; they offered as 'tapas' in bars. I eataly somewhere they eat ;=P Sardinia a Pulia iirc
[choroba]: Zavináč

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2017-11-21 10:55 GMT
Find Nodes?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:

    Results (297 votes). Check out past polls.