Hi, I'm curious if there is a documented/accepted way to give source code locations with error messages from macros. I noticed that some of the objects passed to a macro have meta data that contains a line number, but other objects, like symbols, do not. And I don't see any filenames. I was imagining something like this...
(defmacro something [a ...] (if (not (symbol? a)) (let [loc (get-source-location a)] (throwf "file: %s line: %s a should be a symbol" (loc :file) (loc :line) ... Thoughts? thanks, Rob --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---