projects
/
cgds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add basic Set implementation - TODO: add iterators for Set and HashTable
[cgds.git]
/
src
/
Stack.h
diff --git
a/src/Stack.h
b/src/Stack.h
index
57bb615
..
b6a3bf4
100644
(file)
--- a/
src/Stack.h
+++ b/
src/Stack.h
@@
-41,9
+41,7
@@
Stack* _stack_new(
* Usage: Stack* stack_new(<Type> type)
*/
#define stack_new(type) \
* Usage: Stack* stack_new(<Type> type)
*/
#define stack_new(type) \
-{ \
- _stack_new(sizeof(type)); \
-}
+ _stack_new(sizeof(type))
/**
* @brief Copy constructor (shallow copy, ok for basic types).
/**
* @brief Copy constructor (shallow copy, ok for basic types).
@@
-83,8
+81,8
@@
void _stack_push(
*/
#define stack_push(stack, data) \
{ \
*/
#define stack_push(stack, data) \
{ \
- typeof(
(data)
) tmp = data; \
- _stack_push(stack,&tmp); \
+ typeof(
data
) tmp = data; \
+ _stack_push(stack,
&tmp); \
}
/**
}
/**