mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2025-10-29 21:13:00 +00:00
fixed the warning (-Warray-bounds)
This commit is contained in:
@@ -178,7 +178,7 @@ template<class T> struct connection_table {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
template<class T> T* tailored_alloc(int degree) {
|
template<class T> T* tailored_alloc(int degree) {
|
||||||
const T* sample = (T*) °ree;
|
const T* sample = nullptr;
|
||||||
T* result;
|
T* result;
|
||||||
#ifndef NO_TAILORED_ALLOC
|
#ifndef NO_TAILORED_ALLOC
|
||||||
int b = (char*)&sample->c.move_table[degree] + degree - (char*) sample;
|
int b = (char*)&sample->c.move_table[degree] + degree - (char*) sample;
|
||||||
|
|||||||
Reference in New Issue
Block a user