Skip to main content

Compiler Error C0089

Message: Interface of overridden method '{0}' of interface '{1}' does not match declaration

Possible error cause: The signature of the implemented method does not match the signature of the method in the interface.

Error correction: Make sure that the same return types and parameters are declared.

Example 372. Example of the error:
PROGRAM PLC_PRG
VAR
     inst : FB;
END_VAR

INTERFACE XY
METHOD METH1
VAR_INPUT
    iPar : INT;
END_VAR

FUNCTION_BLOCK FB IMPLEMENTS XY
VAR
END_VAR
METHOD METH1
VAR_INPUT
END_VAR

Message:

C0089: Interface of overridden method 'METH1' of interface 'XY' does not match declaration