diff options
| author | hallgren <hallgren@chalmers.se> | 2015-12-02 16:41:18 +0000 |
|---|---|---|
| committer | hallgren <hallgren@chalmers.se> | 2015-12-02 16:41:18 +0000 |
| commit | f2b057c0787f835675a6bab1af48f4e624f71254 (patch) | |
| tree | e8143cc72d5176bc19a7f645dc2dcc665effaee3 /src/compiler/GF/Compile/Compute | |
| parent | 5bb792be5e3416a2229d549d57f02b54829c470b (diff) | |
GF shell, cc command: try to compute pre{...} tokens in token sequences
This is implemented as a simple post-processing step after partial evaluation
to try compute pre{...} tokens in token sequences. Nothing is done to deal
with intervening free variants.
This was done in response to a query from René T on the gf-dev mailing list.
Diffstat (limited to 'src/compiler/GF/Compile/Compute')
| -rw-r--r-- | src/compiler/GF/Compile/Compute/ConcreteNew.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler/GF/Compile/Compute/ConcreteNew.hs b/src/compiler/GF/Compile/Compute/ConcreteNew.hs index 744074e9e..e368d9d77 100644 --- a/src/compiler/GF/Compile/Compute/ConcreteNew.hs +++ b/src/compiler/GF/Compile/Compute/ConcreteNew.hs @@ -303,8 +303,8 @@ strsFromValue t = case t of vars <- [[(str2strings v, map sstr c) | (v,c) <- zip vv c0] | vv <- combinations v0] ] - VFV ts -> mapM strsFromValue ts >>= return . concat - VStrs ts -> mapM strsFromValue ts >>= return . concat + VFV ts -> concat # mapM strsFromValue ts + VStrs ts -> concat # mapM strsFromValue ts _ -> fail ("cannot get Str from value " ++ show t) |
