AST simplifier: optimize constant AST_CASE nodes before recursively descending