Commits

David McClosky committed 323e01f

Bugfix for printing head indices from Matt Gerber.

Comments (0)

Files changed (1)

second-stage/programs/features/tree.h

 
   const tree_node<label_type>* head_child = syntactic_head ? tree_syntacticHeadChild(t): tree_semanticHeadChild(t);
 
+  if (!head_child)
+    return 0;
+
   int head_num = 0;
   tree_node<label_type> *p = t->child;
   while(p != head_child)