crystal: improve error message
[jackhill/mal.git] / crystal / types.cr
index 44855e0..6f68ed0 100644 (file)
@@ -1,3 +1,5 @@
+require "./printer"
+
 module Mal
   class Symbol
     property :str
@@ -47,6 +49,10 @@ module Mal
       @is_macro
     end
 
+    def to_s
+      pr_str(self)
+    end
+
     def ==(other : Type)
       @val == other.unwrap
     end