Thread: uint64_t please help

  1. #1
    Registered User
    Join Date
    Oct 2010
    Posts
    37

    uint64_t please help

    Hi everyone,

    I try to work with an uint64_t as followed:

    uint64_t a;

    a=a| 1 <<63;

    And it displays: "gf2m.c:71: warning: left shift count >= width of type". I don't know why. Please help me. Thanks a lot.

  2. #2
    Registered User
    Join Date
    Sep 2007
    Posts
    1,012
    Because 1 is an int, not a uint64_t. Use 1ULL, which is an unsigned long long, guaranteed to be at least 64 bits.

  3. #3
    Registered User
    Join Date
    Oct 2010
    Posts
    37
    Thanks so much cas

Popular pages Recent additions subscribe to a feed