emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master e38e7b7: Make syntax errors say the line/column they appear a


From: Lars Ingebrigtsen
Subject: Re: master e38e7b7: Make syntax errors say the line/column they appear at
Date: Tue, 02 Feb 2021 09:34:42 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> But, FWIW, I'd much rather that the error object contains "raw data"
> rather than "human-readable" data.  I.e. something like:
>
>     xsignal2 (Qinvalid_read_syntax, s, PT);
>
> and then convert the buf-pos to line+column later on, when the error
> is displayed.

Good idea; now fixed.

> [ And if we don't have any ready-made place where we can put
>   this display-time conversion, then we should probably change that
>   as well.  ]

We have the same thing with

forward-sexp: Scan error: "Containing expression ends prematurely", 373, 374

which is pretty cryptic, but `M-f' says

user-error: No next sexp

A general display conversion thing would be nice, but I guess some of
the conversions would be context dependent?  The invalid-read-syntax
line/column one wouldn't be, I think...

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no



reply via email to

[Prev in Thread] Current Thread [Next in Thread]