class FunctionSignatureParser {

	DataType extractReturnType(String signatureText) throws ParseException {
		int parenIndex = signatureText.indexOf('(');
		if (parenIndex < 0) {
			throw new ParseException("Can't find return type");
		}
		String[] split = StringUtils.split(signatureText.substring(0, parenIndex));
		if (split.length < 2) {
			throw new ParseException("Can't find return type");
		}
		String returnTypeName = StringUtils.join(split, " ", 0, split.length - 1);

		DataType dt = resolveDataType(returnTypeName);
		if (dt == null) {
			throw new ParseException("Can't resolve return type: " + returnTypeName);
		}
		return dt;
	}

	public  FunctionSignatureParser(Program program, DataTypeManagerService service);

}