Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Chapter 11. Function Parameters > Cdecl Calling Convention

11.7. Cdecl Calling Convention

When looking at pictures and commented assembly language code we have seen that function parameters are passed from right to left and the caller is responsible for adjusting the stack after calling the callee function. This is the so called cdecl calling convention in C and C++. It allows calling functions with variable number of parameters, for example, printf and scanf:

printf("result = %d", nVal);


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial


  
  • Safari Books Online
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint