<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def compiler(self, target):
 """Returns the thrift compiler to use for the given target. :param target: The target to extract the thrift compiler from. :type target: :class:`pants.backend.codegen.thrift.java.java_thrift_library.JavaThriftLibrary` :returns: The thrift compiler to use. :rtype: string """

    self._check_target(target)
    return target.compiler or self._default_compiler