Skip to content

Document define-symbol-macro macro #537

Description

@jcubic

It's part of Devin Wiki.

It was created as a helper to define the vector literals #, but it's not actually documented (on the website, it only has a docstring).

;; Example: Vector literal syntax
(define-symbol-macro SPLICE (vector-literal "#" . args)
  (if (not (or (pair? args) (eq? args '())))
      (throw (new Error "vector require pair"))
      (let ((v (list->array args)))
        (Object.freeze v)
        v)))

Related issues:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions