mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Closes #864: Fix crash with some settings of :confval:modindex_common_prefix
.
This commit is contained in:
parent
5b63fbfd44
commit
a6512317bf
2
CHANGES
2
CHANGES
@ -20,6 +20,8 @@ Release 1.1.3 (in development)
|
|||||||
* #860: Do not crash when encountering invalid doctest examples, just
|
* #860: Do not crash when encountering invalid doctest examples, just
|
||||||
emit a warning.
|
emit a warning.
|
||||||
|
|
||||||
|
* #864: Fix crash with some settings of :confval:`modindex_common_prefix`.
|
||||||
|
|
||||||
|
|
||||||
Release 1.1.2 (Nov 1, 2011) -- 1.1.1 is a silly version number anyway!
|
Release 1.1.2 (Nov 1, 2011) -- 1.1.1 is a silly version number anyway!
|
||||||
======================================================================
|
======================================================================
|
||||||
|
@ -525,7 +525,8 @@ class PythonModuleIndex(Index):
|
|||||||
# it's a submodule
|
# it's a submodule
|
||||||
if prev_modname == package:
|
if prev_modname == package:
|
||||||
# first submodule - make parent a group head
|
# first submodule - make parent a group head
|
||||||
entries[-1][1] = 1
|
if entries:
|
||||||
|
entries[-1][1] = 1
|
||||||
elif not prev_modname.startswith(package):
|
elif not prev_modname.startswith(package):
|
||||||
# submodule without parent in list, add dummy entry
|
# submodule without parent in list, add dummy entry
|
||||||
entries.append([stripped + package, 1, '', '', '', '', ''])
|
entries.append([stripped + package, 1, '', '', '', '', ''])
|
||||||
|
Loading…
Reference in New Issue
Block a user