#lang racket/base
;;; SPDX-License-Identifier: LGPL-3.0-or-later
;;; SPDX-FileCopyrightText: Copyright © 2021 Tony Garnock-Jones <tonyg@leastfixedpoint.com>

(provide (struct-out entity-ref)
         parse-Ref!)

(struct entity-ref (relay target attenuation) #:transparent)

(define (parse-Ref! r)
  (if (entity-ref? r)
      r
      (error 'parse-Ref! "Expected entity-ref; got ~v" r)))
