Commit 6b3457de authored by Samuel Gélineau's avatar Samuel Gélineau
Browse files

don't special-case versions with leading zeroes

I could not install pcre-light because cabal failed with:

  parsing output of pkg-config --modversion failed

The output of that command was simply "8.02", which cabal could not
parse into a Version because of the leading zero. With this patch,
"8.02" now parses as (Version [8,2] []).
parent 2a1cbfcd
......@@ -63,7 +63,5 @@ instance Text Version where
digits = do
first <- Parse.satisfy Char.isDigit
if first == '0'
then return 0
else do rest <- Parse.munch Char.isDigit
return (read (first : rest))
rest <- Parse.munch Char.isDigit
return (read (first : rest))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment