diff --git a/lib/marked.js b/lib/marked.js index d9e3bafeb1..6964429d35 100644 --- a/lib/marked.js +++ b/lib/marked.js @@ -561,7 +561,7 @@ var inline = { reflink: /^!?\[(label)\]\[(?!\s*\])((?:\\[\[\]]?|[^\[\]\\])+)\]/, nolink: /^!?\[(?!\s*\])((?:\[[^\[\]]*\]|\\[\[\]]|[^\[\]])*)\](?:\[\])?/, strong: /^__([^\s_])__(?!_)|^\*\*([^\s*])\*\*(?!\*)|^__([^\s][\s\S]*?[^\s])__(?!_)|^\*\*([^\s][\s\S]*?[^\s])\*\*(?!\*)/, - em: /^_([^\s_])_(?!_)|^\*([^\s*"<\[])\*(?!\*)|^_([^\s][\s\S]*?[^\s_])_(?!_|[^\spunctuation])|^_([^\s_][\s\S]*?[^\s])_(?!_|[^\spunctuation])|^\*([^\s"<\[][\s\S]*?[^\s*])\*(?!\*)|^\*([^\s*"<\[][\s\S]*?[^\s])\*(?!\*)/, + em: /^_([^\s_])_(?!_)|^\*([^\s*<\[])\*(?!\*)|^_([^\s<][\s\S]*?[^\s_])_(?!_|[^\spunctuation])|^_([^\s_<][\s\S]*?[^\s])_(?!_|[^\spunctuation])|^\*([^\s<"][\s\S]*?[^\s\*])\*(?!\*|[^\spunctuation])|^\*([^\s*"<\[][\s\S]*?[^\s])\*(?!\*)/, code: /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, br: /^( {2,}|\\)\n(?!\s*$)/, del: noop, diff --git a/test/specs/commonmark/commonmark.0.29.json b/test/specs/commonmark/commonmark.0.29.json index 9c52c13672..e080b070ff 100644 --- a/test/specs/commonmark/commonmark.0.29.json +++ b/test/specs/commonmark/commonmark.0.29.json @@ -3414,8 +3414,7 @@ "example": 418, "start_line": 6935, "end_line": 6939, - "section": "Emphasis and strong emphasis", - "shouldFail": true + "section": "Emphasis and strong emphasis" }, { "markdown": "** is not an empty emphasis\n", @@ -3909,8 +3908,7 @@ "example": 477, "start_line": 7399, "end_line": 7403, - "section": "Emphasis and strong emphasis", - "shouldFail": true + "section": "Emphasis and strong emphasis" }, { "markdown": "_a `_`_\n", diff --git a/test/specs/new/em_list_links.html b/test/specs/new/em_list_links.html new file mode 100644 index 0000000000..b52cd2a926 --- /dev/null +++ b/test/specs/new/em_list_links.html @@ -0,0 +1,55 @@ +
named link