[MATCH-47] vector patterns dispatch on count after dispatching on type Created: 23/Dec/11 Updated: 23/Dec/11 |
|
| Status: | In Progress |
| Project: | core.match |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Critical |
| Reporter: | David Nolen | Assignee: | David Nolen |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
|
The current behavior just creates complications. |
[MATCH-36] throw on unsuccessful match Created: 27/Oct/11 Updated: 30/Nov/11 |
|
| Status: | Open |
| Project: | core.match |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Critical |
| Reporter: | David Nolen | Assignee: | David Nolen |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
|
I was on the fence about this. But after looking at the literature as well as the behavior of condp, I've decided that throwing on unsuccessful match is the way to go. This is particularly important since we put no constraints on the types allowed - we cannot determine exhaustiveness. |
[MATCH-35] Bug in seq pattern matching Created: 27/Oct/11 Updated: 11/Jan/12 |
|
| Status: | Open |
| Project: | core.match |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Critical |
| Reporter: | David Nolen | Assignee: | David Nolen |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
(let [l '(1 2 3)]
(match [l]
[([a & [b & [c d]]] :seq)] :a0
:else :a1))
Matches when it shouldn't. |
| Comments |
| Comment by Greg Chapman [ 11/Jan/12 10:24 AM ] |
|
Another example of (I think) the same issue: user=> (let [x ()] (match [x] [([h & t] :seq)] [h t] [_] :a1)) Perhaps SeqPattern's IPatternCompile should call seq in order to filter empty seqs? (e.g.: (to-source* [this ocr] |
[MATCH-31] vector patterns should work on seq Created: 10/Oct/11 Updated: 30/Nov/11 |
|
| Status: | In Progress |
| Project: | core.match |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Defect | Priority: | Critical |
| Reporter: | David Nolen | Assignee: | David Nolen |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Description |
|
This means abandoning subvec and using nth + offsets. |