Optimize DataTreeCandidate.applyToModification()
Both implementations use recursive calls to themselves. Instead of recursion,
we can use a simplistic single-linked stack of operations and iterate over
them.
While this results in object allocation, these objects are short-lived
and never leak from current thread, which means they are easily
collected. Since the call is not recursive, JIT should be able to more
easily inline and optimize the operations.
Change-Id: I7d82a58c6be3e853ea5bcf9069876370804cb199
Signed-off-by: Robert Varga <rovarga@cisco.com>