This file contains 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
type RGB = | |
| Red of byte | |
| Green of byte | |
| Blue of byte | |
let (|TheRed|_|) = function | |
| Red x -> Some x | |
| _ -> None | |
let xs = [Red 42uy; Green 0uy; Blue 0uy] |