Skip to content

Instantly share code, notes, and snippets.

@marcmo
Created March 20, 2010 13:37
Show Gist options
  • Save marcmo/338676 to your computer and use it in GitHub Desktop.
Save marcmo/338676 to your computer and use it in GitHub Desktop.
newtype SpecialChar = SC { unSC :: Char } deriving Show
instance Arbitrary SpecialChar where
arbitrary = do
x <- oneof [choose ('\0','\55295'), choose ('\57344','\1114111')]
return (SC x)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment