# C backend: fix enough that zig test works · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/d2f9646d98615d85589d2c46237559d1249f2765)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: d2f9646d98615d85589d2c46237559d1249f2765

Requested commit: d2f9646d98615d85589d2c46237559d1249f2765

Commit: d2f9646d98615d85589d2c46237559d1249f2765

Tree: 87c2297912251993970a282703f688c72932e228

Author: Andrew Kelley

Committer: Andrew Kelley

## Message

```
C backend: fix enough that zig test works

 * test_functions: properly add dependencies of the array on test
   functions and test names so that the order comes out correctly.
 * fix lowering of struct literals to add parentheses around the type
   name.
 * omit const qualifier in slices because otherwise slices cannot be
   reassigned even when they are local variables.
 * special case pointer to functions and double pointer to functions in
   renderTypeAndName. This code will need to be cleaned up but for now
   it helps us make progress on other C backend stuff.
 * fix slice element access to lower to `.ptr[` instead of `[`.
 * airSliceElemVal: respect volatile slices

```

## Parents

- [234d94e42b832dd17eb9144f5523e03ef4fa8eb3](https://git.cafe/gitcafe/zig/commit/234d94e42b832dd17eb9144f5523e03ef4fa8eb3?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/d2f9646d98615d85589d2c46237559d1249f2765?format=markdown)
