Function: eca-uuid
eca-uuid is a natively compiled function defined in eca-util.el.
Signature
(eca-uuid)
Documentation
Return a fresh v4-style UUID string.
Uses Emacs's pseudo-random generator reseeded from system entropy
on every call so consecutive ids inside the same Emacs session do
not repeat across, e.g., quickly-clicked "+ new chat" tabs. Used
for client-generated chatId values sent to the eca server.
Source Code
;; Defined in /nix/store/jklqzw6pzz6j4jrbv8wy0iwgi7jlrbld-emacs-packages-deps/share/emacs/site-lisp/elpa/eca-20260928.1827/eca-util.el
(defun eca-uuid ()
"Return a fresh v4-style UUID string.
Uses Emacs's pseudo-random generator reseeded from system entropy
on every call so consecutive ids inside the same Emacs session do
not repeat across, e.g., quickly-clicked \"+ new chat\" tabs. Used
for client-generated `chatId' values sent to the eca server."
(random t)
(format "%04x%04x-%04x-4%03x-%01x%03x-%04x%04x%04x"
(random 65536) (random 65536)
(random 65536)
(logand (random 65536) #x0fff)
(logior #x8 (logand (random 16) #x3))
(logand (random 65536) #x0fff)
(random 65536) (random 65536) (random 65536)))