src/English/edt/en_PronounLinkerUtils.cpp
// returns parent's headword. If said headword is a copula, we tack on the parent's head's first postmodifier

returns parent's headword. If said headword is a copula, we tack on the parent's head's first postmodifier
returns parent ' s headword . If said headword is a copula we tack on the parent ' s head ' s first postmodifier
Symbol EnglishPronounLinkerUtils::getAugmentedParentHeadWord(const SynNode *node) {
	if(node == NULL || node->getParent() == NULL)
		return SymbolConstants::nullSymbol;
	Symbol result = node->getParent()->getHeadWord();
	if(WordConstants::isTensedCopulaTypeVerb(result)) {
		const SynNode *parentHead = node->getParent()->getHead();
		int firstPostmodIndex = parentHead->getHeadIndex()+1;
		if(firstPostmodIndex < parentHead->getNChildren()) {
			Symbol pair[] = {result, parentHead->getChild(firstPostmodIndex)->getHeadWord()};
			result = combineSymbols(pair, 2);
		}
	}
	return result;
}
Symbol EnglishPronounLinkerUtils :: getAugmentedParentHeadWord ( const SynNode * node ) { if ( node == NULL || node -> getParent ( ) == NULL ) return SymbolConstants :: nullSymbol ; Symbol result = node -> getParent ( ) -> getHeadWord ( ) ; if ( WordConstants :: isTensedCopulaTypeVerb ( result ) ) { const SynNode * parentHead = node -> getParent ( ) -> getHead ( ) ; int firstPostmodIndex = parentHead -> getHeadIndex ( ) + 1 ; if ( firstPostmodIndex < parentHead -> getNChildren ( ) ) { Symbol pair [ ] = { result , parentHead -> getChild ( firstPostmodIndex ) -> getHeadWord ( ) } ; result = combineSymbols ( pair , 2 ) ; } } return result ; }
returns parent's headword.
returns parent ' s headword .
//append first postmodifier if it exists
