emacs-devel
[Top][All Lists]
Advanced

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

Re: Copyright assignment and questions about package submission


From: Stefan Monnier
Subject: Re: Copyright assignment and questions about package submission
Date: Sat, 26 Dec 2020 17:01:39 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

>> Please fill the form below and send it to the FSF as instructed so they
>> can send you the relevant paperwork to sign.
> Thanks, I've sent the form.

BTW, I just looked at your package.

The code looks clean, but when I tried to enable it in my main Emacs
session it got stuck in `swsw-update`, apparently more specifically
inside `swsw--get-possible-ids` (see sample backtrace below obtained
with `debug-on-quit`).

It looks like your algorithm has a bad asymptotic complexity (my session
has currently 88 frames, most of them with a single window in it).


        Stefan



Debugger entered--Lisp error: (quit)
  (closure ((char-lists (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108)) t) (inner) (mapcar #'(lambda 
(outer) (cons outer inner)) (car char-lists)))((103 106 106 107 102 103))
  mapcan((closure ((char-lists (97 115 100 102 103 104 106 107 108) (97 115 100 
102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108)) t) (inner) (mapcar 
#'(lambda (outer) (cons outer inner)) (car char-lists))) ((97 97 97 97 97 97) 
(115 97 97 97 97 97) (100 97 97 97 97 97) (102 97 97 97 97 97) (103 97 97 97 97 
97) (104 97 97 97 97 97) (106 97 97 97 97 97) (107 97 97 97 97 97) (108 97 97 
97 97 97) (97 115 97 97 97 97) (115 115 97 97 97 97) (100 115 97 97 97 97) (102 
115 97 97 97 97) (103 115 97 97 97 97) (104 115 97 97 97 97) (106 115 97 97 97 
97) (107 115 97 97 97 97) (108 115 97 97 97 97) (97 100 97 97 97 97) (115 100 
97 97 97 97) (100 100 97 97 97 97) (102 100 97 97 97 97) (103 100 97 97 97 97) 
(104 100 97 97 97 97) (106 100 97 97 97 97) (107 100 97 97 97 97) (108 100 97 
97 97 97) (97 102 97 97 97 97) (115 102 97 97 97 97) (100 102 97 97 97 97) (102 
102 97 97 97 97) (103 102 97 97 97 97) (104 102 97 97 97 97) (106 102 97 97 97 
97) (107 102 97 97 97 97) (108 102 97 97 97 97) (97 103 97 97 97 97) (115 103 
97 97 97 97) (100 103 97 97 97 97) (102 103 97 97 97 97) (103 103 97 97 97 97) 
(104 103 97 97 97 97) (106 103 97 97 97 97) (107 103 97 97 97 97) (108 103 97 
97 97 97) (97 104 97 97 97 97) (115 104 97 97 97 97) (100 104 97 97 97 97) (102 
104 97 97 97 97) (103 104 97 97 97 97) ...))
  (if char-lists (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons 
outer inner)) (car char-lists))) (apply #'swsw--get-possible-ids (cdr 
char-lists))) (list nil))
  swsw--get-possible-ids((97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108))
  apply(swsw--get-possible-ids ((97 115 100 102 103 104 106 107 108) (97 115 
100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 
102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108)))
  (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons outer inner)) (car 
char-lists))) (apply #'swsw--get-possible-ids (cdr char-lists)))
  (if char-lists (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons 
outer inner)) (car char-lists))) (apply #'swsw--get-possible-ids (cdr 
char-lists))) (list nil))
  swsw--get-possible-ids((97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 106 
107 108))
  apply(swsw--get-possible-ids ((97 115 100 102 103 104 106 107 108) (97 115 
100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 
102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108)))
  (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons outer inner)) (car 
char-lists))) (apply #'swsw--get-possible-ids (cdr char-lists)))
  (if char-lists (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons 
outer inner)) (car char-lists))) (apply #'swsw--get-possible-ids (cdr 
char-lists))) (list nil))
  swsw--get-possible-ids((97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 106 
107 108) (97 115 100 102 103 104 106 107 108))
  apply(swsw--get-possible-ids ((97 115 100 102 103 104 106 107 108) (97 115 
100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 
102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108)))
  (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons outer inner)) (car 
char-lists))) (apply #'swsw--get-possible-ids (cdr char-lists)))
  (if char-lists (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons 
outer inner)) (car char-lists))) (apply #'swsw--get-possible-ids (cdr 
char-lists))) (list nil))
  swsw--get-possible-ids((97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 106 
107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 
108))
  apply(swsw--get-possible-ids ((97 115 100 102 103 104 106 107 108) (97 115 
100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 
102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108)))
  (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons outer inner)) (car 
char-lists))) (apply #'swsw--get-possible-ids (cdr char-lists)))
  (if char-lists (mapcan #'(lambda (inner) (mapcar #'(lambda (outer) (cons 
outer inner)) (car char-lists))) (apply #'swsw--get-possible-ids (cdr 
char-lists))) (list nil))
  swsw--get-possible-ids((97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 106 
107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 
108) (97 115 100 102 103 104 106 107 108))
  apply(swsw--get-possible-ids ((97 115 100 102 103 104 106 107 108) (97 115 
100 102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 
102 103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 
103 104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 
104 106 107 108) (97 115 100 102 103 104 106 107 108) (97 115 100 102 103 104 
106 107 108) (97 115 100 102 103 104 106 107 108)))
  (let ((acc 0) (len (swsw--get-id-length)) char-lists) (while (< acc len) 
(setq char-lists (cons swsw-id-chars char-lists)) (setq acc (1+ acc))) (apply 
#'swsw--get-possible-ids char-lists))
  (setq swsw-window-list nil swsw-ids (let ((acc 0) (len (swsw--get-id-length)) 
char-lists) (while (< acc len) (setq char-lists (cons swsw-id-chars 
char-lists)) (setq acc (1+ acc))) (apply #'swsw--get-possible-ids char-lists)))
  swsw-update()
  (progn (swsw-update) (if (eq swsw-display-function 'lighter) nil (funcall 
swsw-display-function t)) (add-hook 'window-configuration-change-hook 
#'swsw-update) (add-hook 'minibuffer-setup-hook #'swsw-update) (add-hook 
'minibuffer-exit-hook #'swsw-update) (add-hook 'after-delete-frame-functions 
#'swsw-update))
  (if swsw-mode (progn (swsw-update) (if (eq swsw-display-function 'lighter) 
nil (funcall swsw-display-function t)) (add-hook 
'window-configuration-change-hook #'swsw-update) (add-hook 
'minibuffer-setup-hook #'swsw-update) (add-hook 'minibuffer-exit-hook 
#'swsw-update) (add-hook 'after-delete-frame-functions #'swsw-update)) (if (eq 
swsw-display-function 'lighter) nil (funcall swsw-display-function nil)) 
(remove-hook 'window-configuration-change-hook #'swsw-update) (remove-hook 
'minibuffer-setup-hook #'swsw-update) (remove-hook 'minibuffer-exit-hook 
#'swsw-update) (remove-hook 'after-delete-frame-functions #'swsw-update))
  (let ((last-message (current-message))) (progn (set-default 'swsw-mode (cond 
((eq arg 'toggle) (not (default-value 'swsw-mode))) ((and (numberp arg) (< arg 
1)) nil) (t t)))) (if swsw-mode (progn (swsw-update) (if (eq 
swsw-display-function 'lighter) nil (funcall swsw-display-function t)) 
(add-hook 'window-configuration-change-hook #'swsw-update) (add-hook 
'minibuffer-setup-hook #'swsw-update) (add-hook 'minibuffer-exit-hook 
#'swsw-update) (add-hook 'after-delete-frame-functions #'swsw-update)) (if (eq 
swsw-display-function 'lighter) nil (funcall swsw-display-function nil)) 
(remove-hook 'window-configuration-change-hook #'swsw-update) (remove-hook 
'minibuffer-setup-hook #'swsw-update) (remove-hook 'minibuffer-exit-hook 
#'swsw-update) (remove-hook 'after-delete-frame-functions #'swsw-update)) 
(run-hooks 'swsw-mode-hook (if (default-value 'swsw-mode) 'swsw-mode-on-hook 
'swsw-mode-off-hook)) (if (called-interactively-p 'any) (progn 
(customize-mark-as-set 'swsw-mode) (if (and (current-message) (not (equal 
last-message (current-message)))) nil (let ((local "")) (message "Swsw mode 
%sabled%s" (if (default-value ...) "en" "dis") local))))))
  swsw-mode(toggle)
  funcall-interactively(swsw-mode toggle)
  call-interactively(swsw-mode record nil)
  command-execute(swsw-mode record)
  execute-extended-command(nil "swsw-mode" nil)
  funcall-interactively(execute-extended-command nil "swsw-mode" nil)
  call-interactively(execute-extended-command nil nil)
  command-execute(execute-extended-command)




reply via email to

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