mirror of
https://github.com/janet-lang/janet
synced 2025-11-06 18:43:04 +00:00
Update whitespace and some doc strings.
This commit is contained in:
@@ -266,7 +266,6 @@ static void marshal_one_fiber(MarshalState *st, JanetFiber *fiber, int flags) {
|
||||
marshal_one(st, janet_wrap_fiber(fiber->child), flags + 1);
|
||||
}
|
||||
|
||||
|
||||
void janet_marshal_int(JanetMarshalContext *ctx, int32_t value) {
|
||||
MarshalState *st = (MarshalState *)(ctx->m_state);
|
||||
pushint(st, value);
|
||||
@@ -290,7 +289,6 @@ void janet_marshal_janet(JanetMarshalContext *ctx, Janet x) {
|
||||
#define MARK_SEEN() \
|
||||
janet_table_put(&st->seen, x, janet_wrap_integer(st->nextid++))
|
||||
|
||||
|
||||
static void marshal_one_abstract(MarshalState *st, Janet x, int flags) {
|
||||
void *abstract = janet_unwrap_abstract(x);
|
||||
const JanetAbstractType *at = janet_abstract_type(abstract);
|
||||
@@ -306,7 +304,6 @@ static void marshal_one_abstract(MarshalState *st, Janet x, int flags) {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* The main body of the marshaling function. Is the main
|
||||
* entry point for the mutually recursive functions. */
|
||||
static void marshal_one(MarshalState *st, Janet x, int flags) {
|
||||
@@ -519,7 +516,6 @@ typedef struct {
|
||||
const uint8_t *end;
|
||||
} UnmarshalState;
|
||||
|
||||
|
||||
#define MARSH_EOS(st, data) do { \
|
||||
if ((data) >= (st)->end) janet_panic("unexpected end of source");\
|
||||
} while (0)
|
||||
@@ -900,7 +896,6 @@ static const uint8_t *unmarshal_one_fiber(
|
||||
return data;
|
||||
}
|
||||
|
||||
|
||||
void janet_unmarshal_int(JanetMarshalContext *ctx, int32_t *i) {
|
||||
UnmarshalState *st = (UnmarshalState *)(ctx->u_state);
|
||||
*i = readint(st, &(ctx->data));
|
||||
@@ -916,8 +911,6 @@ void janet_unmarshal_size(JanetMarshalContext *ctx, size_t *i) {
|
||||
*i = (size_t)readint(st, &(ctx->data));
|
||||
};
|
||||
|
||||
|
||||
|
||||
void janet_unmarshal_byte(JanetMarshalContext *ctx, uint8_t *b) {
|
||||
UnmarshalState *st = (UnmarshalState *)(ctx->u_state);
|
||||
MARSH_EOS(st, ctx->data);
|
||||
@@ -951,10 +944,6 @@ static const uint8_t *unmarshal_one_abstract(UnmarshalState *st, const uint8_t *
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
static const uint8_t *unmarshal_one(
|
||||
UnmarshalState *st,
|
||||
const uint8_t *data,
|
||||
|
||||
Reference in New Issue
Block a user