diff --git a/lib/modules/Tools.pmod/Standalone.pmod/precompile.pike b/lib/modules/Tools.pmod/Standalone.pmod/precompile.pike index 61578e3579b0cc0e47c2ce4088e433bd8ba3c0de..c41cdd15e9a97e441a544920fd54bb14897e58ca 100644 --- a/lib/modules/Tools.pmod/Standalone.pmod/precompile.pike +++ b/lib/modules/Tools.pmod/Standalone.pmod/precompile.pike @@ -141,7 +141,6 @@ string usage = #"[options] <from> > <to> Currently, the following attributes are understood: efun; makes this function a global constant (no value) - nonstatic; makes PIKECLASSes and PIKEFUNs that are not static flags; ID_STATIC | ID_NOMASK etc. optflags; OPT_TRY_OPTIMIZE | OPT_SIDE_EFFECT etc. optfunc; Optimization function. @@ -1308,7 +1307,6 @@ array recursive(mixed func, array data, mixed ... args) // where. constant valid_attributes = (< "efun", - "nonstatic", "flags", "optflags", "optfunc", @@ -1876,9 +1874,8 @@ sprintf(" } else {\n" string define = make_unique_name("class", base, name, "defined"); ret+=DEFINE(define); - ret+=({sprintf("%sstruct program *%s=NULL;\n" + ret+=({sprintf("DEFAULT_CMOD_STORAGE struct program *%s=NULL;\n" "static int %s_fun_num=-1;\n", - attributes->nonstatic ? "" : "DEFAULT_CMOD_STORAGE ", program_var, program_var)}); ret+=subclass->declarations; ret+=subclass->code; @@ -2307,9 +2304,7 @@ static struct %s *%s_gdb_dummy_ptr; funcname = "NULL"; } else { ret+=({ - sprintf("%svoid %s(INT32 args) ", - attributes->nonstatic ? "" : "DEFAULT_CMOD_STORAGE ", - funcname), + sprintf("DEFAULT_CMOD_STORAGE void %s(INT32 args) ",funcname), "{","\n", }); @@ -2665,9 +2660,7 @@ static struct %s *%s_gdb_dummy_ptr; ret+=IFDEF(tmp->define, ({ sprintf("#define %s\n",define), sprintf("DEFAULT_CMOD_STORAGE ptrdiff_t %s = 0;\n", func_num), - sprintf("%svoid %s(INT32 args) ", - attributes->nonstatic ? "" : "DEFAULT_CMOD_STORAGE ", - funcname), + sprintf("DEFAULT_CMOD_STORAGE void %s(INT32 args) ",funcname), "{\n", })+out+({ "}\n", diff --git a/src/backend.cmod b/src/backend.cmod index b0c1b870ee5d1294664ec166aefa353923411fcb..6753309ca178059de6113ef86f5564090f28b507 100644 --- a/src/backend.cmod +++ b/src/backend.cmod @@ -177,6 +177,8 @@ struct hash_ent +#define DEFAULT_CMOD_STORAGE + DECLARATIONS @@ -273,7 +275,6 @@ struct Backend_struct *really_get_backend_for_fd(int fd) *! main backend APIs. */ PIKECLASS Backend -nonstatic; { /* Provide a unique count to be able to tell backends apart with _sprintf. */ static int unused_id = 0; @@ -3187,7 +3188,6 @@ static void sb_copy_selectors(struct sb_active_selectors *to, *! @[Backend] */ PIKECLASS PollDeviceBackend -nonstatic; { INHERIT Backend; @@ -4437,7 +4437,6 @@ static void check_set_timer(struct timeval tmp) *! @[Backend] */ PIKECLASS PollBackend -nonstatic; { INHERIT Backend; @@ -5041,7 +5040,6 @@ nonstatic; *! Backend based on the classic @tt{select(2)@} system call from BSD. */ PIKECLASS SelectBackend -nonstatic; { INHERIT Backend; diff --git a/src/iterators.cmod b/src/iterators.cmod index 9fd65a2cc3dd6c1279d4737a3c920148a0543741..ef290dcb8f3d22ffecef75a6d43342d3ea77bdbf 100644 --- a/src/iterators.cmod +++ b/src/iterators.cmod @@ -29,6 +29,8 @@ #define sp Pike_sp +#define DEFAULT_CMOD_STORAGE + DECLARATIONS /*! @class Iterator @@ -1182,7 +1184,6 @@ PIKECLASS file_line_iterator *! @endcode */ PIKECLASS string_split_iterator -nonstatic; { CVAR struct pike_string *buffer; CVAR struct pike_string *current; @@ -1871,7 +1872,6 @@ nonstatic; */ PIKEFUN object(Iterator) get_iterator(object|array|mapping|multiset|string data) efun; - nonstatic; { switch(TYPEOF(*data)) { diff --git a/src/modules/Gmp/mpf.cmod b/src/modules/Gmp/mpf.cmod index cca840992e6c1375da94b36d58fae16eb872c4b8..005e14eeaec235bed0e4b8d1ccef9630f11aca25 100644 --- a/src/modules/Gmp/mpf.cmod +++ b/src/modules/Gmp/mpf.cmod @@ -43,6 +43,8 @@ #define sp Pike_sp #define fp Pike_fp +#define DEFAULT_CMOD_STORAGE + DECLARATIONS #define THISMPF (&(THIS->n)) @@ -106,7 +108,6 @@ DECLARATIONS /* id PROG_GMP_MPF_ID; */ PIKECLASS mpf -nonstatic; { CVAR MP_FLT n; diff --git a/src/modules/Gmp/mpq.cmod b/src/modules/Gmp/mpq.cmod index c906e8fbbfa251abfc2f07541a32dac2b1b4f058..2bfc14309d4fa14c9befb9299063da7c17bf27b7 100644 --- a/src/modules/Gmp/mpq.cmod +++ b/src/modules/Gmp/mpq.cmod @@ -44,6 +44,8 @@ #define sp Pike_sp #define fp Pike_fp +#define DEFAULT_CMOD_STORAGE + DECLARATIONS #define THISMPQ (&(THIS->n)) @@ -60,7 +62,6 @@ DECLARATIONS /* id PROG_GMP_MPQ_ID; */ PIKECLASS mpq -nonstatic; { CVAR MP_RAT n;