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

Improve linking for internal headers #168

Merged
merged 3 commits into from
Mar 13, 2019
Merged

Conversation

chussong
Copy link
Contributor

This pull request makes the following changes:

  • Most struct declarations were of the form typedef struct name_s { /* data fields */ } name_t, but some were typedef'd anonymously (without name_s): typedef struct { /* data fields */ } name_t. This made it impossible to forward declare them. I have added the name_s part to all headers which omitted it.

  • A seemingly random selection of the internal headers had the extern "C" required for linking with C++, but many did not have it; also, most of the internal headers containing extern "C" used a style that differed from the style used in the public API headers, and some had extraneous semicolons which caused compiler warnings. I have added the directive to all internal headers and unified the style with that of the public API headers.

  • ps_lattice_internal.h required pocketsphinx_internal.h but did not include it, so it would not work unless pocketsphinx_internal.h was included first. I have added the missing #include directive.

@nshmyrev nshmyrev merged commit 6d6820f into cmusphinx:master Mar 13, 2019
@nshmyrev
Copy link
Contributor

Looks great, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants