From 86c54232752d14069cbb9b3089474d0299f9a20c Mon Sep 17 00:00:00 2001 From: krasimir Date: Wed, 11 May 2016 11:10:22 +0000 Subject: 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 --- src/runtime/haskell-bind/examples/pgf-hsbind-trans.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/runtime/haskell-bind/examples') 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 -- cgit v1.2.3