diff -r docutils-0.3.7/parsers/rst/states.py docutils/parsers/rst/states.py 118c118 < from docutils.parsers.rst import directives, languages, tableparser, roles --- > from docutils.parsers.rst import directives, languages, tableparser 451a452,457 > if roles: > self.roles = roles > else: > import roles > self.roles = roles > 807,808c813,814 < role_fn, messages = roles.role(role, self.language, lineno, < self.reporter) --- > role_fn, messages = self.roles.role(role, self.language, lineno, > self.reporter)