Browse Source

Give indium-structs its own id generator

There is no reason indium-struct would use indium-client's id
generator.
drone
Damien Cassou 2 years ago
committed by Nicolas Petton
parent
commit
9722fb249c
1 changed files with 9 additions and 3 deletions
  1. +9
    -3
      indium-structs.el

+ 9
- 3
indium-structs.el View File

@ -40,8 +40,6 @@
(require 'map)
(require 'subr-x)
(declare-function indium-client--next-id "indium-client.el")
(cl-defstruct
(indium-location (:constructor indium-location-create)
(:constructor indium-location-at-point
@ -64,7 +62,7 @@
overlay
id))
(:copier nil))
(id (indium-client--next-id))
(id (indium-structs--next-breakpoint-id))
(overlay nil)
(resolved nil)
(condition ""))
@ -194,5 +192,13 @@ definitions."
property))
"")))
(defvar indium-structs--breakpoint-id 0
"A number that gets incremented by `indium-structs--next-breakpoint-id'.")
(defun indium-structs--next-breakpoint-id ()
"Return a number, different at each call."
(cl-incf indium-structs--breakpoint-id)
indium-structs--breakpoint-id)
(provide 'indium-structs)
;;; indium-structs.el ends here

Loading…
Cancel
Save