private _hasSuperCallForSameMethodName()

in src/tslint/overrideCallsSuperRule.ts [79:93]


    private _hasSuperCallForSameMethodName(node: ts.Node, methodName: string): boolean {
        const text = node.getText();
        let match: RegExpExecArray | null;

        while ((match = SUPER_REGEXP.exec(text))) {
            if (match[1] === methodName) {
                // This method is fine, so we can bail early.
                // Note: reseting the regex index so it is in a fresh state for its next use.
                SUPER_REGEXP.lastIndex = 0;
                return true;
            }
        }

        return false;
    }