fix: `variable` must execute pending tactics and elaboration problems

closes #2226
closes #3214
3 files changed