Edited lookahead calculation