diff --git a/src/modules/Image/colors.c b/src/modules/Image/colors.c index 783827981b62feb15384642e7ebeba417d117818..a3dc5cd313fe6845aa313b1280ad237cb566c136 100644 --- a/src/modules/Image/colors.c +++ b/src/modules/Image/colors.c @@ -1,7 +1,7 @@ /* **! module Image **! note -**! $Id: colors.c,v 1.22 1999/06/18 19:19:15 mirar Exp $ +**! $Id: colors.c,v 1.23 1999/06/19 20:24:42 hubbe Exp $ **! submodule Color **! **! This module keeps names and easy handling @@ -182,7 +182,7 @@ #include "global.h" -RCSID("$Id: colors.c,v 1.22 1999/06/18 19:19:15 mirar Exp $"); +RCSID("$Id: colors.c,v 1.23 1999/06/19 20:24:42 hubbe Exp $"); #include "image_machine.h" @@ -1544,29 +1544,29 @@ void init_image_colors(void) ADD_FUNCTION("`[]",image_color_index,tFunc(tOr(tStr,tInt),tOr(tInt,tFunction)),0); ADD_FUNCTION("`->",image_color_index,tFunc(tOr(tStr,tInt),tOr(tInt,tFunction)),0); ADD_FUNCTION("`==",image_color_equal,tFunc(tOr(tObj,tInt),tInt),0); - ADD_FUNCTION("__hash",image_color___hash,tFunc(,tInt),0); + ADD_FUNCTION("__hash",image_color___hash,tFunc(tNone,tInt),0); - ADD_FUNCTION("name",image_color_name,tFunc(,tStr),0); - ADD_FUNCTION("hex",image_color_hex,tFunc(,tStr),0); - ADD_FUNCTION("html",image_color_html,tFunc(,tStr),0); + ADD_FUNCTION("name",image_color_name,tFunc(tNone,tStr),0); + ADD_FUNCTION("hex",image_color_hex,tFunc(tNone,tStr),0); + ADD_FUNCTION("html",image_color_html,tFunc(tNone,tStr),0); - ADD_FUNCTION("rgb",image_color_rgb,tFunc(,tArr(tInt)),0); - ADD_FUNCTION("rgbf",image_color_rgbf,tFunc(,tArr(tFlt)),0); - ADD_FUNCTION("hsv",image_color_hsv,tFunc(,tArr(tInt)),0); - ADD_FUNCTION("hsvf",image_color_hsvf,tFunc(,tArr(tFlt)),0); - ADD_FUNCTION("cmyk",image_color_cmyk,tFunc(,tArr(tFlt)),0); - ADD_FUNCTION("greylevel",image_color_greylevel,tOr(tFunc(,tInt),tFunc(tInt tInt tInt,tInt)),0); + ADD_FUNCTION("rgb",image_color_rgb,tFunc(tNone,tArr(tInt)),0); + ADD_FUNCTION("rgbf",image_color_rgbf,tFunc(tNone,tArr(tFlt)),0); + ADD_FUNCTION("hsv",image_color_hsv,tFunc(tNone,tArr(tInt)),0); + ADD_FUNCTION("hsvf",image_color_hsvf,tFunc(tNone,tArr(tFlt)),0); + ADD_FUNCTION("cmyk",image_color_cmyk,tFunc(tNone,tArr(tFlt)),0); + ADD_FUNCTION("greylevel",image_color_greylevel,tOr(tFunc(tNone,tInt),tFunc(tInt tInt tInt,tInt)),0); /* color conversion methods */ ADD_FUNCTION("grey",image_color_grey, - tOr(tFunc(,tObj),tFunc(tInt tInt tInt,tObj)),0); + tOr(tFunc(tNone,tObj),tFunc(tInt tInt tInt,tObj)),0); - ADD_FUNCTION("light",image_color_light,tFunc(,tObj),0); - ADD_FUNCTION("dark",image_color_dark,tFunc(,tObj),0); - ADD_FUNCTION("neon",image_color_neon,tFunc(,tObj),0); - ADD_FUNCTION("bright",image_color_bright,tFunc(,tObj),0); - ADD_FUNCTION("dull",image_color_dull,tFunc(,tObj),0); + ADD_FUNCTION("light",image_color_light,tFunc(tNone,tObj),0); + ADD_FUNCTION("dark",image_color_dark,tFunc(tNone,tObj),0); + ADD_FUNCTION("neon",image_color_neon,tFunc(tNone,tObj),0); + ADD_FUNCTION("bright",image_color_bright,tFunc(tNone,tObj),0); + ADD_FUNCTION("dull",image_color_dull,tFunc(tNone,tObj),0); ADD_FUNCTION("`*",image_color_mult,tFunc(tFlt,tObj),0); ADD_FUNCTION("`+",image_color_add,tFunc(tObj,tObj),0); @@ -1590,8 +1590,8 @@ void init_image_colors(void) ADD_FUNCTION("html",image_make_html_color,tFunc(tStr,tObj),0); ADD_FUNCTION("guess",image_guess_color,tFunc(tStr,tObj),0); ADD_FUNCTION("greylevel",image_make_greylevel_color,tFunc(tInt,tObj),0); - ADD_FUNCTION("_indices",image_colors_indices,tFunc(,tArr(tStr)),0); - ADD_FUNCTION("_values",image_colors_values,tFunc(,tArr(tObj)),0); + ADD_FUNCTION("_indices",image_colors_indices,tFunc(tNone,tArr(tStr)),0); + ADD_FUNCTION("_values",image_colors_values,tFunc(tNone,tArr(tObj)),0); add_program_constant("Color",image_color_program,0); } diff --git a/src/modules/Image/colortable.c b/src/modules/Image/colortable.c index 3f0f5cff182b9c994402f51352f4f0769171d440..e3a438dd2323ff969b58b9dc9facbbe020a391d0 100644 --- a/src/modules/Image/colortable.c +++ b/src/modules/Image/colortable.c @@ -1,11 +1,11 @@ #include "global.h" -/* $Id: colortable.c,v 1.71 1999/06/18 19:19:16 mirar Exp $ */ +/* $Id: colortable.c,v 1.72 1999/06/19 20:24:44 hubbe Exp $ */ /* **! module Image **! note -**! $Id: colortable.c,v 1.71 1999/06/18 19:19:16 mirar Exp $ +**! $Id: colortable.c,v 1.72 1999/06/19 20:24:44 hubbe Exp $ **! class Colortable **! **! This object keeps colortable information, @@ -20,7 +20,7 @@ #undef COLORTABLE_DEBUG #undef COLORTABLE_REDUCE_DEBUG -RCSID("$Id: colortable.c,v 1.71 1999/06/18 19:19:16 mirar Exp $"); +RCSID("$Id: colortable.c,v 1.72 1999/06/19 20:24:44 hubbe Exp $"); #include <math.h> /* fabs() */ @@ -4424,12 +4424,12 @@ void init_image_colortable(void) ADD_FUNCTION("cast",image_colortable_cast,tFunc(tStr,tArray),0); /* info */ - ADD_FUNCTION("_sizeof",image_colortable__sizeof,tFunc(,tInt),0); + ADD_FUNCTION("_sizeof",image_colortable__sizeof,tFunc(tNone,tInt),0); /* lookup modes */ - ADD_FUNCTION("cubicles",image_colortable_cubicles,tFunc(,tObj),0); - ADD_FUNCTION("rigid",image_colortable_rigid,tFunc(,tObj),0); - ADD_FUNCTION("full",image_colortable_full,tFunc(,tObj),0); + ADD_FUNCTION("cubicles",image_colortable_cubicles,tFunc(tNone,tObj),0); + ADD_FUNCTION("rigid",image_colortable_rigid,tFunc(tNone,tObj),0); + ADD_FUNCTION("full",image_colortable_full,tFunc(tNone,tObj),0); /* map image */ /* function(object:object)|function(string,int,int) */ @@ -4442,26 +4442,26 @@ void init_image_colortable(void) /* dither */ /* function(:object) */ - ADD_FUNCTION("nodither",image_colortable_nodither,tFunc(,tObj),0); + ADD_FUNCTION("nodither",image_colortable_nodither,tFunc(tNone,tObj),0); /* function(void|int:object)" "|function(int,int|float,int|float,int|float,int|float:object) */ ADD_FUNCTION("floyd_steinberg",image_colortable_floyd_steinberg,tOr(tFunc(tOr(tVoid,tInt),tObj),tFunc(tInt tOr(tInt,tFlt) tOr(tInt,tFlt) tOr(tInt,tFlt) tOr(tInt,tFlt),tObj)),0); /* function(:object)|function(int,int,int:object) */ - ADD_FUNCTION("randomcube",image_colortable_randomcube,tOr(tFunc(,tObj),tFunc(tInt tInt tInt,tObj)),0); + ADD_FUNCTION("randomcube",image_colortable_randomcube,tOr(tFunc(tNone,tObj),tFunc(tInt tInt tInt,tObj)),0); /* function(:object)|function(int:object) */ - ADD_FUNCTION("randomgrey",image_colortable_randomgrey,tOr(tFunc(,tObj),tFunc(tInt,tObj)),0); + ADD_FUNCTION("randomgrey",image_colortable_randomgrey,tOr(tFunc(tNone,tObj),tFunc(tInt,tObj)),0); /* function(:object)" "|function(int,int,int:object) */ - ADD_FUNCTION("ordered",image_colortable_ordered,tOr(tFunc(,tObj),tFunc(tInt tInt tInt,tObj)),0); + ADD_FUNCTION("ordered",image_colortable_ordered,tOr(tFunc(tNone,tObj),tFunc(tInt tInt tInt,tObj)),0); /* function(:object) */ - ADD_FUNCTION("image",image_colortable_image,tFunc(,tObj),0); + ADD_FUNCTION("image",image_colortable_image,tFunc(tNone,tObj),0); /* tuning image */ /* function(int,int,int:object) */ ADD_FUNCTION("spacefactors",image_colortable_spacefactors,tFunc(tInt tInt tInt,tObj),0); - ADD_FUNCTION("corners",image_colortable_corners,tFunc(,tArray),0); + ADD_FUNCTION("corners",image_colortable_corners,tFunc(tNone,tArray),0); } diff --git a/src/modules/Image/encodings/tga.c b/src/modules/Image/encodings/tga.c index 96657ee27c3938827a59f8952710218ef48668b1..c0f31bd0148c6511f8b0ff1b62b5f6c656925f88 100644 --- a/src/modules/Image/encodings/tga.c +++ b/src/modules/Image/encodings/tga.c @@ -1,6 +1,6 @@ /* - * $Id: tga.c,v 1.7 1999/05/23 17:47:00 mirar Exp $ + * $Id: tga.c,v 1.8 1999/06/19 20:24:59 hubbe Exp $ * * Targa codec for pike. Based on the tga plugin for gimp. * @@ -33,9 +33,13 @@ **! */ +#include "global.h" + #include <stdlib.h> #include <string.h> +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif #include "interpret.h" #include "svalue.h" @@ -73,7 +77,7 @@ #include "image.h" #include "colortable.h" -RCSID("$Id: tga.c,v 1.7 1999/05/23 17:47:00 mirar Exp $"); +RCSID("$Id: tga.c,v 1.8 1999/06/19 20:24:59 hubbe Exp $"); #ifndef MIN # define MIN(X,Y) ((X)<(Y)?(X):(Y)) diff --git a/src/modules/Image/font.c b/src/modules/Image/font.c index 156c5705c0e8ee92d7b99ebc7e6ca1f26bbb42b6..220a46093ec5aeeddd2ddd5a1cf66f3a7fd5c642 100644 --- a/src/modules/Image/font.c +++ b/src/modules/Image/font.c @@ -1,4 +1,4 @@ -/* $Id: font.c,v 1.52 1999/06/18 19:19:21 mirar Exp $ */ +/* $Id: font.c,v 1.53 1999/06/19 20:24:45 hubbe Exp $ */ #include "global.h" #define SPACE_CHAR 'i' @@ -9,7 +9,7 @@ extern unsigned char * image_default_font; /* **! module Image **! note -**! $Id: font.c,v 1.52 1999/06/18 19:19:21 mirar Exp $ +**! $Id: font.c,v 1.53 1999/06/19 20:24:45 hubbe Exp $ **! class Font **! **! note @@ -904,19 +904,19 @@ void init_image_font(void) ADD_FUNCTION("create",font_create,tFunc(tOr(tVoid,tStr),tVoid),0); /* function(string:object) */ - ADD_FUNCTION("write",font_write,tFuncV(,tStr,tObj),0); + ADD_FUNCTION("write",font_write,tFuncV(tNone,tStr,tObj),0); /* function(:int) */ - ADD_FUNCTION("height",font_height,tFunc(,tInt),0); + ADD_FUNCTION("height",font_height,tFunc(tNone,tInt),0); /* function(:int) */ - ADD_FUNCTION("baseline",font_baseline,tFunc(,tInt),0); + ADD_FUNCTION("baseline",font_baseline,tFunc(tNone,tInt),0); /* function(string ...:array(int)) */ - ADD_FUNCTION("extents",font_text_extents,tFuncV(,tStr,tArr(tInt)),0); + ADD_FUNCTION("extents",font_text_extents,tFuncV(tNone,tStr,tArr(tInt)),0); /* function(string ...:array(int)) */ - ADD_FUNCTION("text_extents",font_text_extents,tFuncV(,tStr,tArr(tInt)),0); + ADD_FUNCTION("text_extents",font_text_extents,tFuncV(tNone,tStr,tArr(tInt)),0); /* function(float:void) */ ADD_FUNCTION("set_x_spacing",font_set_xspacing_scale,tFunc(tFlt,tVoid),0); diff --git a/src/modules/Image/image.c b/src/modules/Image/image.c index 8f882b76a2413a68f0a908d45063b1400c2dc291..b89682763f13dec25521e89ef722f7222bf0d055 100644 --- a/src/modules/Image/image.c +++ b/src/modules/Image/image.c @@ -1,9 +1,9 @@ -/* $Id: image.c,v 1.146 1999/06/18 19:19:23 mirar Exp $ */ +/* $Id: image.c,v 1.147 1999/06/19 20:24:46 hubbe Exp $ */ /* **! module Image **! note -**! $Id: image.c,v 1.146 1999/06/18 19:19:23 mirar Exp $ +**! $Id: image.c,v 1.147 1999/06/19 20:24:46 hubbe Exp $ **! class Image **! **! The main object of the <ref>Image</ref> module, this object @@ -97,7 +97,7 @@ #include "stralloc.h" #include "global.h" -RCSID("$Id: image.c,v 1.146 1999/06/18 19:19:23 mirar Exp $"); +RCSID("$Id: image.c,v 1.147 1999/06/19 20:24:46 hubbe Exp $"); #include "pike_macros.h" #include "object.h" #include "constants.h" @@ -3596,14 +3596,14 @@ void init_image_image(void) ADD_FUNCTION("cast",image_cast, tFunc(tStr,tStr),0); - ADD_FUNCTION("tobitmap",image_tobitmap,tFunc(,tStr),0); + ADD_FUNCTION("tobitmap",image_tobitmap,tFunc(tNone,tStr),0); ADD_FUNCTION("copy",image_copy, tFunc(tOr(tVoid,tInt) tOr(tVoid,tInt) tOr(tVoid,tInt) tOr(tVoid,tInt) tRGB,tObj),0); ADD_FUNCTION("autocrop",image_autocrop, - tFuncV(,tOr(tVoid,tInt),tObj),0); + tFuncV(tNone,tOr(tVoid,tInt),tObj),0); ADD_FUNCTION("scale",image_scale, tFunc(tOr(tInt,tFlt) tOr3(tInt,tFlt,tVoid),tObj),0); ADD_FUNCTION("translate",image_translate, @@ -3640,11 +3640,11 @@ void init_image_image(void) ADD_FUNCTION("tuned_box",image_tuned_box, tFunc(tInt tInt tInt tInt tArray,tObj),0); ADD_FUNCTION("gradients",image_gradients, - tFuncV(,tOr(tArr(tInt),tFlt),tObj),0); + tFuncV(tNone,tOr(tArr(tInt),tFlt),tObj),0); ADD_FUNCTION("polygone",image_polyfill, - tFuncV(,tArr(tOr(tFlt,tInt)),tObj),0); + tFuncV(tNone,tArr(tOr(tFlt,tInt)),tObj),0); ADD_FUNCTION("polyfill",image_polyfill, - tFuncV(,tArr(tOr(tFlt,tInt)),tObj),0); + tFuncV(tNone,tArr(tOr(tFlt,tInt)),tObj),0); ADD_FUNCTION("gray",image_grey, tFunc(tRGB,tObj),0); @@ -3688,13 +3688,13 @@ void init_image_image(void) tFunc(tOr(tFlt,tInt) tOr(tFlt,tInt) tOr(tFlt,tInt),tObj)),0); ADD_FUNCTION("rotate_ccw",image_ccw, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("rotate_cw",image_cw, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("mirrorx",image_mirrorx, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("mirrory",image_mirrory, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("skewx",image_skewx, tFunc(tOr(tInt,tFlt) tRGB,tObj),0); ADD_FUNCTION("skewy",image_skewy, @@ -3710,9 +3710,9 @@ void init_image_image(void) tFunc(tOr(tInt,tFlt) tRGB,tObj),0); ADD_FUNCTION("xsize",image_xsize, - tFunc(,tInt),0); + tFunc(tNone,tInt),0); ADD_FUNCTION("ysize",image_ysize, - tFunc(,tInt),0); + tFunc(tNone,tInt),0); ADD_FUNCTION("map_closest",image_map_compat, tFunc(tArr(tArr(tInt)),tObj),0); @@ -3735,7 +3735,7 @@ void init_image_image(void) tFunc(tOr(tVoid,tInt),tObj),0); ADD_FUNCTION("dct",image_dct, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("`-",image_operator_minus, tFunc(tOr3(tObj,tArr(tInt),tInt),tObj),0); @@ -3760,45 +3760,45 @@ void init_image_image(void) tFunc(tOr3(tObj,tArr(tInt),tInt),tInt),0); ADD_FUNCTION("min",image_min, - tFunc(,tArr(tInt)),0); + tFunc(tNone,tArr(tInt)),0); ADD_FUNCTION("max",image_max, - tFunc(,tArr(tInt)),0); + tFunc(tNone,tArr(tInt)),0); ADD_FUNCTION("sum",image_sum, - tFunc(,tArr(tInt)),0); + tFunc(tNone,tArr(tInt)),0); ADD_FUNCTION("sumf",image_sumf, - tFunc(,tArr(tInt)),0); + tFunc(tNone,tArr(tInt)),0); ADD_FUNCTION("average",image_average, - tFunc(,tArr(tInt)),0); + tFunc(tNone,tArr(tInt)),0); ADD_FUNCTION("find_min",image_find_min, - tOr(tFunc(,tArr(tInt)), + tOr(tFunc(tNone,tArr(tInt)), tFunc(tInt tInt tInt,tArr(tInt))),0); ADD_FUNCTION("find_max",image_find_max, - tOr(tFunc(,tArr(tInt)), + tOr(tFunc(tNone,tArr(tInt)), tFunc(tInt tInt tInt,tArr(tInt))),0); ADD_FUNCTION("read_lsb_rgb",image_read_lsb_rgb, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("write_lsb_rgb",image_write_lsb_rgb, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("read_lsb_grey",image_read_lsb_rgb, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("write_lsb_grey",image_write_lsb_rgb, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("orient4",image_orient4, - tFunc(,tArr(tObj)),0); + tFunc(tNone,tArr(tObj)),0); ADD_FUNCTION("orient",image_orient, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("phaseh",image_phaseh, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("phasev",image_phasev, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("phasehv",image_phasehv, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("phasevh",image_phasevh, - tFunc(,tObj),0); + tFunc(tNone,tObj),0); ADD_FUNCTION("match_phase",image_match_phase, tOr4(tFunc(tOr(tInt,tFloat) tObj,tObj), diff --git a/src/modules/Image/layers.c b/src/modules/Image/layers.c index f804fb62c5ebe3fb447763665a2ad5d8f7389da1..53e7e3e4e2e9073768ab5eda4bdd94cabd03a272 100644 --- a/src/modules/Image/layers.c +++ b/src/modules/Image/layers.c @@ -1,7 +1,7 @@ /* **! module Image **! note -**! $Id: layers.c,v 1.17 1999/06/18 17:34:22 mirar Exp $ +**! $Id: layers.c,v 1.18 1999/06/19 20:24:47 hubbe Exp $ **! class Layer */ @@ -9,7 +9,7 @@ #include <math.h> /* floor */ -RCSID("$Id: layers.c,v 1.17 1999/06/18 17:34:22 mirar Exp $"); +RCSID("$Id: layers.c,v 1.18 1999/06/19 20:24:47 hubbe Exp $"); #include "image_machine.h" @@ -2091,7 +2091,7 @@ void init_image_layers(void) set_exit_callback(exit_layer); ADD_FUNCTION("create",image_layer_create, - tOr4(tFunc(,tVoid), + tOr4(tFunc(tNone,tVoid), tFunc(tObj tOr(tObj,tVoid) tOr(tString,tVoid),tVoid), tFunc(tLayerMap,tVoid), tFunc(tInt tInt @@ -2113,24 +2113,28 @@ void init_image_layers(void) /* query */ - ADD_FUNCTION("image",image_layer_image,tFunc(,tObj),0); - ADD_FUNCTION("alpha",image_layer_alpha,tFunc(,tObj),0); - ADD_FUNCTION("mode",image_layer_mode,tFunc(,tStr),0); + ADD_FUNCTION("image",image_layer_image,tFunc(tNone,tObj),0); + ADD_FUNCTION("alpha",image_layer_alpha,tFunc(tNone,tObj),0); + ADD_FUNCTION("mode",image_layer_mode,tFunc(tNone,tStr),0); ADD_FUNCTION("available_modes",image_layer_available_modes, - tFunc(,tArr(tStr)),0); + tFunc(tNone,tArr(tStr)),0); - ADD_FUNCTION("xsize",image_layer_xsize,tFunc(,tInt),0); - ADD_FUNCTION("ysize",image_layer_ysize,tFunc(,tInt),0); + ADD_FUNCTION("xsize",image_layer_xsize,tFunc(tNone,tInt),0); + ADD_FUNCTION("ysize",image_layer_ysize,tFunc(tNone,tInt),0); - ADD_FUNCTION("xoffset",image_layer_xoffset,tFunc(,tInt),0); - ADD_FUNCTION("yoffset",image_layer_yoffset,tFunc(,tInt),0); + ADD_FUNCTION("xoffset",image_layer_xoffset,tFunc(tNone,tInt),0); + ADD_FUNCTION("yoffset",image_layer_yoffset,tFunc(tNone,tInt),0); - ADD_FUNCTION("alpha_value",image_layer_alpha_value,tFunc(,tFloat),0); - ADD_FUNCTION("fill",image_layer_fill,tFunc(,tObj),0); - ADD_FUNCTION("fill_alpha",image_layer_fill_alpha,tFunc(,tObj),0); + ADD_FUNCTION("alpha_value",image_layer_alpha_value,tFunc(tNone,tFloat),0); + ADD_FUNCTION("fill",image_layer_fill,tFunc(tNone,tObj),0); + ADD_FUNCTION("fill_alpha",image_layer_fill_alpha,tFunc(tNone,tObj),0); - ADD_FUNCTION("tiled",image_layer_tiled,tFunc(,tInt01),0); + ADD_FUNCTION("alpha_value",image_layer_alpha_value,tFunc(tNone,tFloat),0); + ADD_FUNCTION("fill",image_layer_fill,tFunc(tNone,tObj),0); + ADD_FUNCTION("fill_alpha",image_layer_fill_alpha,tFunc(tNone,tObj),0); + + ADD_FUNCTION("tiled",image_layer_tiled,tFunc(tNone,tInt01),0); /* image-object operations */ diff --git a/src/modules/Image/orient.c b/src/modules/Image/orient.c index 42dc72e58dd3db941503bb4d1ebe7913f9211959..565e0be18478976738b8aeab331975924b2c16c6 100644 --- a/src/modules/Image/orient.c +++ b/src/modules/Image/orient.c @@ -1,9 +1,9 @@ -/* $Id: orient.c,v 1.12 1999/06/18 19:19:28 mirar Exp $ */ +/* $Id: orient.c,v 1.13 1999/06/19 20:24:48 hubbe Exp $ */ /* **! module Image **! note -**! $Id: orient.c,v 1.12 1999/06/18 19:19:28 mirar Exp $ +**! $Id: orient.c,v 1.13 1999/06/19 20:24:48 hubbe Exp $ **! class Image */ @@ -95,7 +95,7 @@ static void chrono(char *x) **! output in later versions */ static INLINE int sq(int a) { return a*a; } -static INLINE int abs(int a) { return (a<0)?-a:a; } +static INLINE int my_abs(int a) { return (a<0)?-a:a; } static void _image_orient(struct image *source, struct object *o[4], @@ -132,7 +132,7 @@ CHRONO("start"); d[x+y*xz].CO \ = \ (COLORTYPE) \ - abs( s[(x+xd)+(y+yd)*xz].CO - s[(x-xd)+(y-yd)*xz].CO ) + my_abs( s[(x+xd)+(y+yd)*xz].CO - s[(x-xd)+(y-yd)*xz].CO ) /* sqrt( ( sq( s[(x-xd)+(y-yd)*xz].CO - s[x+y*xz].CO ) + \ @@ -240,11 +240,11 @@ CHRONO("begin hsv..."); int z,w; - if (abs(h)>abs(j)) - if (h) z=-(int)(32*(j/h)+(h>0)*128+64),w=abs(h); + if (my_abs(h)>my_abs(j)) + if (h) z=-(int)(32*(j/h)+(h>0)*128+64),w=my_abs(h); else z=0,w=0; else - z=-(int)(-32*(h/j)+(j>0)*128+128),w=abs(j); + z=-(int)(-32*(h/j)+(j>0)*128+128),w=my_abs(j); d->r=(COLORTYPE)z; d->g=255; diff --git a/src/modules/Image/polyfill.c b/src/modules/Image/polyfill.c index 7ac77c8535517f88d5e1a81019adcc4023791347..97a769e893b8daa837a0f7c6631e000d86275c0e 100644 --- a/src/modules/Image/polyfill.c +++ b/src/modules/Image/polyfill.c @@ -1,10 +1,15 @@ #include "global.h" -RCSID("$Id: polyfill.c,v 1.29 1999/06/08 17:31:22 grubba Exp $"); +RCSID("$Id: polyfill.c,v 1.30 1999/06/19 20:24:49 hubbe Exp $"); /* Prototypes are needed for these */ extern double floor(double); +#include "global.h" + +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif + #include <math.h> #include "image_machine.h" @@ -32,7 +37,7 @@ extern double floor(double); /* **! module Image **! note -**! $Id: polyfill.c,v 1.29 1999/06/08 17:31:22 grubba Exp $ +**! $Id: polyfill.c,v 1.30 1999/06/19 20:24:49 hubbe Exp $ **! class Image */ diff --git a/src/modules/Image/search.c b/src/modules/Image/search.c index 1d7c3e1a13f020593edd1da81f6f81546c237ce4..f182c4e9ac795ca26fc95d64f9aececd8474689a 100644 --- a/src/modules/Image/search.c +++ b/src/modules/Image/search.c @@ -97,7 +97,7 @@ static void chrono(char *x) **! output in later versions */ static INLINE int sq(int a) { return a*a; } -static INLINE int abs(int a) { return (a<0)?-a:a; } +static INLINE int my_abs(int a) { return (a<0)?-a:a; } /* phase-image creating functions */ @@ -139,7 +139,7 @@ static INLINE int abs(int a) { return (a<0)?-a:a; } **! **! <pre> **! new pixel value = -**! sum( abs(needle_pixel-haystack_pixel)) +**! sum( my_abs(needle_pixel-haystack_pixel)) **! </pre> **! **! The new image only have the red rgb-part set. @@ -181,7 +181,7 @@ static INLINE int abs(int a) { return (a<0)?-a:a; } #define NAME "match" #define INAME image_match #define PIXEL_VALUE_DISTANCE(CO) \ - (abs(haystacki[j].CO-needlei[ny*nxs+nx].CO)) + (my_abs(haystacki[j].CO-needlei[ny*nxs+nx].CO)) #include "match.h" #define NAME "match_phase" @@ -198,7 +198,7 @@ static INLINE int abs(int a) { return (a<0)?-a:a; } #define INAME image_match_norm #define NEEDLEAVRCODE #define PIXEL_VALUE_DISTANCE(CO) \ - (abs(( haystacki[j].CO-tempavr )-( needlei[ny*nxs+nx].CO-needle_average))) + (my_abs(( haystacki[j].CO-tempavr )-( needlei[ny*nxs+nx].CO-needle_average))) #include "match.h" #define NAME "match_norm_corr" diff --git a/src/modules/Oracle/oracle.c b/src/modules/Oracle/oracle.c index 7e1e5e24a8be1ed16e5d7b4de74409f6783e62b7..8658a4935d8594f82cae6a721cdaea4da9a8902a 100644 --- a/src/modules/Oracle/oracle.c +++ b/src/modules/Oracle/oracle.c @@ -1,5 +1,5 @@ /* - * $Id: oracle.c,v 1.16 1999/02/10 21:49:57 hubbe Exp $ + * $Id: oracle.c,v 1.17 1999/06/19 20:25:09 hubbe Exp $ * * Pike interface to Oracle databases. * @@ -36,7 +36,7 @@ #endif -RCSID("$Id: oracle.c,v 1.16 1999/02/10 21:49:57 hubbe Exp $"); +RCSID("$Id: oracle.c,v 1.17 1999/06/19 20:25:09 hubbe Exp $"); #ifdef HAVE_ORACLE @@ -723,11 +723,11 @@ void pike_module_init(void) /* function(object, array(string|int):void) */ ADD_FUNCTION("create", f_result_create,tFunc(tObj tArr(tOr(tStr,tInt)),tVoid), ID_PUBLIC); /* function(:int) */ - ADD_FUNCTION("num_fields", f_num_fields,tFunc(,tInt), ID_PUBLIC); + ADD_FUNCTION("num_fields", f_num_fields,tFunc(tNone,tInt), ID_PUBLIC); /* function(:array(mapping(string:mixed))) */ - ADD_FUNCTION("fetch_fields", f_fetch_fields,tFunc(,tArr(tMap(tStr,tMix))), ID_PUBLIC); + ADD_FUNCTION("fetch_fields", f_fetch_fields,tFunc(tNone,tArr(tMap(tStr,tMix))), ID_PUBLIC); /* function(:int|array(string|int)) */ - ADD_FUNCTION("fetch_row", f_fetch_row,tFunc(,tOr(tInt,tArr(tOr(tStr,tInt)))), ID_PUBLIC); + ADD_FUNCTION("fetch_row", f_fetch_row,tFunc(tNone,tOr(tInt,tArr(tOr(tStr,tInt)))), ID_PUBLIC); set_init_callback(init_dbresult_struct); set_exit_callback(exit_dbresult_struct); diff --git a/src/modules/Parser/html.c b/src/modules/Parser/html.c index 919850dd47a5d680d6ccad50446ea83f81114b97..e6e72d1e09525af95b316f458e6477c49c22c07d 100644 --- a/src/modules/Parser/html.c +++ b/src/modules/Parser/html.c @@ -157,7 +157,8 @@ struct parser_html_storage int num_look_for_end[MAX_ARGQ]; }; -typedef enum { P_DONE=0, P_WAIT, P_REREAD } newstate; +/* P_WAIT was already used by MSVC++ :( /Hubbe */ +typedef enum { Pi_DONE=0, Pi_WAIT, Pi_REREAD } newstate; #ifdef THIS #undef THIS /* Needed for NT */ @@ -1201,7 +1202,7 @@ static newstate handle_result(struct parser_html_storage *this, st2->c=0; this->stack=st2; THIS->stack_count++; - return P_REREAD; /* please reread stack head */ + return Pi_REREAD; /* please reread stack head */ case T_INT: switch (sp[-1].u.integer) @@ -1210,11 +1211,11 @@ static newstate handle_result(struct parser_html_storage *this, /* just output range */ put_out_feed_range(this,*head,*c_head,tail,c_tail); skip_feed_range(st,head,c_head,tail,c_tail); - return P_DONE; /* continue */ + return Pi_DONE; /* continue */ case 1: /* wait: "incomplete" */ skip_feed_range(st,head,c_head,tail,c_tail); - return P_WAIT; /* continue */ + return Pi_WAIT; /* continue */ } error("Parse.HTML: illegal result from callback: %d, " "not 0 (skip) or 1 (wait)\n", @@ -1230,7 +1231,7 @@ static newstate handle_result(struct parser_html_storage *this, put_out_feed(this,sp[-1].u.array->item[i].u.string); } skip_feed_range(st,head,c_head,tail,c_tail); - return P_DONE; /* continue */ + return Pi_DONE; /* continue */ default: error("Parse.HTML: illegal result from callback: not 0, string or array(string)\n"); @@ -1271,7 +1272,7 @@ static newstate entity_callback(struct parser_html_storage *this, { case T_STRING: push_svalue(v); - return P_DONE; + return Pi_DONE; case T_ARRAY: error("unimplemented"); @@ -1322,7 +1323,7 @@ static newstate tag_callback(struct parser_html_storage *this, { case T_STRING: push_svalue(v); - return P_DONE; + return Pi_DONE; case T_ARRAY: error("unimplemented"); @@ -1376,7 +1377,7 @@ static newstate container_callback(struct parser_html_storage *this, { case T_STRING: push_svalue(v); - return P_DONE; /* done */ + return Pi_DONE; /* done */ case T_ARRAY: error("unimplemented"); @@ -1452,7 +1453,7 @@ static newstate find_end_of_container(struct parser_html_storage *this, { DEBUG_MARK_SPOT("find_end_of_cont : wait\n",s1,c1); free_svalue(endtagname); - return P_WAIT; /* please wait */ + return Pi_WAIT; /* please wait */ } else { @@ -1460,7 +1461,7 @@ static newstate find_end_of_container(struct parser_html_storage *this, *e1=*e2=s1; *ce1=*ce2=c1; free_svalue(endtagname); - return P_DONE; /* end of tag, sure... */ + return Pi_DONE; /* end of tag, sure... */ } } DEBUG_MARK_SPOT("find_end_of_container got tag",feed,c); @@ -1468,7 +1469,7 @@ static newstate find_end_of_container(struct parser_html_storage *this, { DEBUG_MARK_SPOT("find_end_of_cont : wait for end\n",s1,c1); free_svalue(endtagname); - return P_WAIT; + return Pi_WAIT; } tag_name(this,s1,c1+1); @@ -1501,7 +1502,7 @@ static newstate find_end_of_container(struct parser_html_storage *this, *e2=s2; *ce2=c2+1; - return P_DONE; + return Pi_DONE; } else { @@ -1576,7 +1577,7 @@ static int do_try_feed(struct parser_html_storage *this, DEBUG((stderr,"%*d do_try_feed return %d %p:%d\n", this->stack_count,this->stack_count, res,*feed,st->c)); - st->ignore_data=(res==P_WAIT); + st->ignore_data=(res==Pi_WAIT); return res; } recheck_scan(this,&scan_entity,&scan_tag); @@ -1637,7 +1638,7 @@ static int do_try_feed(struct parser_html_storage *this, DEBUG((stderr,"%*d tag callback return %d %p:%d\n", this->stack_count,this->stack_count, res,*feed,st->c)); - st->ignore_data=(res==P_WAIT); + st->ignore_data=(res==Pi_WAIT); return res; } @@ -1665,7 +1666,7 @@ static int do_try_feed(struct parser_html_storage *this, DEBUG((stderr,"%*d find end of cont return %d %p:%d\n", this->stack_count,this->stack_count, res,*feed,st->c)); - st->ignore_data=(res==P_WAIT); + st->ignore_data=(res==Pi_WAIT); pop_stack(); return res; } @@ -1680,7 +1681,7 @@ static int do_try_feed(struct parser_html_storage *this, DEBUG((stderr,"%*d container callback return %d %p:%d\n", this->stack_count,this->stack_count, res,*feed,st->c)); - st->ignore_data=(res==P_WAIT); + st->ignore_data=(res==Pi_WAIT); return res; } @@ -1763,7 +1764,7 @@ static int do_try_feed(struct parser_html_storage *this, DEBUG((stderr,"%*d entity callback return %d %p:%d\n", this->stack_count,this->stack_count, res,*feed,st->c)); - st->ignore_data=(res==P_WAIT); + st->ignore_data=(res==Pi_WAIT); return res; } @@ -1834,7 +1835,7 @@ static void try_feed(int finished) :&(THIS->feed), finished||(THIS->stack->prev!=NULL))) { - case P_DONE: /* done, pop stack */ + case Pi_DONE: /* done, pop stack */ if (!THIS->feed) THIS->feed_end=NULL; st=THIS->stack->prev; @@ -1852,10 +1853,10 @@ static void try_feed(int finished) THIS->stack_count--; break; - case P_WAIT: /* incomplete, call again */ + case Pi_WAIT: /* incomplete, call again */ return; - case P_REREAD: /* reread stack head */ + case Pi_REREAD: /* reread stack head */ if (THIS->stack_count>THIS->max_stack_depth) error("Parse.HTML: too deep recursion\n"); break; @@ -2401,7 +2402,7 @@ static void html_clone(INT32 args) /****** module init *********************************/ #define tCbret tOr3(tInt0,tStr,tArr(tStr)) -#define tCbfunc(X) tOr(tFunc(,tCbret),tFunc(tObj X,tCbret)) +#define tCbfunc(X) tOr(tFunc(tNone,tCbret),tFunc(tObj X,tCbret)) #define tTodo(X) tOr3(tStr,tCbfunc(X),tArr(tCbfunc(X))) #define tTagargs tMap(tStr,tOr(tStr,tInt1)) @@ -2416,13 +2417,13 @@ void init_parser_html(void) #define CBRET "string|array(string)" /* 0|string|({string}) */ - ADD_FUNCTION("create",html_create,tFunc(,tVoid),0); - ADD_FUNCTION("clone",html_clone,tFuncV(,tMixed,tVoid),0); + ADD_FUNCTION("create",html_create,tFunc(tNone,tVoid),0); + ADD_FUNCTION("clone",html_clone,tFuncV(tNone,tMixed,tVoid),0); /* feed control */ - ADD_FUNCTION("feed",html_feed,tOr(tFunc(,tObj),tFunc(tStr tOr(tVoid,tInt),tObj)),0); - ADD_FUNCTION("finish",html_finish,tFunc(,tObj),0); + ADD_FUNCTION("feed",html_feed,tOr(tFunc(tNone,tObj),tFunc(tStr tOr(tVoid,tInt),tObj)),0); + ADD_FUNCTION("finish",html_finish,tFunc(tNone,tObj),0); ADD_FUNCTION("read",html_read,tFunc(tOr(tVoid,tInt),tStr),0); ADD_FUNCTION("write_out",html_write_out,tFunc(tStr,tObj),0); @@ -2430,15 +2431,15 @@ void init_parser_html(void) /* query */ - ADD_FUNCTION("current",html_current,tFunc(,tStr),0); + ADD_FUNCTION("current",html_current,tFunc(tNone,tStr),0); - ADD_FUNCTION("at",html_at,tFunc(,tArr(tInt)),0); - ADD_FUNCTION("at_line",html_at_line,tFunc(,tInt),0); - ADD_FUNCTION("at_char",html_at_char,tFunc(,tInt),0); - ADD_FUNCTION("at_column",html_at_column,tFunc(,tInt),0); + ADD_FUNCTION("at",html_at,tFunc(tNone,tArr(tInt)),0); + ADD_FUNCTION("at_line",html_at_line,tFunc(tNone,tInt),0); + ADD_FUNCTION("at_char",html_at_char,tFunc(tNone,tInt),0); + ADD_FUNCTION("at_column",html_at_column,tFunc(tNone,tInt),0); - ADD_FUNCTION("tag_name",html_tag_name,tFunc(,tStr),0); - ADD_FUNCTION("tag_args",html_tag_args,tFunc(,tMapping),0); + ADD_FUNCTION("tag_name",html_tag_name,tFunc(tNone,tStr),0); + ADD_FUNCTION("tag_args",html_tag_args,tFunc(tNone,tMapping),0); /* callback setup */ @@ -2457,11 +2458,11 @@ void init_parser_html(void) tFunc(tMap(tStr,tTodo( "" )),tVoid),0); ADD_FUNCTION("tags",html_tags, - tFunc(,tMap(tStr,tTodo( tTagargs ))),0); + tFunc(tNone,tMap(tStr,tTodo( tTagargs ))),0); ADD_FUNCTION("containers",html_containers, - tFunc(,tMap(tStr,tTodo( tTagargs tStr ))),0); + tFunc(tNone,tMap(tStr,tTodo( tTagargs tStr ))),0); ADD_FUNCTION("entities",html_entities, - tFunc(,tMap(tStr,tTodo( "" ))),0); + tFunc(tNone,tMap(tStr,tTodo( "" ))),0); /* special callbacks */ @@ -2475,7 +2476,7 @@ void init_parser_html(void) /* debug, whatever */ - ADD_FUNCTION("_inspect",html__inspect,tFunc(,tMapping),0); + ADD_FUNCTION("_inspect",html__inspect,tFunc(tNone,tMapping),0); /* just useful */ diff --git a/src/modules/Parser/parser.c b/src/modules/Parser/parser.c index eb368c7057a4526974c19dda9e44d8af0ade5080..f3bd1d6d5eef821a54ea741c2fb4ca97da72c789 100644 --- a/src/modules/Parser/parser.c +++ b/src/modules/Parser/parser.c @@ -1,7 +1,7 @@ #include "global.h" #include "stralloc.h" #include "global.h" -RCSID("$Id: parser.c,v 1.3 1999/06/12 13:42:42 mirar Exp $"); +RCSID("$Id: parser.c,v 1.4 1999/06/19 20:25:22 hubbe Exp $"); #include "pike_macros.h" #include "interpret.h" #include "program.h" @@ -55,6 +55,7 @@ static struct #define PARSER_CLASS(name,init,exit,prog) #define PARSER_SUBMODULE(name,init,exit) { name,init,exit }, #include "initstuff.h" + {0,0,0 } }; static struct @@ -71,6 +72,7 @@ static struct #define PARSER_SUBMODULE(a,b,c) #define PARSER_SUBMODMAG(name,init,exit) { name,init,exit,NULL,NULL }, #include "initstuff.h" + { 0,0,0,0,0 } }; #ifdef PIKE_DEBUG @@ -90,7 +92,7 @@ static void parser_magic_index(INT32 args) if (sp[-1].type!=T_STRING) error("Parser.`[]: Illegal type of argument\n"); - for (i=0; i<(int)NELEM(submagic); i++) + for (i=0; i<(int)NELEM(submagic)-1; i++) if (sp[-1].u.string==submagic[i].ps) { #ifdef PIKE_DEBUG @@ -168,7 +170,7 @@ void pike_module_init(void) add_program_constant(initclass[i].name,initclass[i].dest[0],0); } - for (i=0; i<(int)NELEM(initsubmodule); i++) + for (i=0; i<(int)NELEM(initsubmodule)-1; i++) { struct program *p; struct pike_string *s; @@ -190,7 +192,7 @@ void pike_module_init(void) pop_stack(); } - for (i=0; i<(int)NELEM(submagic); i++) + for (i=0; i<(int)NELEM(submagic)-1; i++) submagic[i].ps=make_shared_string(submagic[i].name); #undef PARSER_FUNCTION @@ -209,9 +211,9 @@ void pike_module_exit(void) (initclass[i].exit)(); free_program(initclass[i].dest[0]); } - for (i=0; i<(int)NELEM(initsubmodule); i++) + for (i=0; i<(int)NELEM(initsubmodule)-1; i++) (initsubmodule[i].exit)(); - for (i=0; i<(int)NELEM(submagic); i++) + for (i=0; i<(int)NELEM(submagic)-1; i++) if (submagic[i].o) { (submagic[i].exit)(); diff --git a/src/modules/Perl/perlmod.c b/src/modules/Perl/perlmod.c index 10f7bcf0a27759c4bcf780bfb4decfa7774b096e..df3383616660ccacd79f0be0e61665ae444861b8 100644 --- a/src/modules/Perl/perlmod.c +++ b/src/modules/Perl/perlmod.c @@ -227,7 +227,7 @@ void pike_module_init(void) /* function(array(string),void|mapping(string:string):int) */ ADD_FUNCTION("create",perlmod_create,tFunc(tArr(tStr) tOr(tVoid,tMap(tStr,tStr)),tInt),0); /* function(:int) */ - ADD_FUNCTION("run",perlmod_run,tFunc(,tInt),0); + ADD_FUNCTION("run",perlmod_run,tFunc(tNone,tInt),0); /* function(string:int) */ ADD_FUNCTION("eval",perlmod_eval,tFunc(tStr,tInt),0); /* function(string,mixed...:int) */ diff --git a/src/modules/Pipe/pipe.c b/src/modules/Pipe/pipe.c index 8359ad19c12e9a29e6729989a18c5d4d85ec047a..d713c6ed9f5d783d057ff66aa68d59819709d36c 100644 --- a/src/modules/Pipe/pipe.c +++ b/src/modules/Pipe/pipe.c @@ -26,7 +26,7 @@ #include <fcntl.h> -RCSID("$Id: pipe.c,v 1.32 1999/03/05 16:17:19 grubba Exp $"); +RCSID("$Id: pipe.c,v 1.33 1999/06/19 20:25:40 hubbe Exp $"); #include "threads.h" #include "stralloc.h" @@ -1267,7 +1267,7 @@ void pike_module_init(void) ADD_STORAGE(struct pipe); /* function(:array) */ - ADD_EFUN("_pipe_debug", f__pipe_debug,tFunc(,tArray), 0); + ADD_EFUN("_pipe_debug", f__pipe_debug,tFunc(tNone,tArray), 0); /* function(object:void) */ ADD_FUNCTION("input",pipe_input,tFunc(tObj,tVoid),0); /* function(object,void|int:void) */ @@ -1276,9 +1276,9 @@ void pike_module_init(void) ADD_FUNCTION("write",pipe_write,tFunc(tStr,tVoid),0); /* function(:void) */ - ADD_FUNCTION("start",pipe_start,tFunc(,tVoid),0); + ADD_FUNCTION("start",pipe_start,tFunc(tNone,tVoid),0); /* function(:void) */ - ADD_FUNCTION("finish",pipe_finish,tFunc(,tVoid),0); + ADD_FUNCTION("finish",pipe_finish,tFunc(tNone,tVoid),0); /* function(void|function(mixed,object:mixed),void|mixed:void) */ ADD_FUNCTION("set_output_closed_callback",pipe_set_output_closed_callback,tFunc(tOr(tVoid,tFunc(tMix tObj,tMix)) tOr(tVoid,tMix),tVoid),0); @@ -1295,10 +1295,10 @@ void pike_module_init(void) ADD_FUNCTION("_input_read_callback",pipe_read_input_callback,tFunc(tInt tStr,tVoid),0); /* function(:string) */ - ADD_FUNCTION("version",pipe_version,tFunc(,tStr),0); + ADD_FUNCTION("version",pipe_version,tFunc(tNone,tStr),0); /* function(:int) */ - ADD_FUNCTION("bytes_sent",f_bytes_sent,tFunc(,tInt),0); + ADD_FUNCTION("bytes_sent",f_bytes_sent,tFunc(tNone,tInt),0); set_init_callback(init_pipe_struct); set_exit_callback(exit_pipe_struct); diff --git a/src/modules/_Charset/charsetmod.c b/src/modules/_Charset/charsetmod.c index 9bfdb49edc57fcff8b930c03c6f33022e5864e08..da2fc46a8d48619b89785ee0b8d5b5e024ce633a 100644 --- a/src/modules/_Charset/charsetmod.c +++ b/src/modules/_Charset/charsetmod.c @@ -3,7 +3,7 @@ #endif /* HAVE_CONFIG_H */ #include "global.h" -RCSID("$Id: charsetmod.c,v 1.14 1999/04/29 15:11:54 mast Exp $"); +RCSID("$Id: charsetmod.c,v 1.15 1999/06/19 20:25:51 hubbe Exp $"); #include "program.h" #include "interpret.h" #include "stralloc.h" @@ -1082,9 +1082,9 @@ void pike_module_init(void) start_new_program(); ADD_STORAGE(struct std_cs_stor); /* function(:string) */ - ADD_FUNCTION("drain", f_drain,tFunc(,tStr), 0); + ADD_FUNCTION("drain", f_drain,tFunc(tNone,tStr), 0); /* function(:object) */ - ADD_FUNCTION("clear", f_clear,tFunc(,tObj), 0); + ADD_FUNCTION("clear", f_clear,tFunc(tNone,tObj), 0); /* function(string|void,function(string:string)|void:void) */ ADD_FUNCTION("create", f_create,tFunc(tOr(tStr,tVoid) tOr(tFunc(tStr,tStr),tVoid),tVoid), 0); /* function(function(string:string):void) */ @@ -1109,7 +1109,7 @@ void pike_module_init(void) /* function(string:object) */ ADD_FUNCTION("feed", f_feed_utf7,tFunc(tStr,tObj), 0); /* function(:object) */ - ADD_FUNCTION("clear", f_clear_utf7,tFunc(,tObj), 0); + ADD_FUNCTION("clear", f_clear_utf7,tFunc(tNone,tObj), 0); set_init_callback(utf7_init_stor); add_program_constant("UTF7dec", utf7_program = end_program(), ID_STATIC|ID_NOMASK); @@ -1125,7 +1125,7 @@ void pike_module_init(void) /* function(string:object) */ ADD_FUNCTION("feed", f_feed_utf7e,tFunc(tStr,tObj), 0); /* function(:string) */ - ADD_FUNCTION("drain", f_drain_utf7e,tFunc(,tStr), 0); + ADD_FUNCTION("drain", f_drain_utf7e,tFunc(tNone,tStr), 0); add_program_constant("UTF7enc", utf7e_program = end_program(), ID_STATIC|ID_NOMASK); prog.u.program = std_cs_program; diff --git a/src/modules/_Charset/iso2022.c b/src/modules/_Charset/iso2022.c index 7b7782712cf2dbb73c34bd8b8b5f6de9fd3d6b04..f287bfdbeae26782369cc6ffdfdf9a75477f9522 100644 --- a/src/modules/_Charset/iso2022.c +++ b/src/modules/_Charset/iso2022.c @@ -3,7 +3,7 @@ #endif /* HAVE_CONFIG_H */ #include "global.h" -RCSID("$Id: iso2022.c,v 1.9 1999/05/09 07:18:00 hubbe Exp $"); +RCSID("$Id: iso2022.c,v 1.10 1999/06/19 20:25:52 hubbe Exp $"); #include "program.h" #include "interpret.h" #include "stralloc.h" @@ -689,9 +689,9 @@ void iso2022_init(void) /* function(string:object) */ ADD_FUNCTION("feed", f_feed,tFunc(tStr,tObj), 0); /* function(:string) */ - ADD_FUNCTION("drain", f_drain,tFunc(,tStr), 0); + ADD_FUNCTION("drain", f_drain,tFunc(tNone,tStr), 0); /* function(:object) */ - ADD_FUNCTION("clear", f_clear,tFunc(,tObj), 0); + ADD_FUNCTION("clear", f_clear,tFunc(tNone,tObj), 0); set_init_callback(init_stor); set_exit_callback(exit_stor); add_program_constant("ISO2022Dec", iso2022dec_program = end_program(), @@ -702,9 +702,9 @@ void iso2022_init(void) /* function(string:object) */ ADD_FUNCTION("feed", f_enc_feed,tFunc(tStr,tObj), 0); /* function(:string) */ - ADD_FUNCTION("drain", f_enc_drain,tFunc(,tStr), 0); + ADD_FUNCTION("drain", f_enc_drain,tFunc(tNone,tStr), 0); /* function(:object) */ - ADD_FUNCTION("clear", f_enc_clear,tFunc(,tObj), 0); + ADD_FUNCTION("clear", f_enc_clear,tFunc(tNone,tObj), 0); /* function(string|void,function(string:string)|void:void) */ ADD_FUNCTION("create", f_create,tFunc(tOr(tStr,tVoid) tOr(tFunc(tStr,tStr),tVoid),tVoid), 0); /* function(function(string:string):void) */ diff --git a/src/modules/_Crypto/crypto.c b/src/modules/_Crypto/crypto.c index d2336cf3ff6a98c80b38481e746bc2906135877e..e073a0f64e0218180cd0d88a4e1f584fb06b9546 100644 --- a/src/modules/_Crypto/crypto.c +++ b/src/modules/_Crypto/crypto.c @@ -1,5 +1,5 @@ /* - * $Id: crypto.c,v 1.27 1999/02/10 21:51:33 hubbe Exp $ + * $Id: crypto.c,v 1.28 1999/06/19 20:26:00 hubbe Exp $ * * A pike module for getting access to some common cryptos. * @@ -28,7 +28,9 @@ #include <sys/mman.h> #endif #include <sys/stat.h> +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif #include <fcntl.h> #include <errno.h> diff --git a/src/modules/_Crypto/des.c b/src/modules/_Crypto/des.c index 7ce6c5b730d4127126b2fefd1a1eb54d364c1137..1e1c76c98abad854b43a5caa576f9f766d0aa83e 100644 --- a/src/modules/_Crypto/des.c +++ b/src/modules/_Crypto/des.c @@ -1,5 +1,5 @@ /* - * $Id: des.c,v 1.13 1999/02/10 21:51:34 hubbe Exp $ + * $Id: des.c,v 1.14 1999/06/19 20:26:01 hubbe Exp $ * * A pike module for getting access to some common cryptos. * @@ -31,7 +31,11 @@ #include <sys/mman.h> #endif #include <sys/stat.h> + +#ifdef HAVE_UNISTD_H #include <unistd.h> +#endif + #include <fcntl.h> #include <errno.h> diff --git a/src/modules/_Crypto/pipe.c b/src/modules/_Crypto/pipe.c index 89261efaed76b038b1522f4f73a567e90ae60e88..55191bf9a1545c266d0da5e9e36f79a648933c4d 100644 --- a/src/modules/_Crypto/pipe.c +++ b/src/modules/_Crypto/pipe.c @@ -1,5 +1,5 @@ /* - * $Id: pipe.c,v 1.14 1999/02/10 21:51:39 hubbe Exp $ + * $Id: pipe.c,v 1.15 1999/06/19 20:26:02 hubbe Exp $ * * PIPE crypto module for Pike. * @@ -307,7 +307,7 @@ void pike_pipe_init(void) ADD_STORAGE(struct pike_crypto_pipe); /* function(program|object|array(program|mixed) ...:void) */ - ADD_FUNCTION("create", f_create,tFuncV(,tOr3(tPrg,tObj,tArr(tOr(tPrg,tMix))),tVoid), 0); + ADD_FUNCTION("create", f_create,tFuncV(tNone,tOr3(tPrg,tObj,tArr(tOr(tPrg,tMix))),tVoid), 0); /* function(void:string) */ ADD_FUNCTION("name", f_name,tFunc(tVoid,tStr), 0); diff --git a/src/modules/_Image_TTF/image_ttf.c b/src/modules/_Image_TTF/image_ttf.c index 2cb0e7c46944826cf2dc2e054bff4f8c7c3d4886..5e810f9b046545ae51c0679e1cc04f5e29350d8e 100644 --- a/src/modules/_Image_TTF/image_ttf.c +++ b/src/modules/_Image_TTF/image_ttf.c @@ -1,12 +1,12 @@ /* - * $Id: image_ttf.c,v 1.16 1999/06/01 21:23:05 marcus Exp $ + * $Id: image_ttf.c,v 1.17 1999/06/19 20:26:11 hubbe Exp $ */ #include "config.h" #include "global.h" -RCSID("$Id: image_ttf.c,v 1.16 1999/06/01 21:23:05 marcus Exp $"); +RCSID("$Id: image_ttf.c,v 1.17 1999/06/19 20:26:11 hubbe Exp $"); #ifdef HAVE_LIBTTF #include <freetype.h> @@ -1260,18 +1260,18 @@ void pike_module_init(void) #ifdef TTF_DEBUG_INFO /* function(:mapping) */ - ADD_FUNCTION("properties",image_ttf_face_properties,tFunc(,tMapping),0); + ADD_FUNCTION("properties",image_ttf_face_properties,tFunc(tNone,tMapping),0); #endif /* TTF_DEBUG_INFO */ /* function(:object) */ - ADD_FUNCTION("flush",image_ttf_face_flush,tFunc(,tObj),0); + ADD_FUNCTION("flush",image_ttf_face_flush,tFunc(tNone,tObj),0); /* function(:mapping(string:string)) */ - ADD_FUNCTION("names",image_ttf_face_names,tFunc(,tMap(tStr,tStr)),0); + ADD_FUNCTION("names",image_ttf_face_names,tFunc(tNone,tMap(tStr,tStr)),0); /* function(:array(array)) */ - ADD_FUNCTION("_names",image_ttf_face__names,tFunc(,tArr(tArray)),0); + ADD_FUNCTION("_names",image_ttf_face__names,tFunc(tNone,tArr(tArray)),0); /* function(:object) */ - ADD_FUNCTION("`()",image_ttf_face_make,tFunc(,tObj),0); + ADD_FUNCTION("`()",image_ttf_face_make,tFunc(tNone,tObj),0); set_exit_callback(image_ttf_face_exit); image_ttf_face_program=end_program(); @@ -1286,9 +1286,9 @@ void pike_module_init(void) /* function(string:object) */ ADD_FUNCTION("ponder",image_ttf_faceinstance_ponder,tFunc(tStr,tObj),0); /* function(string...:object) */ - ADD_FUNCTION("write",image_ttf_faceinstance_write,tFuncV(,tStr,tObj),0); + ADD_FUNCTION("write",image_ttf_faceinstance_write,tFuncV(tNone,tStr,tObj),0); /* function(:object) */ - ADD_FUNCTION("face",image_ttf_faceinstance_face,tFunc(,tObj),0); + ADD_FUNCTION("face",image_ttf_faceinstance_face,tFunc(tNone,tObj),0); /* function(int:object) */ ADD_FUNCTION("set_height",image_ttf_faceinstance_set_height,tFunc(tInt,tObj),0); diff --git a/src/modules/call_out/call_out.c b/src/modules/call_out/call_out.c index 63f6b48c268f58992c1f33429c4f389397121800..bfda16b6100ff6ca5abaa8e4b1bcbb49da22d864 100644 --- a/src/modules/call_out/call_out.c +++ b/src/modules/call_out/call_out.c @@ -6,7 +6,7 @@ /**/ #include "global.h" #include "config.h" -RCSID("$Id: call_out.c,v 1.27 1999/05/02 08:12:32 hubbe Exp $"); +RCSID("$Id: call_out.c,v 1.28 1999/06/19 20:26:19 hubbe Exp $"); #include "array.h" #include "dynamic_buffer.h" #include "object.h" @@ -716,7 +716,7 @@ void pike_module_init(void) ADD_EFUN("call_out",f_call_out,tFuncV(tFunction tOr(tFlt,tInt),tMix,tMix),OPT_SIDE_EFFECT); /* function(:array*) */ - ADD_EFUN("call_out_info",f_call_out_info,tFunc(,tArr(tArray)),OPT_EXTERNAL_DEPEND); + ADD_EFUN("call_out_info",f_call_out_info,tFunc(tNone,tArr(tArray)),OPT_EXTERNAL_DEPEND); /* function(void:void) */ ADD_EFUN("_do_call_outs",f_do_call_outs,tFunc(tVoid,tVoid), diff --git a/src/modules/files/efuns.c b/src/modules/files/efuns.c index 68cd9b7445278b2d8685f17b526897138c3f85cd..fd4a628717430e3c9aa87f81f6779b6c3684715c 100644 --- a/src/modules/files/efuns.c +++ b/src/modules/files/efuns.c @@ -24,7 +24,7 @@ #include "file_machine.h" #include "file.h" -RCSID("$Id: efuns.c,v 1.71 1999/06/02 21:22:51 marcus Exp $"); +RCSID("$Id: efuns.c,v 1.72 1999/06/19 20:26:28 hubbe Exp $"); #ifdef HAVE_SYS_TYPES_H #include <sys/types.h> @@ -615,7 +615,7 @@ void f_get_dir(INT32 args) while(1) { -#ifdef HAVE_SOLARIS_READDIR_R +#if defined(HAVE_SOLARIS_READDIR_R) /* Solaris readdir_r returns the second arg on success, * and returns NULL on error or at end of dir. */ @@ -975,7 +975,7 @@ void init_files_efuns(void) #endif /* HAVE_STATVFS || HAVE_STATFS */ /* function(:int) */ - ADD_EFUN("errno",f_errno,tFunc(,tInt),OPT_EXTERNAL_DEPEND); + ADD_EFUN("errno",f_errno,tFunc(tNone,tInt),OPT_EXTERNAL_DEPEND); /* function(string,void|mixed...:void) */ ADD_EFUN("werror",f_werror,tFuncV(tStr,tOr(tVoid,tMix),tVoid),OPT_SIDE_EFFECT); @@ -996,7 +996,7 @@ void init_files_efuns(void) ADD_EFUN("cd",f_cd,tFunc(tStr,tInt),OPT_SIDE_EFFECT); /* function(:string) */ - ADD_EFUN("getcwd",f_getcwd,tFunc(,tStr),OPT_EXTERNAL_DEPEND); + ADD_EFUN("getcwd",f_getcwd,tFunc(tNone,tStr),OPT_EXTERNAL_DEPEND); /* function(string,mixed*,void|mapping(string:string):int) */ ADD_EFUN("exece",f_exece,tFunc(tStr tArr(tMix) tOr(tVoid,tMap(tStr,tStr)),tInt),OPT_SIDE_EFFECT); diff --git a/src/modules/files/socket.c b/src/modules/files/socket.c index ea091c6143116513abfb8ecbaed15ce7243d2030..23891ef6ec26599064849855ecc63d108e2170ac 100644 --- a/src/modules/files/socket.c +++ b/src/modules/files/socket.c @@ -18,7 +18,7 @@ #include "file_machine.h" #include "file.h" -RCSID("$Id: socket.c,v 1.42 1999/02/10 21:53:36 hubbe Exp $"); +RCSID("$Id: socket.c,v 1.43 1999/06/19 20:26:30 hubbe Exp $"); #ifdef HAVE_SYS_TYPE_H #include <sys/types.h> @@ -405,13 +405,13 @@ void port_setup_program(void) /* function(mixed:mixed) */ ADD_FUNCTION("set_id",port_set_id,tFunc(tMix,tMix),0); /* function(:mixed) */ - ADD_FUNCTION("query_id",port_query_id,tFunc(,tMix),0); + ADD_FUNCTION("query_id",port_query_id,tFunc(tNone,tMix),0); /* function(:string) */ - ADD_FUNCTION("query_address",socket_query_address,tFunc(,tStr),0); + ADD_FUNCTION("query_address",socket_query_address,tFunc(tNone,tStr),0); /* function(:int) */ - ADD_FUNCTION("errno",port_errno,tFunc(,tInt),0); + ADD_FUNCTION("errno",port_errno,tFunc(tNone,tInt),0); /* function(:object) */ - ADD_FUNCTION("accept",port_accept,tFunc(,tObj),0); + ADD_FUNCTION("accept",port_accept,tFunc(tNone,tObj),0); /* function(void|string|int,void|mixed,void|string:void) */ ADD_FUNCTION("create",port_create,tFunc(tOr3(tVoid,tStr,tInt) tOr(tVoid,tMix) tOr(tVoid,tStr),tVoid),0); diff --git a/src/modules/spider/dumudp.c b/src/modules/spider/dumudp.c index 6b4d75ff8151e488d300e8d4ed489aa8d8265203..911c1b2041de61119480ee5597d91df26c21ab4e 100644 --- a/src/modules/spider/dumudp.c +++ b/src/modules/spider/dumudp.c @@ -1,12 +1,12 @@ /* - * $Id: dumudp.c,v 1.43 1999/02/10 21:54:21 hubbe Exp $ + * $Id: dumudp.c,v 1.44 1999/06/19 20:26:40 hubbe Exp $ */ #include "global.h" #include "config.h" -RCSID("$Id: dumudp.c,v 1.43 1999/02/10 21:54:21 hubbe Exp $"); +RCSID("$Id: dumudp.c,v 1.44 1999/06/19 20:26:40 hubbe Exp $"); #include "fdlib.h" #include "interpret.h" #include "svalue.h" @@ -442,7 +442,7 @@ void init_udp(void) /* function(int,void|function,void|string:int) */ ADD_FUNCTION("bind",udp_bind,tFunc(tInt tOr(tVoid,tFunction) tOr(tVoid,tStr),tInt),0); /* function(:void) */ - ADD_FUNCTION("enable_broadcast", udp_enable_broadcast,tFunc(,tVoid), 0); + ADD_FUNCTION("enable_broadcast", udp_enable_broadcast,tFunc(tNone,tVoid), 0); /* function(int|void:mapping(string:int|string)) */ ADD_FUNCTION("read",udp_read,tFunc(tOr(tInt,tVoid),tMap(tStr,tOr(tInt,tStr))),0); /* function(string,int,string,void|int:int) */ @@ -454,7 +454,7 @@ void init_udp(void) /* function(void:void) */ ADD_FUNCTION( "set_blocking", udp_set_blocking,tFunc(tVoid,tVoid), 0 ); /* function(:string) */ - ADD_FUNCTION("query_address",udp_query_address,tFunc(,tStr),0); + ADD_FUNCTION("query_address",udp_query_address,tFunc(tNone,tStr),0); set_init_callback(zero_udp); set_exit_callback(exit_udp); end_class("dumUDP",0); diff --git a/src/modules/spider/spider.c b/src/modules/spider/spider.c index 6977fb45859c386ed8c789d215525f25a55987d1..ff0a18dd4d12b9c386fc41305004f43b0616e443 100644 --- a/src/modules/spider/spider.c +++ b/src/modules/spider/spider.c @@ -43,7 +43,7 @@ #include "threads.h" #include "operators.h" -RCSID("$Id: spider.c,v 1.81 1999/06/03 14:01:44 grubba Exp $"); +RCSID("$Id: spider.c,v 1.82 1999/06/19 20:26:41 hubbe Exp $"); #ifdef HAVE_PWD_H #include <pwd.h> @@ -1260,7 +1260,7 @@ void pike_module_init(void) /* function(:array(array)) */ - ADD_EFUN("_dump_obj_table", f__dump_obj_table,tFunc(,tArr(tArray)), + ADD_EFUN("_dump_obj_table", f__dump_obj_table,tFunc(tNone,tArr(tArray)), OPT_EXTERNAL_DEPEND); @@ -1280,10 +1280,10 @@ void pike_module_init(void) ADD_EFUN("stardate", f_stardate,tFunc(tInt tOr(tVoid,tInt),tInt), 0); /* function(:int) */ - ADD_EFUN("timezone", f_timezone,tFunc(,tInt), 0); + ADD_EFUN("timezone", f_timezone,tFunc(tNone,tInt), 0); /* function(:array(int)) */ - ADD_EFUN("get_all_active_fd", f_get_all_active_fd,tFunc(,tArr(tInt)), + ADD_EFUN("get_all_active_fd", f_get_all_active_fd,tFunc(tNone,tArr(tInt)), OPT_EXTERNAL_DEPEND); /* function(int:int) */ diff --git a/src/modules/spider/xml.c b/src/modules/spider/xml.c index 7e004eae852f6258101508be3a7fa6023879b8f6..36581a40272f03210758c0f1a59752cf27e811d8 100644 --- a/src/modules/spider/xml.c +++ b/src/modules/spider/xml.c @@ -2303,6 +2303,6 @@ void init_xml(void) add_function("parse",parse_xml,PARSETYPE,0); add_function("parse_dtd",parse_dtd,PARSETYPE,0); /* function(:void) */ - ADD_FUNCTION("create",create,tFunc(,tVoid),0); + ADD_FUNCTION("create",create,tFunc(tNone,tVoid),0); end_class("XML",0); } diff --git a/src/modules/system/nt.c b/src/modules/system/nt.c index e642be2746cd3fc47f325a7d29c9806ec8267d3a..bfe096f68191bde04519c632c32be433bc0e6d95 100644 --- a/src/modules/system/nt.c +++ b/src/modules/system/nt.c @@ -1,5 +1,5 @@ /* - * $Id: nt.c,v 1.11 1999/06/01 21:34:26 marcus Exp $ + * $Id: nt.c,v 1.12 1999/06/19 20:26:54 hubbe Exp $ * * NT system calls for Pike * @@ -111,8 +111,8 @@ static struct program *token_program; #define THIS_TOKEN (*(HANDLE *)(fp->current_storage)) -typedef BOOL WINAPI (*logonusertype)(LPSTR,LPSTR,LPSTR,DWORD,DWORD,PHANDLE); -typedef DWORD WINAPI (*getlengthsidtype)(PSID); +typedef BOOL (WINAPI *logonusertype)(LPSTR,LPSTR,LPSTR,DWORD,DWORD,PHANDLE); +typedef DWORD (WINAPI *getlengthsidtype)(PSID); static logonusertype logonuser; static getlengthsidtype getlengthsid; @@ -181,7 +181,7 @@ static void exit_token(struct object *o) static void low_encode_user_info_0(USER_INFO_0 *tmp) { -#define SAFE_PUSH_WSTR(X) \ +#define SAFE_PUSH_WSTR(X) \ if(X) \ push_string(make_shared_string1((p_wchar1 *) X)); \ else \ @@ -423,7 +423,7 @@ static void encode_localgroup_users_info(BYTE *u, int level) static void low_encode_localgroup_members_info_0(LOCALGROUP_MEMBERS_INFO_0 *tmp) { -#define SAFE_PUSH_SID(X) \ +#define SAFE_PUSH_SID(X) \ if(getlengthsid && (X)) \ push_string(make_shared_binary_string((char *)(X),getlengthsid((X)))); \ else \ @@ -538,13 +538,13 @@ static int sizeof_localgroup_members_info(int level) } } -typedef NET_API_STATUS WINAPI (*netusergetinfotype)(LPWSTR,LPWSTR,DWORD,LPBYTE *); -typedef NET_API_STATUS WINAPI (*netuserenumtype)(LPWSTR,DWORD,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD,LPDWORD); -typedef NET_API_STATUS WINAPI (*netusergetgroupstype)(LPWSTR,LPWSTR,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD); -typedef NET_API_STATUS WINAPI (*netusergetlocalgroupstype)(LPWSTR,LPWSTR,DWORD,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD); -typedef NET_API_STATUS WINAPI (*netgroupenumtype)(LPWSTR,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD,LPDWORD); -typedef NET_API_STATUS WINAPI (*netgroupgetuserstype)(LPWSTR,LPWSTR,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD,LPDWORD); -typedef NET_API_STATUS WINAPI (*netapibufferfreetype)(LPVOID); +typedef NET_API_STATUS (WINAPI *netusergetinfotype)(LPWSTR,LPWSTR,DWORD,LPBYTE *); +typedef NET_API_STATUS (WINAPI *netuserenumtype)(LPWSTR,DWORD,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD,LPDWORD); +typedef NET_API_STATUS (WINAPI *netusergetgroupstype)(LPWSTR,LPWSTR,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD); +typedef NET_API_STATUS (WINAPI *netusergetlocalgroupstype)(LPWSTR,LPWSTR,DWORD,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD); +typedef NET_API_STATUS (WINAPI *netgroupenumtype)(LPWSTR,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD,LPDWORD); +typedef NET_API_STATUS (WINAPI *netgroupgetuserstype)(LPWSTR,LPWSTR,DWORD,LPBYTE*,DWORD,LPDWORD,LPDWORD,LPDWORD); +typedef NET_API_STATUS (WINAPI *netapibufferfreetype)(LPVOID); static netusergetinfotype netusergetinfo; static netuserenumtype netuserenum; diff --git a/src/modules/system/system.c b/src/modules/system/system.c index 437680aaa95d95e0c5774eb14b0d75c4bab423ec..67e0391d0549690b5db61cc7d89cf53753eb6603 100644 --- a/src/modules/system/system.c +++ b/src/modules/system/system.c @@ -1,5 +1,5 @@ /* - * $Id: system.c,v 1.71 1999/06/01 21:44:49 grubba Exp $ + * $Id: system.c,v 1.72 1999/06/19 20:26:55 hubbe Exp $ * * System-call module for Pike * @@ -15,7 +15,7 @@ #include "system_machine.h" #include "system.h" -RCSID("$Id: system.c,v 1.71 1999/06/01 21:44:49 grubba Exp $"); +RCSID("$Id: system.c,v 1.72 1999/06/19 20:26:55 hubbe Exp $"); #ifdef HAVE_WINSOCK_H #include <winsock.h> #endif @@ -1102,7 +1102,7 @@ void pike_module_init(void) #ifdef HAVE_SETGROUPS /* function(:void) */ - ADD_EFUN("cleargroups", f_cleargroups,tFunc(,tVoid), OPT_SIDE_EFFECT); + ADD_EFUN("cleargroups", f_cleargroups,tFunc(tNone,tVoid), OPT_SIDE_EFFECT); /* NOT Implemented in Pike 0.5 */ /* function(array(int):void) */ @@ -1111,7 +1111,7 @@ void pike_module_init(void) #ifdef HAVE_GETGROUPS /* function(:array(int)) */ - ADD_EFUN("getgroups", f_getgroups,tFunc(,tArr(tInt)), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getgroups", f_getgroups,tFunc(tNone,tArr(tInt)), OPT_EXTERNAL_DEPEND); #endif /* HAVE_GETGROUPS */ #ifdef HAVE_INNETGR /* function(string, string|void, string|void, string|void:int) */ @@ -1143,37 +1143,37 @@ void pike_module_init(void) #ifdef HAVE_GETUID /* function(:int) */ - ADD_EFUN("getuid", f_getuid,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getuid", f_getuid,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); #endif #ifdef HAVE_GETGID /* function(:int) */ - ADD_EFUN("getgid", f_getgid,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getgid", f_getgid,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); #endif #ifdef HAVE_GETEUID /* function(:int) */ - ADD_EFUN("geteuid", f_geteuid,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("geteuid", f_geteuid,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); /* function(:int) */ - ADD_EFUN("getegid", f_getegid,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getegid", f_getegid,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); #endif /* HAVE_GETEUID */ /* function(:int) */ - ADD_EFUN("getpid", f_getpid,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getpid", f_getpid,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); #ifdef HAVE_GETPPID /* function(:int) */ - ADD_EFUN("getppid", f_getppid,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getppid", f_getppid,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); #endif /* HAVE_GETPPID */ #ifdef HAVE_GETPGRP /* function(:int) */ - ADD_EFUN("getpgrp", f_getpgrp,tFunc(,tInt), OPT_EXTERNAL_DEPEND); + ADD_EFUN("getpgrp", f_getpgrp,tFunc(tNone,tInt), OPT_EXTERNAL_DEPEND); #endif /* HAVE_GETPGRP */ #ifdef HAVE_CHROOT @@ -1186,13 +1186,13 @@ void pike_module_init(void) #ifdef HAVE_UNAME /* function(:mapping) */ - ADD_EFUN("uname", f_uname,tFunc(,tMapping), OPT_TRY_OPTIMIZE); + ADD_EFUN("uname", f_uname,tFunc(tNone,tMapping), OPT_TRY_OPTIMIZE); #endif /* HAVE_UNAME */ #if defined(HAVE_GETHOSTNAME) || defined(HAVE_UNAME) /* function(:string) */ - ADD_EFUN("gethostname", f_gethostname,tFunc(,tStr),OPT_TRY_OPTIMIZE); + ADD_EFUN("gethostname", f_gethostname,tFunc(tNone,tStr),OPT_TRY_OPTIMIZE); #endif /* HAVE_GETHOSTNAME || HAVE_UNAME */ #ifdef GETHOST_DECLARE @@ -1218,7 +1218,7 @@ void pike_module_init(void) ADD_EFUN("syslog", f_syslog,tFunc(tInt tStr,tVoid), 0); /* function(:void) */ - ADD_EFUN("closelog", f_closelog,tFunc(,tVoid), 0); + ADD_EFUN("closelog", f_closelog,tFunc(tNone,tVoid), 0); #endif /* HAVE_SYSLOG */ init_passwd();