summaryrefslogtreecommitdiff
path: root/extools/striped_grammar.h
diff options
context:
space:
mode:
authorredpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-07-19 18:57:02 +0000
committerredpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-07-19 18:57:02 +0000
commitbcf8d448430312fcf6270e3ba2e304ac58650312 (patch)
treee4c6c9dd12ec55d2d6b6606e8b5b5b14b5d95c43 /extools/striped_grammar.h
parent49e4f80136dd573c8b08c06426724de2d51bb784 (diff)
use lexer instead of handwritten parser
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@319 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'extools/striped_grammar.h')
-rw-r--r--extools/striped_grammar.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/extools/striped_grammar.h b/extools/striped_grammar.h
index cdf529d6..bf3aec7d 100644
--- a/extools/striped_grammar.h
+++ b/extools/striped_grammar.h
@@ -49,6 +49,8 @@ typedef std::tr1::unordered_map<std::vector<WordID>, RuleStatistics, boost::hash
struct StripedGrammarLexer {
typedef void (*GrammarCallback)(WordID lhs, const std::vector<WordID>& src_rhs, const ID2RuleStatistics& rules, void *extra);
static void ReadStripedGrammar(std::istream* in, GrammarCallback func, void* extra);
+ typedef void (*ContextCallback)(const std::vector<WordID>& phrase, const ID2RuleStatistics& rules, void *extra);
+ static void ReadContexts(std::istream* in, ContextCallback func, void* extra);
};
#endif