From cfc3bdbccea042a959bff9b255562cb92b863ca0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?IOhannes=20m=20zm=C3=B6lnig?= Date: Wed, 5 Apr 2006 11:27:26 +0000 Subject: use unused variables svn path=/trunk/externals/zexy/; revision=4815 --- src/0x260x260x7e.c | 3 +++ src/0x2e.c | 4 +++- src/0x3c0x7e.c | 3 ++- src/0x3d0x3d0x7e.c | 3 +++ src/0x3e0x7e.c | 3 +++ src/0x7c0x7c0x7e.c | 3 +++ src/absgn~.c | 1 + src/abs~.c | 1 + src/atoi.c | 1 + src/date.c | 4 +++- src/demultiplex.c | 2 ++ src/demultiplex~.c | 2 ++ src/drip.c | 2 ++ src/fifop.c | 5 +++-- src/glue.c | 3 +++ src/index.c | 4 ++++ src/length.c | 4 ++++ src/lifop.c | 5 +++-- src/limiter~.c | 1 + src/list2int.c | 2 ++ src/list2symbol.c | 6 +++++- src/lister.c | 3 +++ src/lpt.c | 1 + src/makesymbol.c | 3 +++ src/mavg.c | 1 + src/minmax.c | 1 + src/msgfile.c | 10 ++++++++++ src/multiline~.c | 2 ++ src/multiplex.c | 2 ++ src/multiplex~.c | 2 ++ src/operating_system.c | 4 ++-- src/quantize~.c | 1 + src/regex.c | 3 +++ src/relay.c | 1 + src/repack.c | 1 + src/repeat.c | 1 + src/sfplay.c | 1 + src/sgn~.c | 1 + src/sigzero~.c | 12 ++++++------ src/sort.c | 1 + src/strcmp.c | 3 +++ src/sum.c | 1 + src/symbol2list.c | 2 ++ src/tabdump.c | 1 + src/tabminmax.c | 1 + src/tabset.c | 1 + src/time.c | 4 +++- src/unpack~.c | 1 + src/urn.c | 2 +- src/wrap.c | 1 + src/zexy.h | 4 +++- 51 files changed, 115 insertions(+), 19 deletions(-) (limited to 'src') diff --git a/src/0x260x260x7e.c b/src/0x260x260x7e.c index 68ef596..1b054d9 100644 --- a/src/0x260x260x7e.c +++ b/src/0x260x260x7e.c @@ -42,6 +42,7 @@ typedef struct _scalarandand_tilde static void *andand_tilde_new(t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc > 1) post("&&~: extra arguments ignored"); if (argc) { @@ -240,6 +241,8 @@ static void andand_tilde_dsp(t_andand_tilde *x, t_signal **sp) dsp_add(andand_tilde_perform, 4, in1, in2, out, n); else dsp_add(andand_tilde_perf8, 4, in1, in2, out, n); + + ZEXY_USEVAR(x); } static void scalarandand_tilde_dsp(t_scalarandand_tilde *x, t_signal **sp) diff --git a/src/0x2e.c b/src/0x2e.c index bf91541..00b04ea 100644 --- a/src/0x2e.c +++ b/src/0x2e.c @@ -39,6 +39,7 @@ typedef struct _scalmul static void scalmul_lst2(t_scalmul *x, t_symbol *s, int argc, t_atom *argv) { t_float *fp; + ZEXY_USEVAR(s); if (x->n2 != argc) { freebytes(x->buf2, x->n2 * sizeof(t_float)); x->n2 = argc; @@ -53,6 +54,7 @@ static void scalmul_lst(t_scalmul *x, t_symbol *s, int argc, t_atom *argv) t_float *fp; t_atom *ap; int n; + ZEXY_USEVAR(s); if (argc){ if (x->n1 != argc) { @@ -122,7 +124,7 @@ static void scalmul_free(t_scalmul *x) static void *scalmul_new(t_symbol *s, int argc, t_atom *argv) { t_scalmul *x; - + ZEXY_USEVAR(s); if (argc-1){ x = (t_scalmul *)pd_new(scalmul_class); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("list"), gensym("")); diff --git a/src/0x3c0x7e.c b/src/0x3c0x7e.c index b9624de..38c239c 100644 --- a/src/0x3c0x7e.c +++ b/src/0x3c0x7e.c @@ -43,6 +43,7 @@ typedef struct _scalarlt_tilde static void *lt_tilde_new(t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc > 1) post("<~: extra arguments ignored"); if (argc) { @@ -186,7 +187,7 @@ static void lt_tilde_dsp(t_lt_tilde *x, t_signal **sp) t_sample*out=sp[2]->s_vec; int n=sp[0]->s_n; - + ZEXY_USEVAR(x); #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(n)&& diff --git a/src/0x3d0x3d0x7e.c b/src/0x3d0x3d0x7e.c index b535bc1..91d90ff 100644 --- a/src/0x3d0x3d0x7e.c +++ b/src/0x3d0x3d0x7e.c @@ -40,6 +40,7 @@ typedef struct _scalareq_tilde static void *eq_tilde_new(t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc > 1) post("==~: extra arguments ignored"); if (argc) { @@ -185,6 +186,8 @@ static void eq_tilde_dsp(t_eq_tilde *x, t_signal **sp) int n=sp[0]->s_n; + ZEXY_USEVAR(x); + #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(n)&& diff --git a/src/0x3e0x7e.c b/src/0x3e0x7e.c index 6478143..9f8e0eb 100644 --- a/src/0x3e0x7e.c +++ b/src/0x3e0x7e.c @@ -42,6 +42,7 @@ typedef struct _scalargt_tilde static void *gt_tilde_new(t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc > 1) post(">~: extra arguments ignored"); if (argc) { @@ -187,6 +188,8 @@ static void gt_tilde_dsp(t_gt_tilde *x, t_signal **sp) int n=sp[0]->s_n; + ZEXY_USEVAR(x); + #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(n)&& diff --git a/src/0x7c0x7c0x7e.c b/src/0x7c0x7c0x7e.c index d79624e..774605f 100644 --- a/src/0x7c0x7c0x7e.c +++ b/src/0x7c0x7c0x7e.c @@ -40,6 +40,7 @@ typedef struct _scalaroror_tilde static void *oror_tilde_new(t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc > 1) post("||~: extra arguments ignored"); if (argc) { @@ -201,6 +202,8 @@ static void oror_tilde_dsp(t_oror_tilde *x, t_signal **sp) int n=sp[0]->s_n; + ZEXY_USEVAR(x); + #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(n)&& diff --git a/src/absgn~.c b/src/absgn~.c index dde0266..7cfe08b 100644 --- a/src/absgn~.c +++ b/src/absgn~.c @@ -88,6 +88,7 @@ static t_int *sigABSGN_performSSE(t_int *w) static void sigABSGN_dsp(t_absgn *x, t_signal **sp) { + ZEXY_USEVAR(x); #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(sp[0]->s_n)&& diff --git a/src/abs~.c b/src/abs~.c index 4a365a3..368f65d 100644 --- a/src/abs~.c +++ b/src/abs~.c @@ -119,6 +119,7 @@ static t_int *sigABS_performSSE(t_int *w) static void sigABS_dsp(t_abs *x, t_signal **sp) { + ZEXY_USEVAR(x); #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(sp[0]->s_n)&& diff --git a/src/atoi.c b/src/atoi.c index 2dcd325..ef70f09 100644 --- a/src/atoi.c +++ b/src/atoi.c @@ -56,6 +56,7 @@ static void atoi_list(t_atoi *x, t_symbol *s, int argc, t_atom *argv) { int base=10; const char* c; + ZEXY_USEVAR(s); if (argv->a_type==A_FLOAT){ x->i=atom_getfloat(argv); diff --git a/src/date.c b/src/date.c index f6f05d8..0ea352c 100644 --- a/src/date.c +++ b/src/date.c @@ -66,7 +66,8 @@ static void *date_new(t_symbol *s, int argc, t_atom *argv) { t_date *x = (t_date *)pd_new(date_class); char buf[5]; - + ZEXY_USEVAR(s); + x->GMT=0; if (argc) { atom_string(argv, buf, 5); @@ -106,6 +107,7 @@ static void date_bang(t_date *x) static void help_date(t_date *x) { + ZEXY_USEVAR(x); post("\n%c date\t\t:: get the current system date", HEARTSYMBOL); post("\noutputs are\t: year / month / day / day of week /day of year / daylightsaving (1/0)"); post("\ncreation\t::'date [GMT]': show local date or GMT"); diff --git a/src/demultiplex.c b/src/demultiplex.c index 9045177..5c8431e 100644 --- a/src/demultiplex.c +++ b/src/demultiplex.c @@ -84,6 +84,8 @@ static void *demux_new(t_symbol *s, int argc, t_atom *argv) { t_demux *x = (t_demux *)pd_new(demux_class); int n = (argc < 2)?2:argc; + ZEXY_USEVAR(s); + ZEXY_USEVAR(argv); x->n_out = n - 1; diff --git a/src/demultiplex~.c b/src/demultiplex~.c index 4d78583..d55d7f0 100644 --- a/src/demultiplex~.c +++ b/src/demultiplex~.c @@ -89,6 +89,8 @@ static void *demux_new(t_symbol *s, int argc, t_atom *argv) { t_demux *x = (t_demux *)pd_new(demux_class); int i; + ZEXY_USEVAR(s); + ZEXY_USEVAR(argv); if (!argc)argc=2; x->n_out=argc; diff --git a/src/drip.c b/src/drip.c index 2679588..a5d7b55 100644 --- a/src/drip.c +++ b/src/drip.c @@ -109,6 +109,7 @@ static void drip_tick(t_drip *x) static void drip_list(t_drip *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (x->flush && x->current) { /* do we want to flush */ drip_all(x, x->bufsize - (x->current - x->buffer), x->current); } @@ -171,6 +172,7 @@ static void drip_free(t_drip *x) static void *drip_new(t_symbol *s, int argc, t_atom *argv) { t_drip *x = (t_drip *)pd_new(drip_class); + ZEXY_USEVAR(s); if (argc>1) x->flush = 1; else x->flush = 0; diff --git a/src/fifop.c b/src/fifop.c index e316682..0555c21 100644 --- a/src/fifop.c +++ b/src/fifop.c @@ -149,6 +149,7 @@ static t_fifop_prioritylist*getFifo(t_fifop_prioritylist*pfifo) static void fifop_list(t_fifop *x, t_symbol *s, int argc, t_atom *argv) { t_fifop_prioritylist*pfifo=0; + ZEXY_USEVAR(s); if(!(pfifo=fifop_genprioritylist(x, x->priority))) { error("[fifop]: couldn't get priority fifo"); return; @@ -234,7 +235,7 @@ static void fifop_free(t_fifop *x) outlet_free(x->x_infout); } -static void *fifop_new(t_symbol *s, int argc, t_atom *argv) +static void *fifop_new(void) { t_fifop *x = (t_fifop *)pd_new(fifop_class); @@ -251,7 +252,7 @@ static void *fifop_new(t_symbol *s, int argc, t_atom *argv) void fifop_setup(void) { fifop_class = class_new(gensym("fifop"), (t_newmethod)fifop_new, - (t_method)fifop_free, sizeof(t_fifop), 0, A_GIMME, 0); + (t_method)fifop_free, sizeof(t_fifop), 0, A_NULL); class_addbang (fifop_class, fifop_bang); class_addlist (fifop_class, fifop_list); diff --git a/src/glue.c b/src/glue.c index fb1b872..6265eb1 100644 --- a/src/glue.c +++ b/src/glue.c @@ -37,6 +37,7 @@ typedef struct _zglue static void glue_lst2(t_glue *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); x->changed = 1; if (x->n2 != argc) { freebytes(x->ap2, x->n2 * sizeof(t_atom)); @@ -47,6 +48,7 @@ static void glue_lst2(t_glue *x, t_symbol *s, int argc, t_atom *argv) static void glue_lst(t_glue *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (x->n != x->n2+argc) { freebytes(x->ap, x->n * sizeof(t_atom)); x->n1 = argc; @@ -89,6 +91,7 @@ static void glue_free(t_glue *x) static void *glue_new(t_symbol *s, int argc, t_atom *argv) { t_glue *x = (t_glue *)pd_new(glue_class); + ZEXY_USEVAR(s); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("list"), gensym("")); outlet_new(&x->x_obj, 0); diff --git a/src/index.c b/src/index.c index 33e40e6..f3a8fb6 100644 --- a/src/index.c +++ b/src/index.c @@ -170,6 +170,7 @@ static void index_add(t_index *x, t_symbol *s, t_float f) static void index_delete(t_index *x, t_symbol *s, int argc, t_atom*argv) { int index=-1; + ZEXY_USEVAR(s); if(argc!=1){ error("index :: delete what ?"); return; @@ -291,6 +292,8 @@ static void *index_new(t_symbol *s, int argc, t_atom *argv) int maxentries = 0, automod=0; + ZEXY_USEVAR(s); + if (argc--) { maxentries = (int)atom_getfloat(argv++); if (argc) automod = (int)atom_getfloat(argv++); @@ -322,6 +325,7 @@ static void index_free(t_index *x) static void index_helper(t_index *x) { + ZEXY_USEVAR(x); post("\n%c index :: index symbols to indices", HEARTSYMBOL); post(" : look up the in the index and return it's index\n" "\n : look up the element at index in the index" diff --git a/src/length.c b/src/length.c index 5b88659..72304db 100644 --- a/src/length.c +++ b/src/length.c @@ -27,10 +27,14 @@ typedef struct _length static void length_list(t_length *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); + ZEXY_USEVAR(argv); outlet_float(x->x_obj.ob_outlet, (t_float)argc); } static void length_any(t_length *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); + ZEXY_USEVAR(argv); outlet_float(x->x_obj.ob_outlet, (t_float)argc+1); } diff --git a/src/lifop.c b/src/lifop.c index 2a94b15..ebfca54 100644 --- a/src/lifop.c +++ b/src/lifop.c @@ -133,6 +133,7 @@ static t_lifop_prioritylist*getLifo(t_lifop_prioritylist*plifo) static void lifop_list(t_lifop *x, t_symbol *s, int argc, t_atom *argv) { t_lifop_prioritylist*plifo=0; + ZEXY_USEVAR(s); if(!(plifo=lifop_genprioritylist(x, x->priority))) { error("[lifop]: couldn't get priority lifo"); return; @@ -216,7 +217,7 @@ static void lifop_free(t_lifop *x) outlet_free(x->x_infout); } -static void *lifop_new(t_symbol *s, int argc, t_atom *argv) +static void *lifop_new(void) { t_lifop *x = (t_lifop *)pd_new(lifop_class); @@ -234,7 +235,7 @@ static void *lifop_new(t_symbol *s, int argc, t_atom *argv) void lifop_setup(void) { lifop_class = class_new(gensym("lifop"), (t_newmethod)lifop_new, - (t_method)lifop_free, sizeof(t_lifop), 0, A_GIMME, 0); + (t_method)lifop_free, sizeof(t_lifop), 0, A_NULL); class_addbang (lifop_class, lifop_bang); class_addlist (lifop_class, lifop_list); diff --git a/src/limiter~.c b/src/limiter~.c index cc2996e..fa1ba4b 100644 --- a/src/limiter~.c +++ b/src/limiter~.c @@ -597,6 +597,7 @@ static void limiter_dsp(t_limiter *x, t_signal **sp) static void *limiter_new(t_symbol *s, int argc, t_atom *argv) { t_limiter *x = (t_limiter *)pd_new(limiter_class); + ZEXY_USEVAR(s); int i = 0; diff --git a/src/list2int.c b/src/list2int.c index 0758e3d..999ac96 100644 --- a/src/list2int.c +++ b/src/list2int.c @@ -56,6 +56,8 @@ static void *list2int_new(t_symbol *s, int argc, t_atom *argv) outlet_new(&x->x_obj, 0); x->x_n = 0; x->x_list = 0; + + list2int_any(x, s, argc, argv); return (x); } diff --git a/src/list2symbol.c b/src/list2symbol.c index 4380096..dc67769 100644 --- a/src/list2symbol.c +++ b/src/list2symbol.c @@ -121,11 +121,13 @@ static void list2symbol_anything(t_list2symbol *x, t_symbol *s, int argc, t_atom static void list2symbol_list(t_list2symbol *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); list2symbol_anything(x, 0, argc, argv); } static void *list2symbol_new(t_symbol *s, int argc, t_atom *argv) { t_list2symbol *x = (t_list2symbol *)pd_new(list2symbol_class); + ZEXY_USEVAR(s); outlet_new(&x->x_obj, 0); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("symbol"), gensym("")); @@ -136,7 +138,9 @@ static void *list2symbol_new(t_symbol *s, int argc, t_atom *argv) } static void list2symbol_free(t_list2symbol *x) -{} +{ + ZEXY_USEVAR(x); +} void list2symbol_setup(void) diff --git a/src/lister.c b/src/lister.c index 2bc7e27..b72e93a 100644 --- a/src/lister.c +++ b/src/lister.c @@ -28,6 +28,7 @@ static t_class *mypdlist_class; static void mypdlist_secondlist(t_mypdlist *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc) { if (x->x_n != argc) { freebytes(x->x_list, x->x_n * sizeof(t_atom)); @@ -39,6 +40,7 @@ static void mypdlist_secondlist(t_mypdlist *x, t_symbol *s, int argc, t_atom *ar static void mypdlist_list(t_mypdlist *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (x->x_n != argc) { freebytes(x->x_list, x->x_n * sizeof(t_atom)); x->x_n = argc; @@ -56,6 +58,7 @@ static void mypdlist_free(t_mypdlist *x) static void *mypdlist_new(t_symbol *s, int argc, t_atom *argv) { t_mypdlist *x = (t_mypdlist *)pd_new(mypdlist_class); + ZEXY_USEVAR(s); outlet_new(&x->x_obj, 0); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("list"), gensym("lst2")); diff --git a/src/lpt.c b/src/lpt.c index 78be04e..4a57c3a 100644 --- a/src/lpt.c +++ b/src/lpt.c @@ -282,6 +282,7 @@ static void lpt_free(t_lpt *x) static void lpt_helper(t_lpt *x) { + ZEXY_USEVAR(x); post("\n%c lpt :: direct access to the parallel port", HEARTSYMBOL); post("\t: write byte to the parallel-port"); post("\ncreation:\t\"lpt []\": connect to parallel port (0..2)"); diff --git a/src/makesymbol.c b/src/makesymbol.c index c97fff0..eac949c 100644 --- a/src/makesymbol.c +++ b/src/makesymbol.c @@ -80,6 +80,7 @@ static t_symbol* list2symbol(char *masque, int argc, t_atom *argv) static void makesymbol_list(t_makesymbol *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); x->x_sym = list2symbol(x->mask, argc, argv); outlet_symbol(x->x_obj.ob_outlet, x->x_sym); } @@ -93,6 +94,7 @@ static void makesymbol_bang(t_makesymbol *x) static void *makesymbol_new(t_symbol *s, int argc, t_atom *argv) { t_makesymbol *x = (t_makesymbol *)pd_new(makesymbol_class); + ZEXY_USEVAR(s); x->buf = (char *)getbytes(MAXSTRINGLENG * sizeof(char)); @@ -120,6 +122,7 @@ static void makesymbol_free(t_makesymbol *x) static void makesymbol_helper(t_makesymbol *x) { + ZEXY_USEVAR(x); post("\n%c makesymbol :: create a formatted symbol", HEARTSYMBOL); post("\t: glue up to 10 list-elements to 1 formatted symbol\n" "'bang'\t\t\t: re-output\n" diff --git a/src/mavg.c b/src/mavg.c index 2ed0352..e0f1333 100644 --- a/src/mavg.c +++ b/src/mavg.c @@ -54,6 +54,7 @@ static void mavg_set(t_mavg *x, t_symbol *s, int argc, t_atom *argv) int i = x->size; t_float *dummy = x->buf; t_float f=(argc)?atom_getfloat(argv):x->avg; + ZEXY_USEVAR(s); while (i--) *dummy++=f; diff --git a/src/minmax.c b/src/minmax.c index c44065d..98702d3 100644 --- a/src/minmax.c +++ b/src/minmax.c @@ -37,6 +37,7 @@ static void minmax_bang(t_minmax *x) static void minmax_list(t_minmax *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if(argc){ t_float min = atom_getfloat(argv++); t_float max=min; diff --git a/src/msgfile.c b/src/msgfile.c index 6826542..3a925f5 100644 --- a/src/msgfile.c +++ b/src/msgfile.c @@ -284,6 +284,7 @@ static void delete_region(t_msgfile *x, int start, int stop) static void msgfile_delete(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { + ZEXY_USEVAR(s); if (ac==1) { int pos = atom_getfloat(av); int oldwhere = node_wherearewe(x); @@ -309,12 +310,14 @@ static void msgfile_delete(t_msgfile *x, t_symbol *s, int ac, t_atom *av) static void msgfile_add(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { + ZEXY_USEVAR(s); msgfile_end(x); add_currentnode(x); write_currentnode(x, ac, av); } static void msgfile_add2(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { + ZEXY_USEVAR(s); msgfile_end(x); if (x->current->previous) x->current = x->current->previous; write_currentnode(x, ac, av); @@ -322,6 +325,7 @@ static void msgfile_add2(t_msgfile *x, t_symbol *s, int ac, t_atom *av) } static void msgfile_append(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { + ZEXY_USEVAR(s); add_currentnode(x); write_currentnode(x, ac, av); } @@ -333,6 +337,7 @@ static void msgfile_append2(t_msgfile *x, t_symbol *s, int ac, t_atom *av) static void msgfile_insert(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { t_msglist *cur = x->current; + ZEXY_USEVAR(s); insert_currentnode(x); write_currentnode(x, ac, av); x->current = cur; @@ -340,6 +345,7 @@ static void msgfile_insert(t_msgfile *x, t_symbol *s, int ac, t_atom *av) static void msgfile_insert2(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { t_msglist *cur = x->current; + ZEXY_USEVAR(s); if ((x->current) && (x->current->previous)) x->current = x->current->previous; write_currentnode(x, ac, av); x->current = cur; @@ -353,6 +359,7 @@ static void msgfile_set(t_msgfile *x, t_symbol *s, int ac, t_atom *av) static void msgfile_replace(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { + ZEXY_USEVAR(s); freebytes(x->current->thislist, sizeof(x->current->thislist)); x->current->thislist = 0; x->current->n = 0; @@ -426,6 +433,7 @@ static void msgfile_find(t_msgfile *x, t_symbol *s, int ac, t_atom *av) { t_msglist *found = 0; t_msglist *cur=x->current; + ZEXY_USEVAR(s); while (cur) { int n = cur->n; @@ -692,6 +700,7 @@ static void msgfile_write(t_msgfile *x, t_symbol *filename, t_symbol *format) static void msgfile_help(t_msgfile *x) { + ZEXY_USEVAR(x); post("\n%c msgfile\t:: handle and store files of lists", HEARTSYMBOL); post("goto \t: goto line " "\nrewind\t\t: goto the beginning of the file" @@ -732,6 +741,7 @@ static void msgfile_free(t_msgfile *x) static void *msgfile_new(t_symbol *s, int argc, t_atom *argv) { t_msgfile *x = (t_msgfile *)pd_new(msgfile_class); + ZEXY_USEVAR(s); /* an empty node indicates the end of our listbuffer */ x->current = 0; diff --git a/src/multiline~.c b/src/multiline~.c index 2767df5..70c62e9 100644 --- a/src/multiline~.c +++ b/src/multiline~.c @@ -61,6 +61,7 @@ typedef struct _mline { static void mline_list(t_mline *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); if (argc>x->sigNUM)x->time=atom_getfloat(argv+argc-1); if (x->time <= 0) { @@ -198,6 +199,7 @@ static void *mline_new(t_symbol *s, int argc, t_atom *argv) { t_mline *x = (t_mline *)pd_new(mline_class); int i; + ZEXY_USEVAR(s); if (!argc) { argc = 1; diff --git a/src/multiplex.c b/src/multiplex.c index bdade9f..a2d4180 100644 --- a/src/multiplex.c +++ b/src/multiplex.c @@ -64,6 +64,8 @@ static void *mux_new(t_symbol *s, int argc, t_atom *argv) int n = (argc < 2)?2:argc; t_mux *x = (t_mux *)pd_new(mux_class); // t_muxproxy *y=(t_muxproxy*)pd_new(muxproxy_class); + ZEXY_USEVAR(s); + ZEXY_USEVAR(argv); x->i_selected=0; x->i_count = n; diff --git a/src/multiplex~.c b/src/multiplex~.c index be141cd..23a2eef 100644 --- a/src/multiplex~.c +++ b/src/multiplex~.c @@ -80,6 +80,8 @@ static void *mux_new(t_symbol *s, int argc, t_atom *argv) { t_mux *x = (t_mux *)pd_new(mux_class); int i; + ZEXY_USEVAR(s); + ZEXY_USEVAR(argv); if (!argc)argc=2; x->n_in=argc; diff --git a/src/operating_system.c b/src/operating_system.c index d14979f..25453b8 100644 --- a/src/operating_system.c +++ b/src/operating_system.c @@ -48,7 +48,7 @@ static void operating_system_bang(t_operating_system *x) outlet_symbol(x->x_obj.ob_outlet, s); } -static void *operating_system_new(t_floatarg f) +static void *operating_system_new() { t_operating_system *x = (t_operating_system *)pd_new(operating_system_class); outlet_new(&x->x_obj, 0); @@ -58,7 +58,7 @@ static void *operating_system_new(t_floatarg f) void operating_system_setup(void) { operating_system_class = class_new(gensym("operating_system"), (t_newmethod)operating_system_new, - 0, sizeof(t_operating_system), 0, A_DEFFLOAT, 0); + 0, sizeof(t_operating_system), 0, A_NULL); class_addbang (operating_system_class, operating_system_bang); class_sethelpsymbol(operating_system_class, gensym("zexy/operating_system")); diff --git a/src/quantize~.c b/src/quantize~.c index 3fc6bef..97ce92a 100644 --- a/src/quantize~.c +++ b/src/quantize~.c @@ -75,6 +75,7 @@ static void quantize_dsp(t_quantize *x, t_signal **sp) static void quantize_tilde_helper(t_quantize *x) { + ZEXY_USEVAR(x); post("%c quantize~-object\t:: used for quantizing signals by various degrees", HEARTSYMBOL); post(" : quantize a signal into steps ('0' turns quantizing off)\n" "'8bit' : quantize to 8 bit\n" diff --git a/src/regex.c b/src/regex.c index 50794c8..d3b1579 100644 --- a/src/regex.c +++ b/src/regex.c @@ -113,6 +113,7 @@ static char*regex_l2s(int *reslen, t_symbol*s, int argc, t_atom*argv) static void regex_regex(t_regex *x, t_symbol*s, int argc, t_atom*argv) { + ZEXY_USEVAR(s); #ifdef HAVE_REGEX_H char*result=0; int length=0; @@ -145,6 +146,7 @@ static void regex_regex(t_regex *x, t_symbol*s, int argc, t_atom*argv) } static void regex_symbol(t_regex *x, t_symbol *s, int argc, t_atom*argv) { + ZEXY_USEVAR(s); #ifdef HAVE_REGEX_H char*teststring=0; int length=0; @@ -204,6 +206,7 @@ static void regex_symbol(t_regex *x, t_symbol *s, int argc, t_atom*argv) static void *regex_new(t_symbol *s, int argc, t_atom*argv) { t_regex *x = (t_regex *)pd_new(regex_class); + ZEXY_USEVAR(s); outlet_new(&x->x_obj, 0); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("symbol"), gensym("regex")); diff --git a/src/relay.c b/src/relay.c index fad984b..e0609df 100644 --- a/src/relay.c +++ b/src/relay.c @@ -149,6 +149,7 @@ static void *relay_new(t_symbol *s, int argc, t_atom *argv) t_relayelement *e; t_relay *x = (t_relay *)pd_new(relay_class); t_atom a; + ZEXY_USEVAR(s); if (argc == 0) { argc = 1; diff --git a/src/repack.c b/src/repack.c index c7b527b..e0ccef0 100644 --- a/src/repack.c +++ b/src/repack.c @@ -117,6 +117,7 @@ static void repack_list(t_repack *x, t_symbol *s, int argc, t_atom *argv) { int remain = x->outputsize - x->current; t_atom *ap = argv; + ZEXY_USEVAR(s); if (argc >= remain) { memcpy(x->buffer+x->current, ap, remain * sizeof(t_atom)); diff --git a/src/repeat.c b/src/repeat.c index 04fa8bf..cfcaadd 100644 --- a/src/repeat.c +++ b/src/repeat.c @@ -43,6 +43,7 @@ static void repeat_anything(t_repeat *x, t_symbol *s, int argc, t_atom *argv) static void *repeat_new(t_symbol*s, int argc, t_atom*argv) { t_repeat *x = (t_repeat *)pd_new(repeat_class); + ZEXY_USEVAR(s); if(argc){ if(A_FLOAT==argv->a_type) x->fcount = atom_getfloat(argv); diff --git a/src/sfplay.c b/src/sfplay.c index cf2bc70..d197f3c 100644 --- a/src/sfplay.c +++ b/src/sfplay.c @@ -137,6 +137,7 @@ static int sfplay_am_i_big_endian(void) static void sfplay_helper(t_sfplay *x) { + ZEXY_USEVAR(x); post("\nsfplay :: a soundfile-player (c) winfried ritsch 1999"); post("\ncreation :: sfplay : channels set the number of channels, bytes skip fileheader"); post("\nopen [] []\t::open b(ig) or l(ittle) endian file" diff --git a/src/sgn~.c b/src/sgn~.c index e8cd0a0..c69eae2 100644 --- a/src/sgn~.c +++ b/src/sgn~.c @@ -111,6 +111,7 @@ static t_int *sgnTilde_performSSE(t_int *w) static void sgnTilde_dsp(t_sgnTilde *x, t_signal **sp) { + ZEXY_USEVAR(x); #ifdef __SSE__ if( Z_SIMD_CHKBLOCKSIZE(sp[0]->s_n)&& diff --git a/src/sigzero~.c b/src/sigzero~.c index 304da1a..afdbe70 100644 --- a/src/sigzero~.c +++ b/src/sigzero~.c @@ -36,12 +36,12 @@ static void sigzero_activate(t_sigzero *x, t_floatarg activate) x->activate = (activate)?1:0; } -static void sigzero_banged(t_sigzero *x, t_floatarg activate) +static void sigzero_banged(t_sigzero *x) { x->activate = 1; } -static void sigzero_off(t_sigzero *x, t_floatarg activate) +static void sigzero_off(t_sigzero *x) { x->activate = 0; } @@ -87,11 +87,11 @@ static void sigzero_tilde_helper(void) post("outlet :: 1/0\t: signal turned to non-zero/zero\n"); } -static void *sigzero_new(t_symbol s) +static void *sigzero_new() { - t_sigzero *x = (t_sigzero *)pd_new(sigzero_class); - outlet_new(&x->x_obj, &s_float); - return (x); + t_sigzero *x = (t_sigzero *)pd_new(sigzero_class); + outlet_new(&x->x_obj, &s_float); + return (x); } void sigzero_tilde_setup(void) diff --git a/src/sort.c b/src/sort.c index 71eaf44..6169e60 100644 --- a/src/sort.c +++ b/src/sort.c @@ -79,6 +79,7 @@ static void sort_list(t_sort *x, t_symbol *s, int argc, t_atom *argv) t_int *idx; int i, loops = 1; + ZEXY_USEVAR(s); sort_buffer(x, argc, argv); buf = x->buffer; diff --git a/src/strcmp.c b/src/strcmp.c index 684c15a..52f39c5 100644 --- a/src/strcmp.c +++ b/src/strcmp.c @@ -82,6 +82,7 @@ static void list2binbuf(t_binbuf**bbuf, int *n, char**str, int argc, t_atom*argv static void strcmp_list(t_strcmp *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); list2binbuf(&x->bbuf1, &x->n1, &x->str1, argc, argv); strcmp_bang(x); } @@ -95,6 +96,7 @@ static void strcmp_symbol(t_strcmp *x, t_symbol *s) static void strcmp_secondlist(t_strcmp *x, t_symbol *s, int argc, t_atom *argv) { + ZEXY_USEVAR(s); list2binbuf(&x->bbuf2, &x->n2, &x->str2, argc, argv); } static void strcmp_secondsymbol(t_strcmp *x, t_symbol *s) @@ -116,6 +118,7 @@ static void strcmp_proxy_symbol(t_strcmp_proxy *y, t_symbol *s) static void *strcmp_new(t_symbol *s, int argc, t_atom *argv) { t_strcmp *x = (t_strcmp *)pd_new(strcmp_class); + ZEXY_USEVAR(s); x->x_proxy=(t_strcmp_proxy*)pd_new(strcmp_proxy_class); x->x_proxy->p_master = x; diff --git a/src/sum.c b/src/sum.c index 67019ee..0a3dd34 100644 --- a/src/sum.c +++ b/src/sum.c @@ -28,6 +28,7 @@ typedef struct _sum static void sum_list(t_sum *x, t_symbol *s, int argc, t_atom *argv) { t_float sum = 0.f; + ZEXY_USEVAR(s); while(argc--)sum+=atom_getfloat(argv++); diff --git a/src/symbol2list.c b/src/symbol2list.c index ff82ddd..4b3c339 100644 --- a/src/symbol2list.c +++ b/src/symbol2list.c @@ -136,6 +136,7 @@ static void symbol2list_symbol(t_symbol2list *x, t_symbol *s){ static void *symbol2list_new(t_symbol *s, int argc, t_atom *argv) { t_symbol2list *x = (t_symbol2list *)pd_new(symbol2list_class); + ZEXY_USEVAR(s); outlet_new(&x->x_obj, 0); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("symbol"), gensym("")); @@ -150,6 +151,7 @@ static void *symbol2list_new(t_symbol *s, int argc, t_atom *argv) static void symbol2list_free(t_symbol2list *x) { + ZEXY_USEVAR(x); } void symbol2list_setup(void) diff --git a/src/tabdump.c b/src/tabdump.c index daca8ce..092609a 100644 --- a/src/tabdump.c +++ b/src/tabdump.c @@ -63,6 +63,7 @@ static void tabdump_bang(t_tabdump *x) static void tabdump_list(t_tabdump *x, t_symbol*s,int argc, t_atom*argv) { int a,b; + ZEXY_USEVAR(s); switch(argc){ case 2: a=atom_getint(argv); diff --git a/src/tabminmax.c b/src/tabminmax.c index c420c55..ebfa2a2 100644 --- a/src/tabminmax.c +++ b/src/tabminmax.c @@ -85,6 +85,7 @@ static void tabminmax_bang(t_tabminmax *x) static void tabminmax_list(t_tabminmax *x, t_symbol*s,int argc, t_atom*argv) { int a,b; + ZEXY_USEVAR(s); switch(argc){ case 2: a=atom_getint(argv); diff --git a/src/tabset.c b/src/tabset.c index d55cd66..3275532 100644 --- a/src/tabset.c +++ b/src/tabset.c @@ -50,6 +50,7 @@ static void tabset_list(t_tabset *x, t_symbol *s, int argc, t_atom* argv) t_garray *A; int npoints; t_float *vec; + ZEXY_USEVAR(s); if (!(A = (t_garray *)pd_findbyclass(x->x_arrayname, garray_class))) error("%s: no such array", x->x_arrayname->s_name); diff --git a/src/time.c b/src/time.c index eb56c26..4340d6b 100644 --- a/src/time.c +++ b/src/time.c @@ -63,7 +63,8 @@ static void *time_new(t_symbol *s, int argc, t_atom *argv) { t_time *x = (t_time *)pd_new(time_class); char buf[5]; - + ZEXY_USEVAR(s); + x->GMT=0; if (argc) { atom_string(argv, buf, 5); @@ -103,6 +104,7 @@ static void time_bang(t_time *x) static void help_time(t_time *x) { + ZEXY_USEVAR(x); post("\n%c time\t\t:: get the current system time", HEARTSYMBOL); post("\noutputs are\t: hour / minute / sec / msec"); post("\ncreation\t:: 'time [GMT]': show local time or GMT"); diff --git a/src/unpack~.c b/src/unpack~.c index 6ee073c..0dbe672 100644 --- a/src/unpack~.c +++ b/src/unpack~.c @@ -47,6 +47,7 @@ static void sigunpack_list(t_sigunpack *x, t_symbol *s, int argc, t_atom *argv) { t_atom *ap = argv; int i; + ZEXY_USEVAR(s); for (i = 0, ap = argv; i < argc; ap++, i++) { // if (ap->a_type == A_FLOAT) { diff --git a/src/urn.c b/src/urn.c index 83f94e9..b3a8ee4 100644 --- a/src/urn.c +++ b/src/urn.c @@ -111,8 +111,8 @@ static void urn_seed(t_urn *x, t_float f) static void *urn_new(t_symbol *s, int argc, t_atom *argv) { t_urn *x = (t_urn *)pd_new(urn_class); - t_float f=0.; + ZEXY_USEVAR(s); inlet_new(&x->x_obj, &x->x_obj.ob_pd, gensym("float"), gensym("")); x->x_floatout=outlet_new(&x->x_obj, &s_float); diff --git a/src/wrap.c b/src/wrap.c index e23eedc..867415c 100644 --- a/src/wrap.c +++ b/src/wrap.c @@ -39,6 +39,7 @@ static void wrap_float(t_wrap *x, t_float f) } static void wrap_set(t_wrap *x, t_symbol *s, int argc, t_atom *argv){ t_float f1, f2; + ZEXY_USEVAR(s); switch (argc){ case 0: f1=0.0; diff --git a/src/zexy.h b/src/zexy.h index 6b1b278..1c4c54c 100644 --- a/src/zexy.h +++ b/src/zexy.h @@ -87,6 +87,8 @@ # endif /* OSX-10.3 */ #endif /* APPLE */ +#define ZEXY_USEVAR(x) x=x + typedef struct _mypdlist { t_object x_obj; @@ -107,7 +109,7 @@ static void zexy_register(char*object){ } } #else -static void zexy_register(char*object){} +static void zexy_register(char*object){object=0;} #endif /* ZEXY_LIBRARY */ #if (defined PD_MAJOR_VERSION && defined PD_MINOR_VERSION) && (PD_MAJOR_VERSION > 0 || PD_MINOR_VERSION > 38) -- cgit v1.2.1