musictypes.scm 340 B

1234567891011121314151617
  1. (require easy)
  2. (def (pitch-integer? v)
  3. (and (exact-integer? v)
  4. (<= -99 v 99)))
  5. (def (pitchclass-integer? v)
  6. (and (exact-integer? v)
  7. (<= 0 v 11)))
  8. (definterface pitchtype
  9. (defclass (pitch [pitch-integer? integer]))
  10. (defclass (pitchclass [pitchclass-integer? integer])))
  11. (def chord? (list-of integer?))