How to call jQuery function with multiple parameters?

What does the compiler assume if no prototype of a function is mentioned and it directly encounter a user-defined function's call? like return types, no. and type of parameters?

  • I would like to know what parameters can i have as actual parameters or formal parameters and also the return type if no prototype of that function is declared. Also i would like to know the answwers referring to different compilers like gcc, visual studio, TC, etc.

  • Answer:

    When a function is not declared in a compilation unit, the c language specifies that the following implicit declaration is made: int f(); which is a function accepting any number of parameters and returning an int. The C99 standard removed this feature, which was still supported in C89. But typically compiler implementors hate to make changes which would prevent old programs from compiling, so in most cases implicit function declarations are accepted with a warning. There is usually an option to cause an error on missing prototypes (for example -Wmissing-prototypes when using gcc). In C++ prototypes are always required.

Gregory Popovitch at Quora Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.