victorhge / iedit

Modify multiple occurrences simultaneously
https://www.emacswiki.org/emacs/Iedit
402 stars 43 forks source link

Is there a reason for commented-out requirement of cl-lib? #135

Closed lelit closed 2 years ago

lelit commented 2 years ago

I'm facing a problem apparently very similar to issue #117.

After some investigation, it seems that it's due to incorrect byte compilation (I'm using Doom and thus straight, that automatically byte compiles included packages): effectively iedit-lib.el was patched in that commit to use cl-case instead of case.

Near the top of that source there is a commented out (eval-when-compile (require 'cl-lib)): if I uncomment that line (and recompile with doom compile), everything works as expected.

So, is there a specific reason why it was commented out (in commit 7a6a0d65)?

Thanks in advance and happy xmas!

victorhge commented 2 years ago

I guess I thought cl-lib was not used at that time. # Strange enough, with or without that line, the compile result code is the same. I have submit a commit to recall it back.

lelit commented 2 years ago

Thank you! Maybe the same should be applied to iedit-rect.el, as it uses cl-rotatef macro?

lelit commented 2 years ago

Strange enough, with or without that line, the compile result code is the same.

I guess that depends whether you do the compilation with/without preloaded cl-lib, in other words if you do emacs -Q -f byte-compile-file you would hit the issue.