<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def find_segment_highest_version(self, query=None, version=None, callback=None, recurse=True, default=None):
 """Finds the highest matching segment. Same parameters as find_segments(), but returns the match with the highest version, or default if no match is found."""

        # FIXME Test

        retval = None

        for s in self.find_segments(query=query, version=version, callback=callback, recurse=recurse):
            if not retval or s.header.version > retval.header.version:
                retval = s

        if retval is None:
            return default

        return retval