Raku / Raku/doc

Clarify what happens when regex are smartmatched against objects that mix-in Positional or Associative

Open
#3,545 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

docs
Dominant language
Raku
Stars
308
Forks
288
Avg merge
3d 49m
Merged PRs (30d)
2

Description

Problem or new feature

The documentation for Regex.ACCEPTS explains what happens when smartmatching against an Associative or Positional. However, as indicated in rakudo/rakudo#3833, it does not say what happens when those are roles in an object; in the case of Positional, for instance, the class must mix in Iterable too, as the example shows.

Suggestions

That text in general is 8 years old, so implementation or even behavior might have veered away from what's described. Check out specs, source and describe behavior better.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Regex.ACCEPTS documentation and the behavior described in rakudo/rakudo#3833. Check the relevant specifications and implementation to verify how smartmatching handles objects that mix in Positional or Associative, including the Positional and Iterable requirement. Update the documentation to accurately describe the current behavior and examples.

Written by the indexing model from the issue text.

Assessment

Domain
documentation
Issue type
Documentation
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.