format_gcc(self,
maxlines=-1,
maxtokens=-1)
Format error into a GCC-style message.
The message details include the failed token soup, this is
controlled with maxtokens .
The one-line message can be followed by quotation of the failed
block, this is controlled with maxlines .
-
- Parameters:
maxlines -
The maximum number of lines of the failed block to quote. If
not given or negative, there is no length limit on the quotation.
Ellipsis is used in the middle to represent the excluded
lines.
(type=int )
maxtokens -
The maximum number of tokens to dump (from the begining). If
not given or negative, there is no length limit on the soup
dump.
(type=int )
- Returns:
-
GCC-style formatted error message on the first line, possibly
followed quotation of the failed source code block, terminated
with a newline.
(type=str )
- Overrides:
yagdoc.common.DataError.format_gcc
|