summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Dyer <cdyer@cs.cmu.edu>2011-03-09 00:50:38 -0500
committerChris Dyer <cdyer@cs.cmu.edu>2011-03-09 00:50:38 -0500
commit95ea293005f74a627fdd2aae318d5746fa8c4e6c (patch)
tree9915fbe8adea8166e9c84004ae435b42ee267202
parent1469b5394deee4ae80a2498cfab120fc9f11b319 (diff)
print empty line when parse fails
-rw-r--r--decoder/decoder.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/decoder/decoder.cc b/decoder/decoder.cc
index 03b98415..239c8620 100644
--- a/decoder/decoder.cc
+++ b/decoder/decoder.cc
@@ -743,11 +743,13 @@ bool DecoderImpl::Decode(const string& input, DecoderObserver* o) {
translator->SentenceComplete();
if (!translation_successful) {
- if (!SILENT) cerr << " NO PARSE FOUND.\n";
+ if (!SILENT) { cerr << " NO PARSE FOUND.\n"; }
o->NotifySourceParseFailure(smeta);
o->NotifyDecodingComplete(smeta);
if (conf.count("show_conditional_prob")) {
cout << "-Inf" << endl << flush;
+ } else if (!SILENT) {
+ cout << endl;
}
return false;
}