def _generate_lastnames_variations(lastnames):
if not lastnames:<EOL><INDENT>return []<EOL><DEDENT>split_lastnames = [split_lastname for lastname in lastnames for split_lastname in lastname.split('<STR_LIT:->')]<EOL>lastnames_variations = split_lastnames<EOL>if len(split_lastnames) > <NUM_LIT:1>:<EOL><INDENT>lastnames_variations.append(u'<STR_LIT:U+0020>'.join([lastname for lastname in split_lastnames]))<EOL><DEDENT>return lastnames_variations<EOL>
Generate variations for lastnames.

    Note:
        This method follows the assumption that the first last name is the main one.
        E.g. For 'Caro Estevez', this method generates: ['Caro', 'Caro Estevez'].
        In the case the lastnames are dashed, it splits them in two.