On Fri, May 13, 2005 at 01:07:20PM -0700, Larry Wall wrote:
On Fri, May 13, 2005 at 11:54:47AM -0500, Patrick R. Michaud wrote:
: $r1 = rx / abc :: def | ghi :: jkl | mn :: op /;
: $r2 = rx / abc ::: def | ghi ::: jkl | mn ::: op /;
: $r3 = rx / [ abc :: def | ghi :: jkl | mn :: op
Larry Wall wrote:
Speaking of which, it seems to me that :p and :c should allow an
argument that says where to start relative to the current position.
In other words, :p means :p(0) and :c means :c(0). I could also see
uses for :p(-1) and :p(+1).
Isn't that slightly inconsistent with :p meaning
TSa (Thomas Sandlaß) kirjoitti:
Larry Wall wrote:
Speaking of which, it seems to me that :p and :c should allow an
argument that says where to start relative to the current position.
In other words, :p means :p(0) and :c means :c(0). I could also see
uses for :p(-1) and :p(+1).
Isn't that
Markus Laire skribis 2005-05-13 11:43 (+0300):
Perhaps spec should be changed so that :p means :p(bool::true) or :p(?1)
and not :p(1)
aol
Agreed
/
Juerd
--
http://convolution.nl/maak_juerd_blij.html
http://convolution.nl/make_juerd_happy.html
http://convolution.nl/gajigu_juerd_n.html
On Fri, 2005-05-13 at 00:26, Patrick R. Michaud wrote:
On Thu, May 12, 2005 at 08:56:39PM -0700, Larry Wall wrote:
On Thu, May 12, 2005 at 09:33:37AM -0500, Patrick R. Michaud wrote:
: Also, A05 proposes incorrect alternatives to the above
:
: /[:w[]foo bar]/
I would just like to
On 5/12/05, Patrick R. Michaud [EMAIL PROTECTED] wrote:
I have a couple of questions regarding C :: in perl 6 rules.
First, a question of verification -- in
$rule = rx :w / plane :: (\d+) | train :: (\w+) | auto :: (\S+) / ;
travel by plane jet train tgv today ~~ $rule
I think
On 5/13/05, Patrick R. Michaud [EMAIL PROTECTED] wrote:
To use the phrase from later in your message, there's still
the implicit .*? followed by the rule call. Since the rule
itself hasn't failed (only the group failed), we're still free to
try to match the pattern at later positions.
I'm
On Fri, May 13, 2005 at 03:36:50PM +, Luke Palmer wrote:
I'm basically saying that you should treat your:
$str ~~ /abc :: def | ghi :: jkl | mn :: op/;
As:
$rule = rx/abc :: def | ghi :: jkl | mn :: op/;
$str ~~ /^ .*? $rule/;
Which means that you fail the rule, your .*?
On Fri, May 13, 2005 at 11:43:42AM +0300, Markus Laire wrote:
: Perhaps spec should be changed so that :p means :p(bool::true) or :p(?1)
: and not :p(1)
I'm still not sure I believe in booleans to that extent. I suppose
we could go as far as to make it :p(0 but true). Actually, it's more
like
Larry wrote:
I'm still not sure I believe in booleans to that extent. I suppose
we could go as far as to make it :p(0 but true). Actually, it's more
like undef but true, if you want to be able to distinguish
sub foo (+$p = 0) { # no :p at all
say true if $p; # :p with no
On 5/13/05, Patrick R. Michaud [EMAIL PROTECTED] wrote:
First, I'm quite certain that $r2 and $r3 are different. For
illustration, let's use a variation like:
$q2 = rx / \w [ abc ::: def | ghi ::: jkl | mn ::: op ] /;
$q3 = rx / \w [ [ abc :: def | ghi :: jkl | mn :: op ] ]/;
On Sat, May 14, 2005 at 01:15:36AM +, Luke Palmer wrote:
: I think the misunderstanding is rather simple. You keep talking like
: you prepend a .*? to the rule we're matching. I think that's wrong
: (and this is where I'm making a design call, so we can dispute on this
: once we're clear
On 5/14/05, Larry Wall [EMAIL PROTECTED] wrote:
On Sat, May 14, 2005 at 01:15:36AM +, Luke Palmer wrote:
: I think the misunderstanding is rather simple. You keep talking like
: you prepend a .*? to the rule we're matching. I think that's wrong
: (and this is where I'm making a design
On Sat, May 14, 2005 at 04:26:44AM +, Luke Palmer wrote:
On 5/14/05, Larry Wall [EMAIL PROTECTED] wrote:
I want ::: to break out of *that* dynamic scope (or the equivalent
matchrighthere scope), but not ::.
I'm not sure that's such a good idea. When you say:
rule foo() { a* :::
I have a couple of questions regarding C :: in perl 6 rules.
First, a question of verification -- in
$rule = rx :w / plane :: (\d+) | train :: (\w+) | auto :: (\S+) / ;
travel by plane jet train tgv today ~~ $rule
I think the match should fail outright, as opposed to matching train
My take, based on S05:
On Thu, 2005-05-12 at 10:33, Patrick R. Michaud wrote:
I have a couple of questions regarding C :: in perl 6 rules.
First, a question of verification -- in
$rule = rx :w / plane :: (\d+) | train :: (\w+) | auto :: (\S+) / ;
travel by plane jet train tgv
On Thu, May 12, 2005 at 12:53:46PM -0400, Aaron Sherman wrote:
On Thu, 2005-05-12 at 10:33, Patrick R. Michaud wrote:
Next on my list, S05 says It is illegal to use :: outside of
an alternation, but A05 has
/[:w::foo bar]/
I can't even figure out what that means. :w turns on word
On Thu, May 12, 2005 at 12:53:46PM -0400, Aaron Sherman wrote:
My take, based on S05:
In other words, it acts as though one had written
$rule = rx :w / plane ::: (\d+) | train ::: (\w+) | auto ::: (\S+) / ;
and not
$rule = rx :w /[ plane :: (\d+) | train :: (\w+) |
On Thu, May 12, 2005 at 12:33:59PM -0500, Jonathan Scott Duff wrote:
/[:w\bfoo bar]/# not exactly the same as above
No, I think that's exactly the same.
What does \b mean again? I assume it's no longer backspace?
For as long as I can remember \b has meant word boundary in
PRM == Patrick R Michaud [EMAIL PROTECTED] writes:
PRM On Thu, May 12, 2005 at 12:33:59PM -0500, Jonathan Scott Duff wrote:
/[:w\bfoo bar]/# not exactly the same as above
No, I think that's exactly the same.
What does \b mean again? I assume it's no longer
On Thu, 2005-05-12 at 13:44, Patrick R. Michaud wrote:
On Thu, May 12, 2005 at 12:53:46PM -0400, Aaron Sherman wrote:
In other words, it acts as though one had written
$rule = rx :w / plane ::: (\d+) | train ::: (\w+) | auto ::: (\S+) / ;
and not
$rule = rx :w
$rule = rx :w / plane ::: (\d+) | train ::: (\w+) | auto ::: (\S+) / ;
$rule = rx :w /[ plane :: (\d+) | train :: (\w+) | auto :: (\S+) ]/ ;
On Thu, May 12, 2005 at 02:29:24PM -0400, Aaron Sherman wrote:
On Thu, 2005-05-12 at 13:44, Patrick R. Michaud wrote:
On Thu, May 12, 2005 at
On Thu, 2005-05-12 at 15:41, Patrick R. Michaud wrote:
$rule = rx :w / plane ::: (\d+) | train ::: (\w+) | auto ::: (\S+) / ;
$rule = rx :w /[ plane :: (\d+) | train :: (\w+) | auto :: (\S+) ]/ ;
On Thu, May 12, 2005 at 02:29:24PM -0400, Aaron Sherman wrote:
On Thu, 2005-05-12 at
On Thu, May 12, 2005 at 05:15:55PM -0400, Aaron Sherman wrote:
On Thu, 2005-05-12 at 15:41, Patrick R. Michaud wrote:
False. In the first case the group is the whole rule. In the second
case the group would not include the (implied) '.*?' at the start of
the rule.
This was a very
On Thu, May 12, 2005 at 09:33:37AM -0500, Patrick R. Michaud wrote:
: Also, A05 proposes incorrect alternatives to the above
:
: /[:w[]foo bar]/# null pattern illegal, use null
: /[:w()foo bar]/# null capture illegal, and probably undesirable
: /[:w\bfoo bar]/# not
On Thu, May 12, 2005 at 08:56:39PM -0700, Larry Wall wrote:
On Thu, May 12, 2005 at 09:33:37AM -0500, Patrick R. Michaud wrote:
: Also, A05 proposes incorrect alternatives to the above
:
: /[:w[]foo bar]/# null pattern illegal, use null
: /[:w()foo bar]/# null capture
26 matches
Mail list logo