[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#44653: 28.0.50; sql-mode gets confused about string literals
From: |
Lars Ingebrigtsen |
Subject: |
bug#44653: 28.0.50; sql-mode gets confused about string literals |
Date: |
Mon, 16 Nov 2020 23:42:56 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Dale Sedivec <dale@codefu.org> writes:
> 2. Evaluate the following in *scratch*:
>
> (let ((buf (generate-new-buffer "sql")))
> (switch-to-buffer buf)
> (sql-mode)
> (insert "select '''")
> (goto-char 1)
> (delete-region 1 8)
> (goto-char (point-max)))
>
> Point should now be at the end of an `sql-mode' buffer containing
> "'''" (three apostrophes).
>
> 4. Press backspace to erase the third apostrophe.
>
> 5. M-: (nth 3 (syntax-ppss)) RET
>
> Expected result: fourth element of syntax-ppss, the delimiter character
> for the current string, is nil, since we are no longer in a string
>
> Observed result: fourth element is ?' (39), indicating that point is
> still inside a string
>
> My first guess is that this is related to commit 289d6b2265e and #40231.
Yes, sounds likely. I've added Florian to the Cc's -- perhaps he has
some comments here.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no