Update cycle detection algorithm.
authorVincent Belaïche <vincentb1@users.sourceforge.net>
Mon, 27 Jun 2011 06:02:27 +0000 (08:02 +0200)
committerVincent Belaïche <vincentb1@users.sourceforge.net>
Mon, 27 Jun 2011 06:02:27 +0000 (08:02 +0200)
commit90ca8b4908934c72a5a6cec8cda73694278f4362
tree80ed8b6d5df82b3f68e2f30e66c37534ce5cf1a2
parent2bb63e814f7caaa565eaeeaa11a217956c5f4caa
Update cycle detection algorithm.
(ses-localvars): Add ses--Dijkstra-attempt-nb and
ses--Dijkstra-weight-bound, and initial values thereof when
applicable.
(ses-set-localvars): New function.
(ses-make-cell): Add property-list as a cell element.
(ses-cell-property-get-fun, ses-cell-property-get)
(ses-cell-property-delq-fun, ses-cell-property-set-fun)
(ses-cell-property-pop-fun, ses-cell-property-get-handle-fun): New
functions.
(ses-cell-property-set, ses-cell-property-pop)
(ses-cell-property-get-handle): New macro.
(ses-cell-property-handle-car, ses-cell-property-handle-setcar):
New aliases, used for code readability.
(ses-calculate-cell, ses-update-cells): Use Dijkstra algorithm for
cycle detection.
(ses-self-reference-early-detection): New defcustom.
(ses-formula-references): Robustify against self-refering cells.
(ses-mode): Use ses-set-localvars.
(ses-command-hook): Add call to ses-initialize-Dijkstra-attempt
before lauching the update processing.
(ses-initialize-Dijkstra-attempt): New function.
(ses-recalculate-cell): Update for cycle detection based on
Dijkstra algorithm.
lisp/ChangeLog
lisp/ses.el