$ perl5.12.2 junk Compiling REx "-?\p{Nd}" synthetic stclass "ANYOF[\-][+utf8::Nd]". Final program: 1: CURLY {0,1} (5) 3: EXACT <-> (0) 5: ANYOF[{unicode}+utf8::Nd] (17) 17: END (0) stclass ANYOF[\-][+utf8::Nd] minlen 1 Matching REx "-?\p{Nd}" against "1" Matching stclass ANYOF[\-][+utf8::Nd] against "1" (1 chars) Contradicts stclass... [regexec_flags] Match failed Doesn't match Freeing REx: "-?\p{Nd}" #### $ perl5.14.1 junk Compiling REx "-?\p{Nd}" synthetic stclass "ANYOF{i}[\-][{non-utf8-latin1-all}{unicode}{outside bitmap}+utf8::Nd]". Final program: 1: CURLY {0,1} (5) 3: EXACT <-> (0) 5: ANYOF[{unicode}{outside bitmap}+utf8::Nd] (16) 16: END (0) stclass ANYOF{i}[\-][{non-utf8-latin1-all}{unicode}{outside bitmap}+utf8::Nd] minlen 1 Matching REx "-?\p{Nd}" against "1" Matching stclass ANYOF{i}[\-][{non-utf8-latin1-all}{unicode}{outside bitmap}+utf8::Nd] against "1" (1 bytes) 0 <> <1> | 1:CURLY {0,1}(5) EXACT <-> can match 0 times out of 1... 0 <> <1> | 5: ANYOF[{unicode}{outside bitmap}0-9...+utf8::Nd](16) 1 <1> <> | 16: END(0) Match successful! Matches Freeing REx: "-?\p{Nd}" #### $ perl5.12.2 junk Compiling REx "-?\p{Nd}{1}" Final program: 1: CURLY {0,1} (5) 3: EXACT <-> (0) 5: CURLY {1,1} (19) 7: ANYOF[{unicode}+utf8::Nd] (0) 19: END (0) minlen 1 Matching REx "-?\p{Nd}{1}" against "1" 0 <> <1> | 1:CURLY {0,1}(5) EXACT <-> can match 0 times out of 1... 0 <> <1> | 5: CURLY {1,1}(19) ANYOF[{unicode}0-9...+utf8::Nd] can match 1 times out of 1... 1 <1> <> | 19: END(0) Match successful! Matches Freeing REx: "-?\p{Nd}{1}" #### $ perl5.14.1 junk Compiling REx "-?\p{Nd}{1}" Final program: 1: CURLY {0,1} (5) 3: EXACT <-> (0) 5: CURLY {1,1} (18) 7: ANYOF[{unicode}{outside bitmap}+utf8::Nd] (0) 18: END (0) minlen 1 Matching REx "-?\p{Nd}{1}" against "1" 0 <> <1> | 1:CURLY {0,1}(5) EXACT <-> can match 0 times out of 1... 0 <> <1> | 5: CURLY {1,1}(18) ANYOF[{unicode}{outside bitmap}0-9...+utf8::Nd] can match 1 times out of 1... 1 <1> <> | 18: END(0) Match successful! Matches Freeing REx: "-?\p{Nd}{1}"