Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document < … > lists on the regex page #1857

Open
cfa opened this issue Mar 20, 2018 · 2 comments
Open

Document < … > lists on the regex page #1857

cfa opened this issue Mar 20, 2018 · 2 comments
Labels
docs Documentation issue (primary issue type) external Depends on another ticket (likely in another repo)

Comments

@cfa
Copy link
Contributor

cfa commented Mar 20, 2018

It's not obvious that <> is a LTM; the angle brackets may also be mistaken for rule delimiters.

say 'food' ~~ /< f fo foo food >/;      # OUTPUT: «「food」␤»
say 'food' ~~ / f | fo | foo | food /;  # OUTPUT: «「food」␤»
@cfa cfa added the docs Documentation issue (primary issue type) label Mar 20, 2018
@cfa cfa changed the title Document < > lists on the regex page Document < … > lists on the regex page Mar 20, 2018
@zoffixznet
Copy link
Contributor

I also would've thought || prefix applied to this construct as it does in /||@foo/ and even /||<{qw/foo food/}>/ to effect first-listed-match instead of LTM matching, but it doesn't look like it works.

I think that's a bug and filed it as rakudo/rakudo#1635 but I'm not 100% sure if it's intentional that it doesn't work.

cfa added a commit that referenced this issue Mar 21, 2018
Also document a trap to cover <foo> vs. < foo> within regexes.

Refs #1857.
@JJ JJ self-assigned this Mar 23, 2018
@JJ JJ added the TPF Grant label Mar 23, 2018
@cfa
Copy link
Contributor Author

cfa commented Mar 23, 2018

@JJ: to clarify, the main issue was addressed in 124b498; @zoffixznet's || comment is outstanding.

@JJ JJ removed the JJ TPF Grant label May 14, 2018
@JJ JJ removed their assignment Nov 4, 2018
@JJ JJ added the external Depends on another ticket (likely in another repo) label Jan 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation issue (primary issue type) external Depends on another ticket (likely in another repo)
Projects
None yet
Development

No branches or pull requests

3 participants