[Haskell-cafe] ANN: Mueval 0.3.1, 0.4, 0.4.5, 0.4.6, 0.5

Gwern Branwen gwern0 at gmail.com
Mon Jul 28 14:05:09 EDT 2008


Hi everyone. So there've been a number of releases of Mueval lately. I figured I'd tell you about them.

WHERE

As always, you can 'cabal install mueval', or get it from Hackage <http://hackage.haskell.org/cgi-bin/hackage-scripts/package/mueval>, or get it from the new Darcs repository <http://code.haskell.org/mubot/>. Usage remains as before, but see below for numerous examples, or the file 'tests.sh'.

WHAT'S INTERESTING

Mueval is now even more capable. I've fixed the big security hole Spencer identified, so right now I know of no vulnerabilities in Mueval (or even potentially dangerous aspects). More interestingly is how close Mueval is now to Lambdabot's capabilities: we can evaluate all the same expressions, and Mueval now even can do QuickCheck tests.

The only missing pieces is that currently there's no interface to Smallcheck yet (but hardly anyone in #haskell seems to use that, so I'm considering not even bothering), and currently there's no way to do @let or qualified imports. I hope to add these two missing pieces for the next release - and then I can finally remove hs-plugins from Lambdabot.

CHANGES

0.5

Adds support for Unicode in expressions!

 bash$ mueval -e 'let (ñ) = (+) in ñ 5 5'
  10"

Adds support for QuickCheck tests!

 bash-3.2$ mueval -E -e 'myquickcheck (\x -> x == x)'
 "\"OK, passed 500 tests.\\n\""
 bash-3.2$ mueval -E -e 'myquickcheck (\x -> x+1 == x+2)'
 "\"Falsifiable, after 0 tests:\\n0\\n\""

--inferred-type prints out even more information!

 bash-3.2$ mueval --inferred-type --expression 'foldr (\x y -> concat ["(f ",x," ",y,")"]) "z" (map show [1..5])'
 foldr (\x y -> concat ["(f ",x," ",y,")"]) "z" (map show [1..5])
 [Char]
 "\"(f 1 (f 2 (f 3 (f 4 (f 5 z)))))\""

0.4.6

A README!

--print-type was renamed to --inferred-type so as to avoid short-option ambiguity!

Refactoring!

Haddocks look somewhat nicer!

0.4.5

Even more refactoring and modularization!

Performance improvements! (ie. 'call error sooner so mueval doesn't hang around waiting for the timeout to expire')

0.4

Close major security hole! No more:

 mueval --expression "Foreign.unsafePerformIO $ readFile \"foo\""

(Since now one must declare module imports, and cannot circumvent them due to a certain bad behaviour of the GHC API.)

0.3.1

Blacklist unsafe keywords!

 mueval --expression "Foreign.unsafePerformIO $ readFile \"/etc/passwd\""
 mueval: Unsafe functions to use mentioned.

Looser resource limits (so hopefully more people can run it)!

A Darcs repository!

 darcs get http://code.haskell.org/mubot/

(And of course mixed in throughout these changes are various test additions; it's a respectable little suite now.)


--
gwern
Propaganda Security rip CIO VIP Pershing O/S MPRI JASON AMEMB
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20080728/de56bf56/attachment.bin


More information about the Haskell-Cafe mailing list