MATLAB: Generate HDL error: Reference to non-existent field ‘hasVariantError’.

fpgagenerate hdlgenerate vhdlhdlHDL Codersimulinkvhdl

When generating HDL or performing a "Run Compatibility Checker" the operation fails with the error
Reference to non-existent field 'hasVariantError'.
I've tried commenting out blocks but it doesnt seem to help.

Best Answer

As a follow-up I cleared out the mex files, deleted the SLPRJ folder & work folder from the project and the HDL is now being generated ok.