- * Buffer parameter types. These are not needed when formatting or
- * unformatting buffers. Use the macros such as SILC_STR_UI_CHAR and
- * others instead. These types may be used when describing what a
- * buffer looks like, and how it may be formatted and unformatted.
- *
- * SOURCE
- */
-typedef enum {
- SILC_PARAM_SI8_CHAR, /* Signed 8-bit char */
- SILC_PARAM_UI8_CHAR, /* Unsigned 8-bit char */
- SILC_PARAM_SI16_SHORT, /* Signed 16-bit int */
- SILC_PARAM_UI16_SHORT, /* Unsigned 16-bit int */
- SILC_PARAM_SI32_INT, /* Signed 32-bit int */
- SILC_PARAM_UI32_INT, /* Unsigned 32-bit int */
- SILC_PARAM_SI64_INT, /* Signed 64-bit int */
- SILC_PARAM_UI64_INT, /* Unsigned 64-bit int */
- SILC_PARAM_UI8_STRING, /* String (max len 8-bits)*/
- SILC_PARAM_UI16_STRING, /* String (max len 16-bits) */
- SILC_PARAM_UI32_STRING, /* String (max len 32-bits) */
- SILC_PARAM_BUFFER, /* SilcBuffer */
-
- /* Internal types */
- SILC_PARAM_DATA, /* Binary data */
- SILC_PARAM_UI8_NSTRING, /* String (max len 8-bits) */
- SILC_PARAM_UI16_NSTRING, /* String (max len 16-bits) */
- SILC_PARAM_UI32_NSTRING, /* String (max len 32-bits) */
- SILC_PARAM_UI8_STRING_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_UI16_STRING_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_UI32_STRING_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_UI8_NSTRING_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_UI16_NSTRING_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_UI32_NSTRING_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_DATA_ALLOC, /* Alloc + memcpy */
- SILC_PARAM_BUFFER_ALLOC, /* Alloc + memcpy */
-
- SILC_PARAM_OFFSET,
- SILC_PARAM_ADVANCE,
- SILC_PARAM_FUNC,
-
- SILC_PARAM_UI_XNSTRING,
- SILC_PARAM_UI_XNSTRING_ALLOC,
-
- SILC_PARAM_END
-} SilcBufferParamType;
-/***/
-
-/****d* silcutil/SilcBufferFormatAPI/SILC_STR_*_CHAR
+ * One 8-bit signed integer.
+ *
+ * Formatting: SILC_STR_SINT8(SilcInt8)
+ * Unformatting: SILC_STR_SINT8(SilcInt8 *)
+ *
+ ***/
+#define SILC_STR_SINT8(x) SILC_PARAM_SINT8, (x)
+
+/****d* silcutil/SilcBufferFormatAPI/SILC_STR_UINT8
+ *
+ * NAME
+ *
+ * #define SILC_STR_UINT8() ...
+ *
+ * DESCRIPTION
+ *
+ * One 8-bit unsigned integer.
+ *
+ * Formatting: SILC_STR_UINT8(SilcUInt8)
+ * Unformatting: SILC_STR_UINT8(SilcUInt8 *)
+ *
+ ***/
+#define SILC_STR_UINT8(x) SILC_PARAM_UINT8, (x)
+
+/* Deprecated */
+#define SILC_STR_SI_CHAR(x) SILC_PARAM_SINT8, (x)
+#define SILC_STR_UI_CHAR(x) SILC_PARAM_UINT8, (x)
+
+/****d* silcutil/SilcBufferFormatAPI/SILC_STR_SINT16
+ *
+ * NAME
+ *
+ * #define SILC_STR_SINT16() ...
+ *
+ * DESCRIPTION
+ *
+ * SilcInt16.
+ *
+ * Formatting: SILC_STR_SINT16(SilcInt16)
+ * Unformatting: SILC_STR_SINT16(SilcInt16 *)
+ *
+ ***/
+#define SILC_STR_SINT16(x) SILC_PARAM_SINT16, (x)
+
+/****d* silcutil/SilcBufferFormatAPI/SILC_STR_UINT16