code: private Term evalLangMatches(Function term) {
  		final String SELECT_ALL = "*";
  		
  		/*
  		 * Evaluate the first term
  		 */
  		Term teval1 = eval(term.getTerm(0));
  		if (teval1 == null) {
  			return valueNull; // ROMAN (10 Jan 2017): not valueFalse
  		}
  		/*
  		 * Evaluate the second term
  		 */
  		Term innerTerm2 = term.getTerm(1);
  		if (innerTerm2 == null) {
  			return valueNull; // ROMAN (10 Jan 2017): not valueFalse
  		}
  
  		/*
  		 * Term checks
  		 */
  		if (teval1 instanceof Constant && innerTerm2 instanceof Constant) {
  			String lang1 = ((Constant) teval1).getValue();
  			String lang2 = ((Constant) innerTerm2).getValue();	
  			if (lang2.equals(SELECT_ALL)) {
  				if (lang1.isEmpty()) 
  					return termFactory.getFunctionIsNull(teval1);
  				else 
  					return termFactory.getFunctionIsNotNull(teval1);
  			} 
  			else {
  				return termFactory.getBooleanConstant(lang1.equals(lang2));
  			}
  		} 
  		else if (teval1 instanceof Variable && innerTerm2 instanceof Constant) {
  			Variable var = (Variable) teval1;
  			Constant lang = (Constant) innerTerm2;
  			if (lang.getValue().equals(SELECT_ALL)) {
  				// The char * means to get all languages
  				return termFactory.getFunctionIsNotNull(var);
  			} else {
  				return termFactory.getFunctionEQ(var, lang);
  			}
  		} 
  		else if (teval1 instanceof Function && innerTerm2 instanceof Function) {
  			Function f1 = (Function) teval1;
  			Function f2 = (Function) innerTerm2;
  			if(f1.isOperation()){
  				return term;
  			}
  			return evalLangMatches(termFactory.getLANGMATCHESFunction(f1.getTerm(0),
  					f2.getTerm(0)));
  		} 
  		else {
  			return term;
  		}
  	}
docs: /*
  Expression evaluator for langMatches() function