Skip to Main Content
C Programming: Visual Quickstart Guide
book

C Programming: Visual Quickstart Guide

by Larry Ullman, Marc Liyanage
October 2004
Beginner content levelBeginner
408 pages
9h 24m
English
Peachpit Press
Content preview from C Programming: Visual Quickstart Guide

Creating Inline Functions

New to C99 is the ability to create inline functions: user-defined functions that will, theoretically, perform faster. Inline functions are normally defined before the main function and are preceded with the keyword inline. For example:

#include <stdio.h>
inline int my_func() {
   // Function content.
}
int main (void) {...

Inline functions do not require the prototype, because they are defined before the main function.

These types of function definitions have the potential to be faster because the compiler treats them differently. Instead of setting aside the resources necessary for defining a new function, the compiler will go through an application's code, replacing calls to the inline function with the function code ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Intermediate C Programming

Intermediate C Programming

Yung-Hsiang Lu
Data Structures Using C

Data Structures Using C

Samir Kumar Bandyopadhyay, Kashi Nath Dey

Publisher Resources

ISBN: 0321287630Purchase book