From: Subramanya Sastry Date: Tue, 13 Aug 2013 17:27:48 +0000 (+0000) Subject: Revert "Make line breaks in
behave like
(bug 6200)." See bug... X-Git-Tag: 1.31.0-rc.0~18981^2 X-Git-Url: http://git.cyclocoop.org/%22%2C%20generer_url_ecrire%28?a=commitdiff_plain;h=8b9a8d568988d8f964b2b57954dc57f54bad3372;p=lhc%2Fweb%2Fwiklou.git Revert "Make line breaks in
behave like
(bug 6200)." See bug 52763 This reverts commit b9d0e5e4e763aa58647f88739ed0e5682685d064. Change-Id: I9451f7d11fe01085e4289b21b2e905751bdbf800 --- diff --git a/RELEASE-NOTES-1.22 b/RELEASE-NOTES-1.22 index b9890a0457..cfe553ebad 100644 --- a/RELEASE-NOTES-1.22 +++ b/RELEASE-NOTES-1.22 @@ -255,7 +255,6 @@ production. revision as second argument now, rather than just the current section. * (bug 49694) $wgSpamRegex is now also applied on the new section headline text adding a new topic on a page -* (bug 6200) line breaks in
are handled like they are in
* (bug 41756) Improve treatment of multiple comments on a blank line. === API changes in 1.22 === diff --git a/includes/parser/Parser.php b/includes/parser/Parser.php index 1bba876b42..8fdf4072c0 100644 --- a/includes/parser/Parser.php +++ b/includes/parser/Parser.php @@ -2450,10 +2450,10 @@ class Parser { wfProfileIn( __METHOD__ . "-paragraph" ); # No prefix (not in list)--go to paragraph mode # XXX: use a stack for nestable elements like span, table and div - $openmatch = preg_match( '/(?:mUniqPrefix . '-pre|<\\/li|<\\/ul|<\\/ol|<\\/dl|<\\/?center)/iS', $t ); + '/(?:<\\/table|<\\/blockquote|<\\/h1|<\\/h2|<\\/h3|<\\/h4|<\\/h5|<\\/h6|' . + 'mUniqPrefix . '-pre|<\\/li|<\\/ul|<\\/ol|<\\/dl|<\\/?center)/iS', $t ); if ( $openmatch or $closematch ) { $paragraphStack = false; # TODO bug 5718: paragraph closed diff --git a/tests/parser/parserTests.txt b/tests/parser/parserTests.txt index 41d49d1e16..0715ae683e 100644 --- a/tests/parser/parserTests.txt +++ b/tests/parser/parserTests.txt @@ -1352,6 +1352,8 @@ Regression with preformatted in
!! end +# Expected output in the following test is not really expected (there should be +#
 in the output) -- it's only testing for well-formedness.
 !! test
 Bug 6200: Preformatted in 
!! input @@ -1360,53 +1362,7 @@ Bug 6200: Preformatted in
!! result
-
Blah
-
-
- -!! end - -!! test -Bug 51086: Double newlines in blockquotes should be turned into paragraphs -!! input -
-Foo - -Bar -
-!! result -
-

Foo -

Bar -

-
- -!! end - -!! test -Bug 15491: / in blockquote -!! input -
-Foo bar baz quux -
-!! result -
-

Foo bar baz quux -

-
- -!! end - -# Note that the p-wrapping is newline sensitive, which could be -# considered a bug: tidy will wrap only the 'Foo' in the example -# below in a

tag. (see comment 23-25 of bug #6200) -!! test -Bug 15491: / in blockquote (2) -!! input -

Foo bar baz quux -
-!! result -
Foo bar baz quux + Blah
!! end @@ -1921,8 +1877,7 @@ c
-
foo
-
+ foo
foo
@@ -13523,6 +13478,9 @@ __NOEDITSECTION__
 

!! end +# Expected output in the following test is not necessarily expected (there +# should probably be

tags inside the

in the output) -- it's +# only testing for well-formedness. !! test Bug 6200: blockquotes and paragraph formatting !! input @@ -13535,8 +13493,7 @@ bar baz !! result
-

foo -

+foo

bar

@@ -14216,6 +14173,8 @@ B # Bug 6200:
should behave like
with respect to line breaks !! test Bug 6200: paragraphs inside blockquotes (no extra line breaks) +!! options +disabled !! input
Line one @@ -14228,6 +14187,8 @@ Line two
!! test Bug 6200: paragraphs inside blockquotes (extra line break on open) +!! options +disabled !! input
Line one @@ -14243,6 +14204,8 @@ Line two
!! test Bug 6200: paragraphs inside blockquotes (extra line break on close) +!! options +disabled !! input
Line one @@ -14258,6 +14221,8 @@ Line two !! test Bug 6200: paragraphs inside blockquotes (extra line break on open and close) +!! options +disabled !! input
Line one