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
commit81f492931b11a6c7609d5450e9c93e7cae0a868a (patch)
tree01baf7d1b289b172ab7ca2e31809c5898d0332bb /extools/striped_grammar.h
parent686e494171c7b336c20349d7c38f3d2259ed5410 (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