title: Python 3 regular expression to find multiline comment
body: <p>I'm trying to find comment blocks in PHP source code using regular expressions in Python 3. The PHP comments are in this format:</p>
  
  <pre><code>/**
   * This is a very short block comment
   */
  </code></pre>
  
  <p>Now I came up with the following regular expression:</p>
  
  <pre><code>'/\*\*[.]+?\*/'
  </code></pre>
  
  <p>I figure that -in combination with the DOTALL flag- should do it, but no. It doesn't find anything. Strange thing is that when I remove the trailing slash, like this:</p>
  
  <pre><code>'/\*\*[.]+?\*'
  </code></pre>
  
  <p>then it finds the following string:</p>
  
  <pre><code>/**\n\t*
  </code></pre>
  
  <p>I have no idea why the regex can't find an asterisk followed by a slash... I checked the file that I'm searching to double check I didn't have a typo in the comment (I didn't).
  Also a slash is no special character in regex, so I wouldn't have to escape it. (I tried, but it didn't help.)</p>
  
  <p>Can anyone tell me what's wrong with my regex? :)</p>
  
  <p>By the way, I also came across <a href="https://stackoverflow.com/questions/5898636/java-regular-expression-for-php-comment">this</a>! thread where someone tried to do the same in Java. The final winning answer finished his regular expression the same way I do now, so I'm clueless :( Could this be a bug in Python regex or am I completely missing something?</p>
  
  <p>Any help is much appreciated! :D</p>