Re: [xml] adding "void *private" member to the struct xmlNs

I added "void *_private;" to the end of "struct xmlNs" and I hope
this will break nobody.


Daniel Veillard wrote:
On Sun, Jul 21, 2002 at 05:43:53PM -0700, Aleksey Sanin wrote:
Hi, Daniel!

This question was discussed some time ago but I could not understand
do we have any agreement or not. And  I would like to raise it again
because it looks like I need this functionality too :)

Argh ....

So the question is: can we add "void* private" member to the "struct xmlNs"?
This pointer will be used by application to store application specific data
and LibXML will simply always ignore it.
There were two suggestions:
    1) make struct xmlNs  similar to structures for other node types and put
    "void * private" on the second place (adv.: simplicity and following
    standard; dis. : this breaks binary compatibility)
    2) add "void* private" to the end of struct xmlNs (adv.: binary 
    dis.: "special case" for applications)
As far as I can understand, we could not go with option 1) because of 
compatibility. I would like to find out, can the implement option 2) 
 (it's ugly
but it gives me what I want :) ).

  then 2) please but make the field name "_private" like on the others
nodes. It also avoid the C++ reserved name problem.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]