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

Multidimensional arrays different behaviour with compability mode #53

Closed
Misiur opened this issue Apr 5, 2015 · 1 comment
Closed

Comments

@Misiur
Copy link
Contributor

Misiur commented Apr 5, 2015

Try this snippet in standard compiler, and with this compiler in compability mode:

#include <a_samp>

new foo[3][2][] = {
    {"Bar","Bar"},
    {"Boo","Boo"},
    {"Bee","Bee"}
};

main() {
    printf("%d, %s", sizeof foo, foo[0][0]);
}

Expected result: All is well
Actual result: error 052, multidimensional-arrays must be fully initialized

No idea why, maybe new ellipsis support changed that.

edit: Compability mode doesn't matter, it still reports this error

@Zeex Zeex closed this as completed in 7314b56 Apr 6, 2015
@Zeex Zeex reopened this Apr 6, 2015
@Zeex
Copy link
Contributor

Zeex commented Apr 6, 2015

It compiles now but doesn't print the correct string, I'm looking into that.

@Zeex Zeex closed this as completed in 2e162ea Apr 6, 2015
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

2 participants