I am testing code that works in CF 11 for an upgrade to CF 2023. I have a component that extends another component and overrides the type of a property in the base component. Here is some simple pseudo code demonstrating the components:
Base.cfc:
component accessors="true" {
property name="myData" type="query";
}
Extend.cfc:
component extends="Base" accessors="true" {
property name="myData" type="array";
public Extend function init() {
setmyData([]);
return THIS;
}
}
When Extend.init() is called, an error is thrown saying that the value is not of type "query". This code works fine in CF 11. Has something changed since that won't allow this, or, is there a workaround?
Thanks,
Eric