What does ~(uint32_t) mean?

c, syntax

Solution

`~()` is actually two things:

- `(uint32_t)` is a cast.

- `~` is a bitwise complement operator.

Problem

I'm reading a bit of C code in an OS kernel that says ``` x & ~(uint32_t)CST_IEc; ``` What does the `~()` mean? It's a tilde followed by parentheses!

Original source