I wonder if it would good to have something indicating the struct name put in the metadata when creating a struct?
On Fri, Nov 14, 2008 at 1:42 PM, Chouser <[EMAIL PROTECTED]> wrote: > > On Fri, Nov 14, 2008 at 2:11 PM, Jeff Rose <[EMAIL PROTECTED]> wrote: > > Does my dispatch function have to inspect the passed in values to > > figure out which type of struct they are, or can I query that > > somehow? > > My understanding is that StructMaps are just Maps with an > implementation that's optimized to reduce memory usage. The different > basis types don't really function as "classes" of StractMaps or > anything. You can still add new keys to StructMaps, for example, just > like any other Map. So if you want some kind of 'type' data do > dispatch off of, you'll have to attach that yourself, either as > another key that all your Maps share or as metadata. > > --Chouser > > > > --~--~---------~--~----~------------~-------~--~----~ 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 To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~----------~----~----~----~------~----~------~--~---