smartparens
smartparens copied to clipboard
Quotes being autoescaped in python-mode and in emacs-lisp-mode even if I disable this feature
Expected behavior
With disabled quotes escaping, quotes shouldn't be escaped with the backward slash. E.g in the case like:
a = "some| string"
typing "
should result in a = "some" string"
Actual behavior
Result is a = "some\" string"
I've noticed that it happens in python and elisp buffers. As far as I can tell, javascript buffers are respecting the setting.
Steps to reproduce the problem
Disable autoescaping with the
(setq sp-escape-quotes-after-insert nil
sp-escape-wrapped-region nil)
Go to python buffer and try to insert a quote insite of the string literal or a variable.
Environment & version information
-
smartparens
version: This commit https://github.com/Fuco1/smartparens/commit/3bdc4cab439854358374698e36078547755ddaae - Active major-mode: python-mode
- Emacs version (
M-x emacs-version
): 26.1 - Spacemacs/Evil/Other starterkit (specify which)/Vanilla: Smartparens + Evil, no starter kit
- OS: Arch Linux
I also have this problem. Spacemacs.
Hello, I'm also experimenting this issue, I read the entry in the manual but I'm not exactly sure how to add the 'escape
action, can we get a one-liner right there in the docs? In fact I'm not even sure that solves this problem or if its even about achieving the behavior desired in this issue, I find it rather confusing to be honest 🤔 .
I have the same problem, but in different modes:
- NOT in Emacs Lisp mode (unlike the OP)
- in sh-mode
Possibly in other modes too. I bump into this problem often, but never paid attention to what modes are affected. I'll look at it now and update if I get the same behaviour in other modes.
It took me a while to pinpoint the problem (since I had
(sp-escape-quotes-after-insert nil)
I thought this behaviour must be set somewhere else and I spent forever trying to find out where. But uninstalling smartparens solved the issue).
- smartparens: 20191015.1754
- Emacs: 26.3-1
- OS: 5.3.12-arch1-1