diff options
author | Joey Hess <joey@kitenet.net> | 2013-04-13 17:22:15 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2013-04-13 17:22:15 -0400 |
commit | 5533ec2f918dca97e8528485f94da545506b6a53 (patch) | |
tree | c6fd49f07ed1fb4ca2fd753dc3d4cd11ce8fc766 /Build | |
parent | 82d22b56ed6aecebd6c40c0368e432a6abb7213f (diff) |
fix a syntax problem with a splace that provides a parameter to a function
Diffstat (limited to 'Build')
-rw-r--r-- | Build/EvilSplicer.hs | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/Build/EvilSplicer.hs b/Build/EvilSplicer.hs index ad3fb3b92..2cc411e6a 100644 --- a/Build/EvilSplicer.hs +++ b/Build/EvilSplicer.hs @@ -173,13 +173,16 @@ expandSplice s lls = concat [before, new:splicerest, end] l:r -> (expandtabs l, take (length r) (repeat [])) _ -> ([], []) new = concat - [ let s = deqqstart $ take (coordColumn cs - 1) splicestart - in if all isSpace s - then "" - else s + [ beforesplice , addindent (findindent splicestart) (mangleCode $ splicedResult s) , deqqend $ drop (coordColumn ce) splicestart ] + where + beforesplice = + let s = deqqstart $ take (coordColumn cs - 1) splicestart + in if all isSpace s + then "" + else s ++ " $ " {- coordinates assume tabs are expanded to 8 spaces -} expandtabs = replace "\t" (take 8 $ repeat ' ') |