parameters: (doc)
return_statement: return match_compatibility.subn(r'', doc)[0], compatibility_notes
docstring: Parse and remove compatibility blocks from the main docstring.
  
    Args:
      doc: The docstring that contains compatibility notes"
  
    Returns:
      a tuple of the modified doc string and a hash that maps from compatibility
      note type to the text of the note.
docstring_summary: Parse and remove compatibility blocks from the main docstring.
docstring_tokens: Parse and remove compatibility blocks from the main docstring .
function: def _handle_compatibility(doc):
    """Parse and remove compatibility blocks from the main docstring.
  
    Args:
      doc: The docstring that contains compatibility notes"
  
    Returns:
      a tuple of the modified doc string and a hash that maps from compatibility
      note type to the text of the note.
    """
    compatibility_notes = {}
    match_compatibility = re.compile(r'[ \t]*@compatibility\((\w+)\)\s*\n'
                                     r'((?:[^@\n]*\n)+)'
                                     r'\s*@end_compatibility')
    for f in match_compatibility.finditer(doc):
      compatibility_notes[f.group(1)] = f.group(2)
    return match_compatibility.subn(r'', doc)[0], compatibility_notes
function_tokens: def _handle_compatibility ( doc ) : compatibility_notes = { } match_compatibility = re . compile ( r'[ \t]*@compatibility\((\w+)\)\s*\n' r'((?:[^@\n]*\n)+)' r'\s*@end_compatibility' ) for f in match_compatibility . finditer ( doc ) : compatibility_notes [ f . group ( 1 ) ] = f . group ( 2 ) return match_compatibility . subn ( r'' , doc ) [ 0 ] , compatibility_notes