preserve order when auto-squashing typedefs
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 620
- Forks
- 79
- Avg merge
- 14h 27m
- Merged PRs (30d)
- 1
Description
I'm using F# where the order of declaring functions, structs, etc somewhat matters. If I can, I'd like to preserve that order (coming from a C header). the auto-squashing type defs would be nice, but when I iterate through the parsed children ICppDeclaration s they are thrown in after all the squashed classes, causing the order to break.
Would this be an easy fix, or should I just turn off auto-squashing and parse the typedefs?
by the way, thanks for making this! it's saving me a lot of time.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the auto-squashing implementation and the traversal that exposes parsed ICppDeclaration children; reproduce the ordering issue with a C header containing typedefs and declarations. Done means auto-squashing remains enabled while iterating children preserves the header declaration order for the reported F# use case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, csharp, fsharp
- Domain
- compilers
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100