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

MunitTest.name and MunitSuite_.prefix should be const char* #54

Open
albert-chang0 opened this issue May 9, 2019 · 0 comments
Open

Comments

@albert-chang0
Copy link

I believe it's because we have the pedantic flag with gcc, but compiling unit tests against munit I get warnings about discarded qualifiers. This is because I initialize a struct with a const string similar to what's in the example. It doesn't show up in default gcc, so I believe it's one of my stricter compilation flags (likely pedantic).

It's not exactly as simple as changing the type qualifier in the struct to be const char* instead of char* since when I took a brief scan over some of the functions, it looks like there could actually be some modifications to the strings.

Fix should be simply to allocate new strings on the heap and copy/concatenate things over. I'm willing to help out when I can.

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