smartparens icon indicating copy to clipboard operation
smartparens copied to clipboard

(require 'smartparens-org) doesn't load sp-local-pair's

Open thor314 opened this issue 4 years ago • 2 comments

Expected behavior

(require 'smartparens-org) loads org-specific local pairs

Actual behavior

I can see the functions are loaded, eg M-h f sp-org-point-after-left-square-bracket-p does show a value, but clicking into an org-buffer, and looking at sp-pairs are unchanged

Environment & version information

In recent enough smartparens you can call M-x sp-describe-system to generate this report. Please fill manually what we could not detect automatically. Edit the output as you see fit to protect your privacy. The content of the buffer underneath the line was copied to your clipboard. You can also edit it in this buffer and then copy the results manually.

  • smartparens version: 20210904.1621
  • Active major-mode: org-journal-mode
  • Smartparens strict mode: nil
  • Emacs version (M-x emacs-version): GNU Emacs 27.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.23, cairo version 1.16.0) of 2021-01-18, modified by Debian
  • Starterkit/Distribution: Vanilla
  • OS: gnu/linux

thor314 avatar Nov 22 '21 22:11 thor314

The pairs are defined for org-mode but you seem to be using org-journal-mode. I don't know that package, but if we assume it's the same as org mode, we can add it to the list of "autoloads" for the org definitions.

Fuco1 avatar Jan 18 '23 12:01 Fuco1

Actually, since that mode is derived from org-mode, the org definitions should also get loaded.

Note that sp-pairs is a global object while sp-local-pairs is the resolved and merged definitions valid for the current buffer. You should see the org defined pairs there.

Fuco1 avatar Jan 18 '23 12:01 Fuco1