Skip to content

Instantly share code, notes, and snippets.

@kaworu
Created November 18, 2013 20:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kaworu/7535144 to your computer and use it in GitHub Desktop.
Save kaworu/7535144 to your computer and use it in GitHub Desktop.
/*
* ui64.cpp
*
*/
#include <iostream>
#define UINT64_C(C) C##ui64
int
main(int argc, char *argv[])
{
uint64_t x, a = 42;
x = std::max(a, UINT64_C(41));
std::cout << x << std::endl;
return (0);
}
@kaworu
Copy link
Author

kaworu commented Nov 18, 2013

% g++ ui64.cpp 
ui64.cpp:13:1: error: invalid suffix "ui64" on integer constant

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment