Skip to content

Commit

Permalink
Merge pull request #1303 from aduh95/patch-1
Browse files Browse the repository at this point in the history
add hard line break when backslash at EOL
  • Loading branch information
styfle authored Jul 6, 2018
2 parents f459cd6 + 35db435 commit 2f86d94
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/marked.js
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ var inline = {
strong: /^__([^\s][\s\S]*?[^\s])__(?!_)|^\*\*([^\s][\s\S]*?[^\s])\*\*(?!\*)|^__([^\s])__(?!_)|^\*\*([^\s])\*\*(?!\*)/,
em: /^_([^\s][\s\S]*?[^\s_])_(?!_)|^_([^\s_][\s\S]*?[^\s])_(?!_)|^\*([^\s][\s\S]*?[^\s*])\*(?!\*)|^\*([^\s*][\s\S]*?[^\s])\*(?!\*)|^_([^\s_])_(?!_)|^\*([^\s*])\*(?!\*)/,
code: /^(`+)\s*([\s\S]*?[^`]?)\s*\1(?!`)/,
br: /^ {2,}\n(?!\s*$)/,
br: /^( {2,}|\\)\n(?!\s*$)/,
del: noop,
text: /^[\s\S]+?(?=[\\<!\[`*]|\b_| {2,}\n|$)/
};
Expand Down
4 changes: 2 additions & 2 deletions test/specs/commonmark/commonmark-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ describe('CommonMark 0.28 Backslash escapes', function() {
var section = 'Backslash escapes';

// var shouldPassButFails = [];
var shouldPassButFails = [290, 291, 293, 300, 301];
var shouldPassButFails = [290, 291, 300, 301];

var willNotBeAttemptedByCoreTeam = [];

Expand Down Expand Up @@ -409,7 +409,7 @@ describe('CommonMark 0.28 Hard line breaks', function() {
var section = 'Hard line breaks';

// var shouldPassButFails = [];
var shouldPassButFails = [611, 606, 609, 613];
var shouldPassButFails = [613];

var willNotBeAttemptedByCoreTeam = [];

Expand Down

0 comments on commit 2f86d94

Please sign in to comment.