diff options
| author | krasimir <krasimir@chalmers.se> | 2016-05-11 11:10:22 +0000 |
|---|---|---|
| committer | krasimir <krasimir@chalmers.se> | 2016-05-11 11:10:22 +0000 |
| commit | 86c54232752d14069cbb9b3089474d0299f9a20c (patch) | |
| tree | b502ee4110c41f7ae93c3976e607a3bdf61b49c0 /src/runtime/haskell-bind/examples | |
| parent | 9abc6aaddeb892015015f9f02d5a790701f1c8a2 (diff) | |
the Literals API in Haskell no longer offers the sentence as an argument to the callbacks. It is just as easy to save the sentence in a closure and by doing that we save the repeated round about from C to Haskell strings
Diffstat (limited to 'src/runtime/haskell-bind/examples')
| -rw-r--r-- | src/runtime/haskell-bind/examples/pgf-hsbind-trans.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/runtime/haskell-bind/examples/pgf-hsbind-trans.hs b/src/runtime/haskell-bind/examples/pgf-hsbind-trans.hs index 7487c04df..96808f906 100644 --- a/src/runtime/haskell-bind/examples/pgf-hsbind-trans.hs +++ b/src/runtime/haskell-bind/examples/pgf-hsbind-trans.hs @@ -50,7 +50,7 @@ translates pgf cfrom cto cat (mxt,mxv) s0 = cparse pgf concr cat input = parseWithHeuristics concr cat input (-1) callbacks where callbacks = maybe [] cb $ lookup "App" literalCallbacks - cb fs = [(cat,f pgf ("TranslateEng",concr))|(cat,f)<-fs] + cb fs = [(cat,f pgf ("TranslateEng",concr) input)|(cat,f)<-fs] lextext cnc = unwords . lexText' (\w -> case lookupMorpho cnc w of _:_ -> w |
