chjj/marked — pull request #371 by izuzak (2014-03-23 08:35:57+00:00)
Title: Allow un-closed fenced code blocks

This fixes https://github.com/atom/markdown-preview/issues/13

In GFM, if you open a fenced code block and never close it -- a code block is created that spans until the end of the file. I have to admit that it's arguable if this is a bug or a feature, but since that behavior in GFM is not likely to change soon and people seem to rely on it -- it makes sense to match it in marked.

Currently, marked creates a code block only if both an opening and a closing codefence is found. So, this PR
* changes the `fences` regex so that it detects fenced code blocks even if no closing codefence is found
* adds tests to verify the new behavior