retrieve vars using reflection instead of static analysis