Created
July 22, 2011 03:14
-
-
Save frenchy64/1098817 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(def pm2 (pattern-matrix [(pattern-row [wildcard (pattern false) (pattern true)] :a1) | |
(pattern-row [(pattern false) (pattern true) wildcard] :a2) | |
(pattern-row [wildcard wildcard (pattern false)] :a3) | |
(pattern-row [wildcard wildcard (pattern true)] :a4)] | |
'[x y z])) | |
(compile pm2) | |
;#match.core.SwitchNode[ | |
; 1, | |
; [[<Pattern: true> #match.core.PatternMatrix[ | |
; [#match.core.PatternRow[ | |
; [<Pattern: false> <Pattern: true>], :a1] | |
; #match.core.PatternRow[ | |
; [<Pattern: _> <Pattern: false>], :a3] | |
; #match.core.PatternRow[ | |
; [<Pattern: _> <Pattern: true>], :a4]], [y z]]] | |
; | |
; | |
; [<Pattern: false> #match.core.PatternMatrix[ | |
; [#match.core.PatternRow[ | |
; [<Pattern: false> <Pattern: true>], :a1] | |
; #match.core.PatternRow[ | |
; [<Pattern: true> <Pattern: _>], :a2] | |
; #match.core.PatternRow[ | |
; [<Pattern: _> <Pattern: false>], :a3] | |
; #match.core.PatternRow[ | |
; [<Pattern: _> <Pattern: true>], :a4]], [y z]]] | |
; | |
; [default #match.core.FailNode[]]]] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment