NodeStack implementation