Method: difflib.HtmlDiff._make_prefix
Calls: 17, Exceptions: 0, Paths: 1Back
Path 1: 17 calls (1.0)
1def _make_prefix(self):
2 """Create unique anchor prefixes"""
3
4 # Generate a unique anchor prefix so multiple tables
5 # can exist on the same HTML page without conflicts.
6 fromprefix = "from%d_" % HtmlDiff._default_prefix
7 toprefix = "to%d_" % HtmlDiff._default_prefix
8 HtmlDiff._default_prefix += 1
9 # store prefixes so line format method has access
10 self._prefix = [fromprefix,toprefix]