Page MenuHomePhabricator

pre_in_lists.patch

Authored By
bzimport
Nov 21 2014, 8:13 PM
Size
1007 B
Referenced Files
None
Subscribers
None

pre_in_lists.patch

Index: Parser.php
===================================================================
--- Parser.php (revision 57771)
+++ Parser.php (working copy)
@@ -1989,7 +1989,6 @@
// elements.
$prefix2 = str_replace( ';', ':', $prefix );
$t = substr( $oLine, $prefixLength );
- $this->mInPre = (bool)$preOpenMatch;
} else {
# Don't interpret any other prefixes in preformatted text
$prefixLength = 0;
@@ -2014,7 +2013,7 @@
$output .= $term . $this->nextItem( ':' );
}
}
- } elseif( $prefixLength || $lastPrefixLength ) {
+ } elseif( $prefixLength || ( $lastPrefixLength && !$this->mInPre ) ) {
// We need to open or close prefixes, or both.
# Either open or close a level...
@@ -2049,6 +2048,10 @@
$lastPrefix = $prefix2;
}
+ if (!$this->mInPre) {
+ $this->mInPre = (bool)$preOpenMatch;
+ }
+
// If we have no prefixes, go to paragraph mode.
if( 0 == $prefixLength ) {
wfProfileIn( __METHOD__."-paragraph" );

File Metadata

Mime Type
text/x-diff
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1428
Default Alt Text
pre_in_lists.patch (1007 B)

Event Timeline