[SOLVED] warning: empty declaration| |error: parameter ‘mount_opts’ is initialized| error: array index in non-array initializer|...
ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
warning: empty declaration| |error: parameter ‘mount_opts’ is initialized| error: array index in non-array initializer|...
I do not no longer have any idea what to put i here to show anyone what it is I am looking at, or doing to give me the errors I am getting so I will just use the exact example that is now giving me the very same errors. when what I was using following the example was working just fine until hours later of coding. then all of a sudden it just started giving me these complaints and errors and no longer compiling completely.
Your example completely make that enum pointless, so what is the entire purpose of GNU and it telling me that their way is the correct way, especially when it was working and now you are showing me that GNU them grurs that invented coding (C) or something to do with it anyways are wrong?
||=== Build: Debug in mh (compiler: GNU GCC Compiler) ===|
/media/data/C-Projects/mh/mh/options.c|50|error: parameter ‘tile_opts’ is initialized|
/media/data/C-Projects/mh/mh/options.c|52|warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]|
/media/data/C-Projects/mh/mh/options.c|52|note: (near initialization for ‘tile_opts’)|
/media/data/C-Projects/mh/mh/options.c|53|warning: excess elements in scalar initializer|
/media/data/C-Projects/mh/mh/options.c|53|note: (near initialization for ‘tile_opts’)|
I do not no longer have any idea what to put i here to show anyone what it is I am looking at, or doing to give me the errors I am getting
You need to post a clear problem description based on the result of your own troubleshooting, the point at which you are stuck. Include the minimal code example which your own troubleshooting produced and which reproduces the specific problem, in isolation (independent of your application code as much as possible). See the Site FAQ, again, especially this, What makes a good issue description?.
Quote:
Originally Posted by BW-userx
I will just use the exact example that is now giving me the very same errors. when what I was using following the example was working just fine until hours later of coding. then all of a sudden it just started giving me these complaints and errors and no longer compiling completely.
Is the code that you posted the actual code giving you the error, or is it just the example that your own code is based on?
Code:
The original was...
const char *mount_opts[] =
{
... values
};
Is now...
const char *tile_opts [] =
{
... different values
};
The different value list would also probably mean that the enum declaration is different. Which is it?
Quote:
..working just fine until hours later of coding. then all of a sudden it just started giving me these complaints and errors and no longer compiling...
That is not a useful problem description.
When things have been working then suddenly begin producing errors, obviously something has changed. At that point you need to stop and look at what you had done between when it did work and when it did not.
What have you done to identify the changes? What have you done to troubleshoot and isolate the actual problem other than post here?
Last edited by astrogeek; 08-24-2017 at 03:26 PM.
Reason: Added "what to post" para, grammer changes
You need to post a clear problem description based on the result of your own troubleshooting, the point at which you are stuck. Include the minimal code example which your own troubleshooting produced and which reproduces the specific problem, in isolation (independent of your application code as much as possible). See the Site FAQ, again, especially this, What makes a good issue description?.
it is either one way or the other with you it seems
too much information, no its not enough information.
Quote:
Is the code that you posted the actual code giving you the error, or is it just the example that your own code is based on?
Code:
The original was...
const char *mount_opts[] =
{
... values
};
Is now...
const char *tile_opts [] =
{
... different values
};
The different value list would also probably mean that the enum declaration is different. Which is it?
That is not a useful problem description.
When things have been working then suddenly begin producing errors, obviously something has changed. At that point you need to stop and look at what you had done between when it did work and when it did not.
I got fed up with trying to find it so I just striped it out ---
I got fed up with trying to find it so I just striped it out ---
Without ever showing effort to troubleshoot your code nor to answer our questions.
So here we are again, another pointless, dead-end BW-userx thread in the LQ Programming forum.
You have been asked multiple times to end this posting pattern, and have been directed to the LQ posting guidelines, along with patient explanation of what you should include, and not include, in your posts. You have either ignored, or at the very least not demonstrated any effort to learn or apply those simple guidelines to your posts here.
This thread is being closed and you are being warned strongly that this pattern must end now.
From the Site FAQ to which you have been repeatedly referred:
Quote:
If you are unwilling or unable to ask questions in a manner that allows us to help you, it's unlikely our community will be able to provide you a solution. Unfortunately, serial offenders who show wanton disregard for this request after multiple pointers may be asked to seek help elsewhere. We truly hope that isn't necessary...
That is the ultimate endpoint toward which we are now headed. No one wants to get there, least of all myself. Please make effort to understand and apply the principles necessary for continued participation in these forums.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.