Currently we are losing the connection between the structure enum parameter value and the enum definition itself in PHP.
The following thrift parameter which is using GroupType enum:
Is compiled to PHP:
Which means that we cannot say on PHP side if that is a regular i32 or an enum.
Why do I need that?
I am using lowercase enum values instead of integers in database and on the frontend. Currently converting them by manually specifying the Enum Classes for enum parameters for each Structure which is not scalable, more difficult to maintain and growing over time.
This also makes it impossible to validate fields by Enum values on php side.