Fuco1 / smartparens

Minor mode for Emacs that deals with parens pairs and tries to be smart about it.
GNU General Public License v3.0
1.82k stars 195 forks source link

The delete-selection property on sp-[backward-]delete-char is broken with strict mode #1196

Open Fuco1 opened 6 months ago

Fuco1 commented 6 months ago

Normally we place 'supersede but if strict mode is activated anywhere, it will get replaced with a custom smartparens check. However, the symbol property is global so it will now start working also in non-strict buffers. Further, if any strict buffer is turned non-strict, we reset the property which will then break all the strict buffers.

The solution is to always have the same custom smartparens check which will internally check strict mode status and decide based on that what to do.