Lazy allocation. (so Document not for parsing don't need to allocate stack). Remove redundant stackCapacity member variable.