how to name an anonymous referenceby omkellogg (Novice)
|on Dec 17, 2017 at 21:59 UTC||Need Help??|
omkellogg has asked for the wisdom of the Perl Monks concerning the following question:
Let there be a small language for creating annotations. (The actual case in point is section 7.4.15 in OMG IDL4, http://www.omg.org/spec/IDL/4.1/PDF).
Some annotations are predefined. In order to support both predefined annotations and user defined annotations, I would use an array, e.g.:
The idea is that the array is initialized with the predefined annotations, and user defined annotations are parsed and appended onto the same array later on.
In the example above, the predefined annotation autoid first defines an enum type AutoidKind with values SEQUENTIAL and HASH, and then shall define a parameter named value of the enum type just defined.
The notation $annotations-> for referencing the enum type does not work - probably because the declaration @annotations is still in progress at the point of reference.
Perhaps there is a different way to achieve what I am trying to do?Thanks.