title: .Net regex matching $ with the end of the string and not of line, even with multiline enabled
body: <p>I'm trying to highlight markdown code, but am running into this weird behavior of the .NET regex multiline option.</p>
  
  <p>The following expression: <code>^(#+).+$</code> works fine on any online regex testing tool:</p>
  
  <p><a href="https://i.stack.imgur.com/C1BZn.png" rel="noreferrer"><img src="https://i.stack.imgur.com/C1BZn.png" alt="enter image description here"></a></p>
  
  <p>But it refuses to work with .net:</p>
  
  <p><a href="https://i.stack.imgur.com/Ntdrr.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Ntdrr.png" alt="enter image description here"></a></p>
  
  <p>It doesn't seem to take into account the $ tag, and just highlights everything until the end of the string, no matter what. This is my C#</p>
  
  <pre><code>RegExpression = new Regex(@"^(#+).+$", RegexOptions.Multiline)
  </code></pre>
  
  <p>What am I missing?</p>