May I know what are bits fields & the 5 bits of hole for?

struct Record
		{
			unsigned int n1 : 3;	// 3 bits, can store 0 - 7
			int : 5; 			// 5 bits of hole
			unsigned int n2 : 4;	// 4 bits, can store 0 - 15
			//etc
		};
		
		0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 etc
		* * * H H H H H * * * * //etc

It means that bits 3-7 aren't relevant to the problem domain and that the programmer is ignoring whatever data they may happen to contain. You still need to take them into account in the bit field structure though so that the rest of your data lines up properly. Since they don't have a name associated with them, they are inaccessible. They are simply placeholders/filler/a "hole".

And actually, on most architectures it's more like this:

11 10 9 8 7 6 5 4 3 2 1 0
 *  * * * H H H H H * * *
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.