export function sanitizeVariable(input) {
    return input.replace(/^[^a-zA-Z_$]|[^\\w$]/g, '_');
}
export function collectPrototype(key, base, limit) {
    let c = base;
    const components = new Map();
    while (c !== limit) {
        if (c[key]) {
            Object.keys(c[key]).forEach((k) => components.set(k, c[key][k]));
        }
        c = Object.getPrototypeOf(c);
    }
    return components;
}
//# sourceMappingURL=util.js.map