diff options
author | David Roundy <droundy@darcs.net> | 2007-09-25 22:28:01 +0200 |
---|---|---|
committer | David Roundy <droundy@darcs.net> | 2007-09-25 22:28:01 +0200 |
commit | f156bd3f2b4fbd9d4153245a6fd148af57929f06 (patch) | |
tree | 72c4d04fbfb037c861309f44a95e302258c3dca9 | |
parent | f9f72b911aa645fd9510dc541bb681da6153194f (diff) | |
download | metatile-f156bd3f2b4fbd9d4153245a6fd148af57929f06.tar metatile-f156bd3f2b4fbd9d4153245a6fd148af57929f06.zip |
fix bug in reading of SomeLayouts.
darcs-hash:20070925202801-72aca-476deef33546c9e50ab8b214df29e3330b1839f9
-rw-r--r-- | XMonad.hs | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -144,7 +144,9 @@ instance Show (SomeLayout a) where show (SomeLayout l) = show l readLayout :: [SomeLayout a] -> String -> [(SomeLayout a, String)] -readLayout ls s = concatMap rl ls +readLayout ls s = case concatMap rl ls of + (x:_) -> [x] + [] -> [] where rl (SomeLayout x) = map (\(l,s') -> (SomeLayout l,s')) $ rl' x rl' :: Layout l a => l a -> [(l a,String)] rl' _ = reads s |