var_lookup() faster alternative