return simpleError(Sets.newHashSet(new VariableTypeClashException(kex))); String msg = "Could not infer a sort for variable " + fails + " to match every location."; KException kex = new KException(ExceptionType.ERROR, KExceptionGroup.CRITICAL, msg, loc.source().orElse(null), loc.location().orElse(null)); return simpleError(Sets.newHashSet(new VariableTypeClashException(kex))); return simpleError(Sets.newHashSet(new ParseFailedException(kex))); msg = msg.substring(0, msg.length() - 2); KException kex = new KException(ExceptionType.ERROR, KExceptionGroup.CRITICAL, msg, loc.source().orElse(null), loc.location().orElse(null)); return simpleError(Sets.newHashSet(new VariableTypeClashException(kex))); return simpleError(Sets.newHashSet(new VariableTypeClashException(kex))); } else {