Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 12 additions & 13 deletions docs/error-messages/compiler-errors-1/compiler-error-c2033.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,34 @@
---
title: "Compiler Error C2033"
description: "Learn more about: Compiler Error C2033"
ms.date: 11/04/2016
ms.date: 09/10/2025
f1_keywords: ["C2033"]
helpviewer_keywords: ["C2033"]
---
# Compiler Error C2033

> 'identifier' : bit field cannot have indirection
> '*identifier*': bit field cannot have indirection

## Remarks

The bit field was declared as a pointer, which is not allowed.
Bit fields can't be declared as a pointer, reference, or array. For more information, see [C++ Bit Fields](../../cpp/cpp-bit-fields.md).

## Example

The following example generates C2033:

```cpp
// C2033.cpp
struct S {
int *b : 1; // C2033
// compile with: /c

struct S
{
int* ptr : 1; // C2033
int& ref : 1; // C2033
int arr[3] : 1; // C2033
};
```

Possible resolution:
## See also

```cpp
// C2033b.cpp
// compile with: /c
struct S {
int b : 1;
};
```
[Compiler Error C2531](../compiler-errors-2/compiler-error-c2531.md)