Add a hook to obtain lval of the last reduction.
Overhaul of the hook from last commit.