Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFC: add type dependency ordering #98

Merged
merged 1 commit into from
Aug 12, 2014
Merged

RFC: add type dependency ordering #98

merged 1 commit into from
Aug 12, 2014

Conversation

kmsquire
Copy link
Collaborator

I got around to adding dependency ordering for types (which has decreased my work in wrapping libav/ffmpeg significantly!). I'm not sure if or how this fits in with your other ideas (cf. Build EAR tool in #33), but if you haven't made much progress in that arena, this might be useful.

  • Introduce an ExprUnit type for grouping together expressions
    (e.g., enums), specifying dependencies, and maintaining
    wrapped/output status
  • Removed cache_wrapped (subsumed above)
  • empty_structs is now a Set
  • type declarations, enums, and typealiases are stored in the
    common_buf, along with dependency information.
  • All enum Exprs are grouped together in the same ExprUnit
  • For other Exprs, there is one ExprUnit per Expr
  • Before outputting, the common_buf OrderedDict is dumped to an
    array with dependencies properly ordered. (Circular
    dependecies are implicitly detected, but remain.)
  • Function declarations are wrapped as before (in an array)

Note: this subsumes #96, although those changes can be backed out. I find it useful having blank lines in the output, though.

* Introduce an ExprUnit type for grouping together expressions
  (e.g., enums), specifying dependencies, and maintaining
  wrapped/output status
* Removed cache_wrapped (subsumed above)
* empty_structs is now a Set

* Type declarations, enums, and typealiases are stored in the
  common_buf, along with dependency information.
* All enum Exprs are grouped together in the same ExprUnit
* For other Exprs, there is one ExprUnit per Expr
* Before outputting, the common_buf OrderedDict is dumped to an
  array with dependencies properly ordered.  (Circular
  dependecies are implicitly detected, but remain.)

* Function declarations are wrapped as before (in an array)
@ihnorton
Copy link
Collaborator

I haven't had a chance to test this, but otherwise LGTM if it's working for you.

kmsquire added a commit that referenced this pull request Aug 12, 2014
RFC: add type dependency ordering
@kmsquire kmsquire merged commit 2dc889e into master Aug 12, 2014
@kmsquire kmsquire deleted the kms/type_ordering branch August 12, 2014 05:17
melonedo pushed a commit to melonedo/Clang.jl that referenced this pull request Jul 20, 2021
README: add GHA badge, remove Travis badge, remove AV badge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants