aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.mike/enum1.C
blob: 89e8542b779bac52db992505b0b710e935cd04af (plain)
1
2
3
4
5
6
7
8
9
10
11
// Build don't link:
// Warn if a enum cannot fit into a small bit-field.

enum TypeKind { ATK, BTK, CTK, DTK } ;

struct Type {
  enum TypeKind kind : 1;		// WARNING - 
  void setBTK();
};

void Type::setBTK() { kind = DTK; }