mirror of
https://github.com/libretro/cpp-cheat.git
synced 2025-04-08 14:02:03 +00:00
29 lines
522 B
C
29 lines
522 B
C
/*
|
|
# Literals
|
|
|
|
*Literals* are values that can be expressed through a single
|
|
language dedicated built-in syntax:
|
|
|
|
- int: `1`
|
|
- long: `1L`
|
|
- float: `1.0f`
|
|
- double: `1.0`and their
|
|
- char: `'a'`
|
|
- string: `"abc"`
|
|
|
|
Some base types do not have specific literals: e.g. `short`.
|
|
|
|
C99 introduces compound literals,
|
|
which allow creation of literals for user defined types:
|
|
|
|
- arrays
|
|
- structs
|
|
- unions
|
|
*/
|
|
|
|
#include "common.h"
|
|
|
|
int main() {
|
|
return EXIT_SUCCESS;
|
|
}
|