Compare commits

...

3 Commits

Author SHA1 Message Date
seeseemelk 189c21667b Ignore intellij files 2026-04-28 16:07:46 +02:00
seeseemelk abdc6d67dc Re-order log lines 2026-04-28 16:06:21 +02:00
seeseemelk d89833b705 Add TYPES documentation 2026-04-28 16:06:12 +02:00
4 changed files with 41 additions and 1 deletions
+2
View File
@@ -1 +1,3 @@
/c2
/.idea/*
!/.idea/c_cpp_properties.json
+12
View File
@@ -0,0 +1,12 @@
{
"configurations": [
{
"name": "CLion",
"includePath": [
"${workspaceFolder}/v0/*"
],
"cStandard": "c89",
}
],
"version": 4
}
+25
View File
@@ -0,0 +1,25 @@
# Types
C2 has both built-in types and user-defined types.
## Builtin types
C2 has the following types builtin:
- `void`
- `i8`
- `i16`
- `i32`
- `i64`
- `u8`
- `u16`
- `u32`
- `u64`
## Type Aliases
Types can be aliased to different names using the alias keyword.
Here's a list of the default builtin aliases.
```c2
alias int = i32;
alias uint = u32;
alias char = u8;
alias string = char[];
```
+2 -1
View File
@@ -1,9 +1,10 @@
#include "log.h"
#include "util.h"
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <stdarg.h>
#include "util.h"
static LogError* s_logError = NULL;