def _find_var(tokens, expander, expanded_names):
    """Return pending expanders when var is found in tokens."""
    for token in tokens:
        if check_var_function(token):
            # Found CSS variable, keep pending-substitution values.
            pending = PendingExpander(tokens, expander)
            return {name: pending for name in expanded_names}
Return pending expanders when var is found in tokens.
weasyprint/css/validation/expanders.py