in reply to Re: A data structure for XML generation
in thread A data structure for XML generation
If you've defined two explicit cases for $inner (scalar or array ref), you can always differentiate it from a hash ref, so why not just make the \%attr optional and just omit the empty hashes {}?Yes, I certainly thought of that. And you will often simply provide content without attributes, so I think that is a nice shorthand.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: A data structure for XML generation
by jrey (Initiate) on Aug 12, 2009 at 00:54 UTC |