bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#42088: [feature/native-comp] Lockup on opening TypeScript files


From: Andrea Corallo
Subject: bug#42088: [feature/native-comp] Lockup on opening TypeScript files
Date: Sun, 28 Jun 2020 10:43:22 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux)

Okay after some digging I think I've an idea of what is going on:

the code was hanging in `typescript--ensure-cache' in the loop

(cl-loop while (re-search-forward typescript--quick-match-re-func nil t)...

This because typescript--quick-match-re-func is not set correctly going
back and back this is because `typescript--available-frameworks' is set
to nil.

IIUC the reason for that is: cl-macs is expanding cl-loop using various
`--cl-var--', these looks the same but each of this is a separete
uninterned symbol.  The native compiler squash them all toghether having
to pass them through the reader and a simple testcase like this fails to
behave as expected.

===
(require 'cl-lib)

(defun foo ()
  (cl-loop for xxx in '(a b)
           for yyy = xxx
           do (print xxx)))
===

This fails only compiling for dynamic scope because in lexical all
--cl-vars-- are absorbed as slots in the execution stack.

I suspect the solution is to have some renaming performed by the native
compiler not to confuse them.

  Andrea

--
akrl@sdf.org





reply via email to

[Prev in Thread] Current Thread [Next in Thread]