aboutsummaryrefslogtreecommitdiff
path: root/code/main.felan
blob: 3af33e4995342a55797312aaf36ff5f08687e3ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
@import("basic.felan");

/*
t :: (comptime formatter : string) macro -> void {
  i := 0;
  in := 0;
  opening := 0;
  while @cast(i,u64) < formatter.length {
    c := formatter[i];
    if c == '{' {
      if in == 0 {
        opening = i+1;
      }
      in += 1;
    } else if c == '}' {
      in -= 1;
      if in == 0 {
        return sub_string(formatter,opening,i);
      } else if in < 0 {
        in = 0;
      }
    }
    i += 1;
  }
  return "";
};
*/

main :: () -> void {
  v := vector_new(i64);

  push_back(&v,32);

  println(v.capacity);
  println(v[0]);

  delete(v);
};