mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-07-07 05:06:37 +02:00
Refactoring __attribute__((unused)).
This commit is contained in:
parent
663f34000c
commit
380a551f43
2 changed files with 7 additions and 6 deletions
7
gc.c
7
gc.c
|
@ -435,12 +435,7 @@ void sexp_mark_global_symbols(sexp ctx) {
|
|||
#endif
|
||||
|
||||
sexp sexp_gc (sexp ctx, size_t *sum_freed) {
|
||||
sexp res;
|
||||
#ifdef __GNUC__
|
||||
sexp finalized __attribute__((unused));
|
||||
#else
|
||||
sexp finalized;
|
||||
#endif
|
||||
sexp res, finalized SEXP_NO_WARN_UNUSED;
|
||||
sexp_debug_printf("%p (heap: %p size: %lu)", ctx, sexp_context_heap(ctx),
|
||||
sexp_heap_total_size(sexp_context_heap(ctx)));
|
||||
sexp_mark_global_symbols(ctx);
|
||||
|
|
|
@ -45,6 +45,12 @@ extern "C" {
|
|||
#define sexp_out_of_file_descriptors() (0)
|
||||
#endif
|
||||
|
||||
#ifdef __GNUC__
|
||||
#define SEXP_NO_WARN_UNUSED __attribute__((unused))
|
||||
#else
|
||||
#define SEXP_NO_WARN_UNUSED
|
||||
#endif
|
||||
|
||||
#ifdef PLAN9
|
||||
#include <u.h>
|
||||
#include <libc.h>
|
||||
|
|
Loading…
Add table
Reference in a new issue