Update Stack implementation