Further reimplementation