From ae019e86ed29969de2f15e93fab539d36f935661 Mon Sep 17 00:00:00 2001 From: hasufell Date: Sun, 5 Oct 2014 15:50:52 +0200 Subject: [PATCH] Style --- Diagram.hs | 1 + Meshparser.hs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Diagram.hs b/Diagram.hs index 19433ee..cc275b9 100644 --- a/Diagram.hs +++ b/Diagram.hs @@ -35,6 +35,7 @@ diagFromVTable prop vt t prop :: Diagram Cairo R2) # fc black mkPoint (x,y) = p2 (x,y) + -- |Create the Diagram from a String. diagFromString :: DiagProp -> String -> Diagram Cairo R2 diagFromString prop mesh diff --git a/Meshparser.hs b/Meshparser.hs index c0de440..73aef8d 100644 --- a/Meshparser.hs +++ b/Meshparser.hs @@ -10,7 +10,7 @@ type VTable = [(Double, Double)] -- an array of float tuples. meshToArr :: String -- ^ the string to convert -> VTable -- ^ the resulting vertice table -meshToArr xs = fmap (\(Just (x, _)) -> x) . +meshToArr xs = fmap (\(Just (x, _)) -> x) . filter (/= Nothing) . fmap (runParser parseVertice) . lines $