tromey / el-compilador

An SSA-based compiler for Emacs Lisp
206 stars 10 forks source link

extra handlerlist pop from unwind-protect #18

Closed tromey closed 7 years ago

tromey commented 7 years ago

The C output for a simple unwind-protect case, like:

; -*- lexical-binding:t -*-
(defun x ()
  (save-excursion
    (message "hi")))

Ends up with:

  PUSH_HANDLER (h1, Qnil, UNWIND_PROTECT);
  if (sys_setjmp (h1->jmp))
    {
      handlerlist = handlerlist->next;
      goto BB_1;
    }
...
BB_1:
  handlerlist = handlerlist->next;

One of these is redundant.