arc> (src atom)
(from "arc.arc")
(def atom (x)
(in type.x 'int 'num 'sym 'char 'string))
(define (ar-type x)
(cond ((ar-tagged? x) (vector-ref x 1)) ((pair? x) 'cons) ((symbol? x) 'sym) ((null? x) 'sym) ((procedure? x) 'fn) ((char? x) 'char) ((string? x) 'string) ((exint? x) 'int) ((number? x) 'num) ; unsure about this ((vector? x) 'vector) ((hash-table? x) 'table) ((output-port? x) 'output) ((input-port? x) 'input) ((tcp-listener? x) 'socket) ((exn? x) 'exception) ((thread? x) 'thread) ((thread-cell? x) 'thread-cell) ((keyword? x) 'keyword) (#t (err "Type: unknown type" x))))
[1] https://github.com/arclanguage/anarki/issues/40#issuecomment...
[2] http://arclanguage.org/item?id=19492