Alejandro Mery
17 years ago
1 changed files with 54 additions and 0 deletions
@ -0,0 +1,54 @@ |
|||||||
|
# --- SDE-COPYRIGHT-NOTE-BEGIN ---
|
||||||
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch.
|
||||||
|
#
|
||||||
|
# Filename: package/.../asciidoc/hotfix-undefined_b.patch
|
||||||
|
# Copyright (C) 2007 The OpenSDE Project
|
||||||
|
#
|
||||||
|
# More information can be found in the files COPYING and README.
|
||||||
|
#
|
||||||
|
# This patch file is dual-licensed. It is available under the license the
|
||||||
|
# patched project is licensed under, as long as it is an OpenSource license
|
||||||
|
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
|
||||||
|
# of the GNU General Public License as published by the Free Software
|
||||||
|
# Foundation; either version 2 of the License, or (at your option) any later
|
||||||
|
# version.
|
||||||
|
# --- SDE-COPYRIGHT-NOTE-END ---
|
||||||
|
|
||||||
|
Taken from http://hg.sharesource.org/asciidoc/raw-rev/8b6d11203ed3
|
||||||
|
|
||||||
|
# HG changeset patch
|
||||||
|
# User Stuart Rackham <srackham@methods.co.nz>
|
||||||
|
# Date 1197344594 -46800
|
||||||
|
# Node ID 8b6d11203ed3729ed597fc7ca876bde205d271a1
|
||||||
|
# Parent 386e75a49a1ae3437581fae97a5d5c27c82ba5fb
|
||||||
|
b variable used before assignment
|
||||||
|
|
||||||
|
An error is generated using the asciidoc -e option when
|
||||||
|
there are no block definitions.
|
||||||
|
|
||||||
|
Patch submitted by Alejandro Mery
|
||||||
|
|
||||||
|
--- a/asciidoc.py Tue Dec 11 11:10:45 2007 +1300
|
||||||
|
+++ b/asciidoc.py Tue Dec 11 16:43:14 2007 +1300
|
||||||
|
@@ -2061,16 +2061,13 @@ class AbstractBlocks:
|
||||||
|
def validate(self):
|
||||||
|
'''Validate the block definitions.'''
|
||||||
|
# Validate delimiters and build combined lists delimiter pattern.
|
||||||
|
+ delimiters = []
|
||||||
|
for b in self.blocks:
|
||||||
|
assert b.__class__ is self.BLOCK_TYPE
|
||||||
|
b.validate()
|
||||||
|
- if b.is_conf_entry('delimiter'):
|
||||||
|
- delimiters = []
|
||||||
|
- for b in self.blocks:
|
||||||
|
- b.validate()
|
||||||
|
- if b.delimiter:
|
||||||
|
- delimiters.append(b.delimiter)
|
||||||
|
- self.delimiter = join_regexp(delimiters)
|
||||||
|
+ if b.delimiter:
|
||||||
|
+ delimiters.append(b.delimiter)
|
||||||
|
+ self.delimiter = join_regexp(delimiters)
|
||||||
|
|
||||||
|
class Paragraph(AbstractBlock):
|
||||||
|
def __init__(self):
|
||||||
|
|
Loading…
Reference in new issue