All files / vsl/scope/items scopeFuncItem.js

0% Statements 0/2
0% Branches 0/2
0% Functions 0/3
0% Lines 0/2
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28                                                       
import ScopeItem from '../scopeItem';
 
/**
 * Describes a function declaration. Usually a top, nested, or class-level
 * declaration.
 */
export default class ScopeFuncItem extends ScopeItem {
    
    /**
     * Creates a spot for a function in a scope. Use this when you need to
     * handle overloading etc. For lambdas you probably want to use a normal
     * 
     * @param {string} rootId - The root primary identifier of this type. (not mangled)
     */
    constructor(rootId: string, body: FunctionBody) {
        super(rootId);
    }
    
    /** @private */
    _equal(ref: ScopeFuncItem) {
        
    }
    
    /** @override */
    equal(ref: ScopeItem): boolean {
        return ref instanceof ScopeFuncItem && this._equal(ref);
    }
}