• R/O
  • SSH
  • HTTPS

cstl: Commit


Commit MetaInfo

Revision201 (tree)
Time2008-02-16 15:26:56
Authorkatono

Log Message

構造体のタグ名を他のコンテナと合わせた。

Change Summary

Incremental Difference

--- trunk/cstl/list.h (revision 200)
+++ trunk/cstl/list.h (revision 201)
@@ -68,11 +68,11 @@
6868 * \param Type 要素の型
6969 */
7070 #define CSTL_LIST_INTERFACE(Name, Type) \
71-typedef struct Name##Node_t Name;\
71+typedef struct Name##_t Name;\
7272 /*!
7373 * \brief イテレータ
7474 */\
75-typedef struct Name##Node_t *Name##Iterator;\
75+typedef struct Name##_t *Name##Iterator;\
7676 \
7777 CSTL_LIST_BEGIN_EXTERN_C()\
7878 Name *Name##_new(void);\
@@ -115,11 +115,11 @@
115115 * \param Type 要素の型
116116 */
117117 #define CSTL_LIST_IMPLEMENT(Name, Type) \
118-typedef struct Name##Node_t Name##Node;\
118+typedef struct Name##_t Name##Node;\
119119 /*!
120- * \brief listノード構造体
120+ * \brief list構造体
121121 */\
122-struct Name##Node_t {\
122+struct Name##_t {\
123123 Name##Node *prev;\
124124 Name##Node *next;\
125125 Type elem;\
@@ -128,7 +128,8 @@
128128 \
129129 Name *Name##_new(void)\
130130 {\
131- Name *self = (Name *) malloc(sizeof(Name));\
131+ Name *self;\
132+ self = (Name *) malloc(sizeof(Name));\
132133 if (!self) return 0;\
133134 self->next = self;\
134135 self->prev = self;\
Show on old repository browser