/*****************************************************************
 ** @author   STF 521
 ** @version  0.0.1
 ** @purpose  1:22.3.1, incompatible template in the to clause of the call operation
 ** @verdict  pass reject
 *****************************************************************/

// The following requirements are tested:
// f) All AddressRef items in the to clause and all VariableRef items in the sender clause
// shall be of type address, component or of the address type bound to the port type (see
// section 6.2.9) of the port instance referenced in the call operation.

module NegSem_220301_CallOperation_005 {

	signature S() return integer;

	type port P procedure {
		inout S;
	}

    type component GeneralComp {
		port P p;
	}

    testcase TC_NegSem_220301_CallOperation_005() runs on GeneralComp system GeneralComp {
        var charstring v_addr := "addr";
        var GeneralComp v_ptc := GeneralComp.create;
		connect(self:p, v_ptc:p);
		p.call(S:{}, nowait) to v_addr;
        setverdict(pass);
    }

    control {
        execute(TC_NegSem_220301_CallOperation_005(), 5.0);
    }
}