Issue #119: moved some code inside DupAccumulator