forked from bartvdbraak/blender
fix for building in debug mode.
This commit is contained in:
parent
583fa7d1ea
commit
00ea79afa0
@ -24,6 +24,10 @@
|
|||||||
#ifndef __BLI_STACK_H__
|
#ifndef __BLI_STACK_H__
|
||||||
#define __BLI_STACK_H__
|
#define __BLI_STACK_H__
|
||||||
|
|
||||||
|
/** \file BLI_stack.h
|
||||||
|
* \ingroup bli
|
||||||
|
*/
|
||||||
|
|
||||||
typedef struct BLI_Stack BLI_Stack;
|
typedef struct BLI_Stack BLI_Stack;
|
||||||
|
|
||||||
/* Create a new homogeneous stack with elements of 'elem_size' bytes */
|
/* Create a new homogeneous stack with elements of 'elem_size' bytes */
|
||||||
|
@ -21,10 +21,17 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "BLI_stack.h"
|
/** \file blender/blenlib/intern/stack.c
|
||||||
|
* \ingroup bli
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <string.h>
|
||||||
|
#include <stdlib.h> /* abort() */
|
||||||
|
|
||||||
|
#include "BLI_stack.h" /* own include */
|
||||||
|
|
||||||
#include "BLI_utildefines.h"
|
#include "BLI_utildefines.h"
|
||||||
#include "MEM_guardedalloc.h"
|
#include "MEM_guardedalloc.h"
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
typedef struct BLI_Stack {
|
typedef struct BLI_Stack {
|
||||||
void *data;
|
void *data;
|
||||||
@ -55,7 +62,7 @@ void BLI_stack_free(BLI_Stack *stack)
|
|||||||
|
|
||||||
/* Gets the last element in the stack */
|
/* Gets the last element in the stack */
|
||||||
#define STACK_LAST_ELEM(stack__) \
|
#define STACK_LAST_ELEM(stack__) \
|
||||||
(((char*)(stack__)->data) + \
|
(((char *)(stack__)->data) + \
|
||||||
((stack__)->elem_size * ((stack__)->totelem - 1)))
|
((stack__)->elem_size * ((stack__)->totelem - 1)))
|
||||||
|
|
||||||
void BLI_stack_push(BLI_Stack *stack, void *src)
|
void BLI_stack_push(BLI_Stack *stack, void *src)
|
||||||
|
Loading…
Reference in New Issue
Block a user