This repository was archived by the owner on Mar 20, 2023. It is now read-only.
This repository was archived by the owner on Mar 20, 2023. It is now read-only.
Separator: =
vs. :
#8
Closed
Description
Perl does both:
$ perl -Mutf8 -E 'say "π" =~ /\p{Script=Greek}/'
1
$ perl -Mutf8 -E 'say "π" =~ /\p{Script:Greek}/'
1
We only want to support one, but which one? The current proposal uses =
, but why not :
?
00:35:54 <bterlson> what is the rationale for `=` in `Script=` btw?
00:37:40 <bterlson> I mean, why not `Script:foo`
00:38:09 <mathiasbynens> no strong preference, but I think we should only support either `:` or `=` but not both: https://github.com/mathiasbynens/es-regexp-unicode-property-escapes#why-not-support--as-a-separator-in-addition-to-
00:38:29 <bterlson> both is absurd
00:38:40 <mathiasbynens> Perl does both!
00:38:46 <bterlson> absurd
00:38:50 <mathiasbynens> :)
00:39:06 <bterlson> `:` aligns with property syntax
00:43:06 <mathiasbynens> hmm yeah that makes sense… although property name grammar in \p{} is much more restrictive than Identifier