FFXIVClientStructs
FFXIVClientStructs copied to clipboard
CExporter stack trace
It looks like the c structs are a bit out of date with the csharp source, so I tried building/running your CExporter and got the following:
PS C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\bin\Debug\net5.0> ./CExporter.exe Unhandled exception. System.ArgumentException: Field passed in is not a marshaled member of the type 'FFXIVClientStructs.FFXIV.Client.UI.AddonEnemyList'. (Parameter 'fieldName') at System.Runtime.InteropServices.Marshal.OffsetOf(Type t, String fieldName) at CExporter.FieldInfoExtensions.GetFieldOffset(FieldInfo finfo) in C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\Program.cs:line 424 at CExporter.Exporter.<>c.<ProcessStruct>b__10_1(FieldInfo finfo) in C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\Program.cs:line 145 at System.Linq.EnumerableSorter
2.ComputeKeys(TElement[] elements, Int32 count)
at System.Linq.EnumerableSorter1.ComputeMap(TElement[] elements, Int32 count) at System.Linq.EnumerableSorter
1.Sort(TElement[] elements, Int32 count)
at System.Linq.OrderedEnumerable1.GetEnumerator()+MoveNext() at System.Linq.Lookup
2.Create(IEnumerable1 source, Func
2 keySelector, IEqualityComparer1 comparer) at System.Linq.GroupedEnumerable
2.GetEnumerator()
at CExporter.Exporter.ProcessStruct(Type type, StringBuilder header) in C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\Program.cs:line 147
at CExporter.Exporter.ProcessType(Type type, StringBuilder header) in C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\Program.cs:line 105
at CExporter.Exporter.Export(GapStrategy strategy) in C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\Program.cs:line 84
at CExporter.Program.Main(String[] _) in C:\Users\miked\Source\repos\FFXIVClientStructs\ida\CExporter\Program.cs:line 19`
I actually took a shot at "fixing" this issue, and was able to get past that particular one, but then ran into NUMEROUS other problems with errors due to problems with how the offsets are defined, particularly where different fields defined at the same offsets are translated to C unions, or where generic instantiations are required. I've been trying to modify the source to get around the issues, but given the sheer number of the issues I've encountered, I'm not sure how this program ever really "worked". Could that be why the current c header files this program creates are so out of date in the repository? In any event, having those files really is quite useful, so if there is any way you could take a whack at brining them up to date, that would be really helpful.
I was able to fix this issue in a local branch I created from a clone of this repository. Unfortunately, I do not know how to create a pull request that allows you to consider these fixes for inclusion into the main repository. I tried following the instructions, but it appears I am not able to create the branch for the fixes. So any help getting this to you would be appreciated.
fork your own, push to it, then in github web you can make a PR and select your branch/fork.
im reviewing this now.