Opened 3 years ago

Closed 3 years ago

#1333 closed defect (fixed)

match from matchable doesn't handle keywords properly

Reported by: xificurC Owned by: Alex Shinn
Priority: major Milestone: someday
Component: extensions Version: 4.11.0
Keywords: match matchable Cc:
Estimated difficulty: easy

Description

(match '(#:key 1) [(#:foo x) x]) matches and returns 1, whereas I would expect keywords to be self evaluating and therefore throw a match error.

And this throws a match error, not sure why: (match '(#:key #:key) [(#:foo #:foo) "here"]). Again the expected behavior would be a match error.

As a last example: (match '(#:key) [(#:foo) 1] [(#:key) 2]) should return 2 but returns 1.

Change History (3)

comment:1 Changed 3 years ago by xificurC

For the second example - I meant to say I think it should throw a match error but with the current behavior in place I don't understand why it doesn't match.

comment:2 Changed 3 years ago by Mario Domenech Goulart

Owner: set to Alex Shinn
Status: newassigned

comment:3 Changed 3 years ago by Alex Shinn

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.