That string is the docstring, accessible as t_WORD.__doc__
. The PLY library uses it to assign rules to functions.
In this case, PLY is using docstrings for its own purpose. The string is assigned to the __doc__
attribute, and anyone can read the string. In this case, PLY uses it to construct the parser.