Hi,
we are switching our C# editor from the old WinForms version (14.1.320) to the latest WPF version. And we are using the parse data to extract informations about the code files. To get all the necessary informations we need to resolve the type references of parameters and return types in methods.
So in this scenario there is no active editor view. We just go through all type definitions in the source files of IProjectAssembly. When we come to a parameter of type IParameterDefinition, we use the resolver to get the type definition (ITypeDefinition) of the corresponding type reference (ITypeReference).
I finally was able to resolve most of the type definitions correctly, but the members of an enum declaration are not in their original order. Instead they are sorted alphabetically, which makes it impossible to get the corresponding integer value. For local enums I can parse the syntax tree, because I have the SourceFileLocation, but for external declarations I am relyant on the infos I receive from the resolver.
Is there any other way to get the values of an external enum declaration, base on the ITypeDefinition instance? Or at least get the members in the correct order?
Best regards, Tobias Lingemann.