diff options
| author | G. Branden Robinson <g.branden.robinson@gmail.com> | 2022-09-28 17:19:56 -0500 |
|---|---|---|
| committer | G. Branden Robinson <g.branden.robinson@gmail.com> | 2022-09-29 08:45:32 -0500 |
| commit | 316cfdd2ad3ff37b1c0c7d6af8877467fd0d2b8e (patch) | |
| tree | 4d8c42c1362ea6931abe9beab1dd030fddd2c624 /src/roff/troff/input.cpp | |
| parent | 9d408e5ce0f2e5e639142d33b8292778e954bfb4 (diff) | |
| download | groff-git-316cfdd2ad3ff37b1c0c7d6af8877467fd0d2b8e.tar.gz | |
[troff]: Make ambiguous \s error more helpful.
* src/roff/troff/input.cpp (read_size): Be more helpful to ambiguous
type size escape sequence users; offer advice in terms of the current
escape character.
This only goes so far; if they choose ' as their escape character, they
might need to do some thinking.
Diffstat (limited to 'src/roff/troff/input.cpp')
| -rw-r--r-- | src/roff/troff/input.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/roff/troff/input.cpp b/src/roff/troff/input.cpp index 7f0b17095..0597f7ade 100644 --- a/src/roff/troff/input.cpp +++ b/src/roff/troff/input.cpp @@ -5106,7 +5106,8 @@ static bool read_size(int *x) else { val = val*10 + (c - '0'); error("ambiguous type size in escape sequence; rewrite to use" - " '\\s(%1' or similar", val); + " '%1s(%2' or similar", static_cast<char>(escape_char), + val); } } val *= sizescale; |
