Merge pull request #271 from andy-morris/p_strLen
Fix missing case in Idris.Primitives.p_strLen
commitc4b7e56c09aa885aa3010ae68d79a1ba31b061a1
authorEdwin Brady <edwin.brady@gmail.com>
dateWed 10 Apr 2013, 01:42 (14 years ago)
parent35096cfc328454
src/Idris/Primitives.hs+1
@@ -625,6 +625,7 @@ p_floatFloor = p_fPrim (fromInteger . floor)
625625p_floatCeil = p_fPrim (fromInteger . ceiling)
626626
627627p_strLen [VConstant (Str xs)] = Just $ VConstant (I (length xs))
628+p_strLen _ = Nothing
628629p_strHead [VConstant (Str (x:xs))] = Just $ VConstant (Ch x)
629630p_strHead _ = Nothing
630631p_strTail [VConstant (Str (x:xs))] = Just $ VConstant (Str xs)