import tokenize
import io
import token


def tokenize_composite_calc(calc_procedure):
    """tokenize a calculation procedure"""
    tokens = tokenize.generate_tokens(io.StringIO(calc_procedure).readline)
    return [t[token.NAME] for t in tokens if t[token.NAME]]