New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor element/text base class #359
Conversation
5834d17
to
65fc6cd
Compare
65fc6cd
to
771bf27
Compare
94ce132
to
10b6d3a
Compare
Renamed "fraternal" nodes to "non-attribute nodes", updated XmlComment to be a subclass, and changed XmlNode::New so that it creates the correct kind of subclasses (fixes #226) |
It could also be called a We could easily move that same logic into this sub class instead, just as long as it's in one place. |
@rc0x03 I also moved |
I'm going to extract the memory fix for adding/merging text nodes into a separate PR that can be merged without delay. I will leave the refactoring of the Element/Text base class for later consideration. The correction of the wrapper selection for child nodes, etc. is technically a bug fix, but it also impacts usage, since nodes returned from some operations won't respond to the same API as before the change. So it would be kinder not to shoehorn it into a minor release. |
Bug fixes extracted to #362. Once that is merged, will rebase this PR to exclude those commits. |
Factored out common methods in Element/Text.
Couldn't come up with a decent name for the result; would welcome suggestions.Perhaps more importantly: Noticed some memory issues when adding text siblings. It may be good to patch those before letting this out into the wild. Working on a fix, but wanted to get a clean refactor out first.( Bug fixes in #362 )