mardi 14 juin 2016

What does the colon operator indicate when used with declaration [duplicate]


This question already has an answer here:

I am working on a project which uses C++98, I found a code snippet like

#include <stdint.h>
class Toy {
    int64_t lID;
    int64_t eID : 48;
    short pID : 16;
};

I understand what int64_t does but am not able to understand the significance ": 48" and ": 16". Can someone please help me?


Aucun commentaire:

Enregistrer un commentaire