mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-27 13:32:51 -06:00
fixed reading argvars from gfc in gf-to-gfcc
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
module GF.Infra.CompactPrint where
|
||||
import Data.Char
|
||||
|
||||
compactPrint = concat . map spaceIf . words
|
||||
compactPrint = tail . concat . map spaceIf . words
|
||||
|
||||
spaceIf w = case w of
|
||||
_ | keyword w -> "\n" ++ w
|
||||
c:cs | isAlpha c || isDigit c -> " " ++ w
|
||||
_ -> w
|
||||
|
||||
keyword w = elem w ["cat","fun","lin","lincat","oper","param"]
|
||||
keyword w = elem w ["cat","fun","lin","lincat","lindef","oper","param"]
|
||||
|
||||
Reference in New Issue
Block a user