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

(raylib.h specific) two structs are missing from output #2

Open
Brian-ED opened this issue Feb 8, 2025 · 3 comments
Open

(raylib.h specific) two structs are missing from output #2

Brian-ED opened this issue Feb 8, 2025 · 3 comments

Comments

@Brian-ED
Copy link
Owner

Brian-ED commented Feb 8, 2025

The following two structs aren't included in raylib.h, they're just shown as typedefs. I'm not sure how to define these, currently they're ignored. I think having them as opaque pointers is a good way to go.

typedef struct rAudioBuffer rAudioBuffer;
typedef struct rAudioProcessor rAudioProcessor;
@Brian-ED Brian-ED changed the title two structs are missing from output (raylib.h specific) two structs are missing from output Feb 8, 2025
@Brian-ED
Copy link
Owner Author

Brian-ED commented Feb 8, 2025

Worse than i thought, I do handle it manually with this code under remap:

  "rAudioBuffer"   ‿"ptr"
  "rAudioProcessor"‿"ptr"

@Brian-ED
Copy link
Owner Author

Brian-ED commented Feb 8, 2025

This is bad because it's manual. Any other libs having opaque typedefs wouldn't be handled correctly.

@Brian-ED
Copy link
Owner Author

Brian-ED commented Feb 8, 2025

Also relevant:

    # Read struct lines
    # Find structs
    # starting with "typedef struct ... {" or "typedef struct ... ; \n struct ... {"
    # ending with "} ... ;"
    # i.e. excluding "typedef struct rAudioBuffer rAudioBuffer;" -> Typedef and forward declaration only
  }¨/{
    [m1,m2]←"typedef struct"‿"struct"(⊣≡≠⊸↑)⌜ ∨`∘≠⟜' '⊸/¨𝕩
    m1∧m2 0⊸«⊸∨<´∘⊐⟜"{;"¨𝕩
  } lines

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

No branches or pull requests

1 participant