[Lldb-commits] [PATCH] Use SIZE_MAX instead of SIZE_T_MAX for portability.

Chris Lattner clattner at apple.com
Wed Feb 16 10:48:00 PST 2011


On Feb 15, 2011, at 8:05 PM, Stephen Wilson wrote:

> 
> diff --git a/include/lldb/Core/ArchSpec.h b/include/lldb/Core/ArchSpec.h
> index 198722c..3bb14ac 100644
> --- a/include/lldb/Core/ArchSpec.h
> +++ b/include/lldb/Core/ArchSpec.h
> @@ -12,6 +12,8 @@
> 
> #if defined(__cplusplus)
> 
> +#include <stdint.h>

stdint.h isn't portable.  Please use llvm/Support/DataTypes.h.  Alternatively you can just use something like "~(size_t)0".

-Chris

> +
> #include "lldb/lldb-private.h"
> #include "llvm/ADT/Triple.h"
> 
> @@ -348,10 +350,10 @@ protected:
> private:
> 
>     void
> -    MachOArchUpdated (size_t macho_idx = SIZE_T_MAX);
> +    MachOArchUpdated (size_t macho_idx = SIZE_MAX);
> 
>     void
> -    ELFArchUpdated (size_t idx = SIZE_T_MAX);
> +    ELFArchUpdated (size_t idx = SIZE_MAX);
> };
> 
> 
> 
> _______________________________________________
> lldb-commits mailing list
> lldb-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits





More information about the lldb-commits mailing list