comment = re.compile(r'/*(.*?)*/', re.DOTALL) comment.findall(text2) [' this is a\n multiline comment ']