llvm.org GIT mirror llvm / 37e8bde
Fix build breakage on alpha, without causing it on x86. as a bonus, all platforms can invent the same number of unique names now git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28596 91177308-0d34-0410-b5e6-96231b3b80d8 Andrew Lenharth 14 years ago
4 changed file(s) with 5 addition(s) and 16 deletion(s). Raw diff Collapse all Expand all
5454 return std::string(BufPtr);
5555 }
5656
57 static inline std::string utostr(unsigned long X, bool isNeg = false) {
58 return utostr(static_cast(X), isNeg);
59 }
60
61 static inline std::string utostr(unsigned X, bool isNeg = false) {
57 static inline std::string utostr(uint32_t X, bool isNeg = false) {
6258 char Buffer[20];
6359 char *BufPtr = Buffer+19;
6460
8278 return utostr(static_cast(X));
8379 }
8480
85 static inline std::string itostr(long X) {
86 if (X < 0)
87 return utostr(static_cast(-X), true);
88 else
89 return utostr(static_cast(X));
90 }
91
92 static inline std::string itostr(int X) {
81 static inline std::string itostr(int32_t X) {
9382 if (X < 0)
9483 return utostr(static_cast(-X), true);
9584 else
291291
292292 /// This value is used to retain the last unique value used
293293 /// by getUniqueName to generate unique names.
294 mutable unsigned long LastUnique;
294 mutable uint64_t LastUnique;
295295
296296 /// @}
297297
137137 /// @{
138138 private:
139139 TypeMap tmap; ///< This is the mapping of names to types.
140 mutable unsigned long LastUnique; ///< Counter for tracking unique names
140 mutable uint64_t LastUnique; ///< Counter for tracking unique names
141141
142142 /// @}
143143
126126 /// @{
127127 private:
128128 ValueMap vmap; ///< The map that holds the symbol table.
129 mutable unsigned long LastUnique; ///< Counter for tracking unique names
129 mutable uint64_t LastUnique; ///< Counter for tracking unique names
130130
131131 /// @}
132132