def METHOD_NAME(file_path: str) -> Callable[[Dict], bool]:
    """
    Returns a function which checks whether a build action belongs to the
    given file_path. This returned function can be used for filtering
    build actions in a compilation database to find build actions belonging
    to the given source file.
    """
    def describes_file(build_action) -> bool:
        return os.path.abspath(file_path) == os.path.abspath(
            os.path.join(build_action['directory'], build_action['file']))
    return describes_file