Skip to content
vindarel edited this page Nov 5, 2020 · 2 revisions

(= number), (/= number) patterns

These will check if the matched values are of type `number`, and if they follow the specific numeric constraints.

<, >, <=, >= patterns

These will check if the matched values are of type `real`, and if they follow the specific numeric constraints. The arguments do not match when they are `complex`, since they cannot be compared by greater/less.

(let ((x 5))
   (trivia:match x
       ((< 10)
        :lower)))
:LOWER