michaelrsweet / mxml

Tiny XML library.
https://www.msweet.org/mxml
Apache License 2.0
451 stars 163 forks source link

MXML_NO_PARENT is documented but is not defined #334

Closed chad-earthscope closed 22 minutes ago

chad-earthscope commented 3 hours ago

The MXML_NO_PARENT value is documented as an input value for many functions, e.g. https://www.msweet.org/mxml/mxml.html#mxmlNewElement

but is not set anywhere in v4.0.3 (that I can find).

In v3.3.1 for example this was defined in mxml.h:

#  define MXML_NO_PARENT        0       /* No parent for the node */

So I'm using NULL with mxmlNewElement() instead, which appears to work as desired.

michaelrsweet commented 2 hours ago

OK, that's a holdover from Mini-XML 3.x, and using NULL is the correct approach.

michaelrsweet commented 22 minutes ago

[master 61eddf1] Update docos (Issue #334)