Class UnresolvedCall

    • Constructor Detail

      • UnresolvedCall

        public UnresolvedCall​(CFG cfg,
                              CodeLocation location,
                              UnresolvedCall.ResolutionStrategy strategy,
                              boolean instanceCall,
                              java.lang.String targetName,
                              Expression... parameters)
        Builds the CFG call, happening at the given location in the program. The static type of this CFGCall is the one return type of the descriptor of target.
        Parameters:
        cfg - the cfg that this expression belongs to
        location - the location where the expression is defined within the source file. If unknown, use null
        strategy - the UnresolvedCall.ResolutionStrategy of the parameters of this call
        instanceCall - whether or not this is a call to an instance method of a unit (that can be overridden) or not.
        targetName - the name of the target of this call
        parameters - the parameters of this call
    • Method Detail

      • getTargetName

        public java.lang.String getTargetName()
        Yields the name of the target of this call.
        Returns:
        the name of the target
      • isInstanceCall

        public boolean isInstanceCall()
        Yields whether or not this is a call to an instance method of a unit (that can be overridden) or not.
        Returns:
        true if this call targets instance cfgs, false otherwise
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Call
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class Call
      • toString

        public java.lang.String toString()
        Specified by:
        toString in class Statement
      • callSemantics

        public <A extends AbstractState<A,​H,​V>,​H extends HeapDomain<H>,​V extends ValueDomain<V>> AnalysisState<A,​H,​V> callSemantics​(AnalysisState<A,​H,​V> entryState,
                                                                                                                                                                        InterproceduralAnalysis<A,​H,​V> interprocedural,
                                                                                                                                                                        AnalysisState<A,​H,​V>[] computedStates,
                                                                                                                                                                        ExpressionSet<SymbolicExpression>[] params)
                                                                                                                                                                 throws SemanticException
        Description copied from class: Call
        Computes the semantics of the call, after the semantics of all parameters have been computed. Meta variables from the parameters will be forgotten after this call returns.
        Specified by:
        callSemantics in class Call
        Type Parameters:
        A - the type of AbstractState
        H - the type of the HeapDomain
        V - the type of the ValueDomain
        Parameters:
        entryState - the entry state of this call
        interprocedural - the interprocedural analysis of the program to analyze
        computedStates - the array of states chaining the parameters' semantics evaluation starting from entryState, namely computedState[i] corresponds to the state obtained by the evaluation of params[i] in the state computedState[i-1] (params[0] is evaluated in entryState)
        params - the symbolic expressions representing the computed values of the parameters of this call
        Returns:
        the AnalysisState representing the abstract result of the execution of this call
        Throws:
        SemanticException - if something goes wrong during the computation
      • inheritRuntimeTypesFrom

        public void inheritRuntimeTypesFrom​(Expression other)
        Updates this call's runtime types to match the ones of the given expression.
        Parameters:
        other - the expression to inherit from