mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-20 03:23:01 +02:00
Changed Allocate to use size_t instead of unsigned.
llvm-svn: 66602
This commit is contained in:
parent
6eec7905d5
commit
12fd8e63d9
@ -75,9 +75,9 @@ public:
|
||||
/// Allocate space for a specific count of elements and with a specified
|
||||
/// alignment.
|
||||
template <typename T>
|
||||
T *Allocate(size_t Num, unsigned Alignment) {
|
||||
T *Allocate(size_t Num, size_t Alignment) {
|
||||
// Round EltSize up to the specified alignment.
|
||||
unsigned EltSize = (sizeof(T)+Alignment-1)&(-Alignment);
|
||||
size_t EltSize = (sizeof(T)+Alignment-1)&(-Alignment);
|
||||
return static_cast<T*>(Allocate(Num * EltSize, Alignment));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user