ScummVM API documentation
forbidden.h
Go to the documentation of this file.
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef COMMON_FORBIDDEN_H
23 #define COMMON_FORBIDDEN_H
24 
41 #ifndef FORBIDDEN_SYMBOL_ALLOW_ALL
42 
43 // Make sure scummsys.h is always included first
44 #include "common/scummsys.h"
45 
46 
57 // Use debug and warning in common/textconsole.h
58 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_printf
59 #undef printf
60 #define printf FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
61 #endif
62 
63 // Use g_system->getSaveFileManager()->openForSaving
64 // to create output streams and use the stream's methods
65 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fprintf
66 #undef fprintf
67 #define fprintf FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
68 #endif
69 
70 // Use Common::String::format to format strings,
71 // and then debug or warning to output to console
72 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_vprintf
73 #undef vprintf
74 #define vprintf FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
75 #endif
76 
77 // Use Common::String::format to format strings,
78 // and then use the save file manager's methods to write
79 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_vfprintf
80 #undef vfprintf
81 #define vfprintf FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
82 #endif
83 
84 // Use Common::File in common/file.h
85 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_FILE
86 #undef FILE
87 #define FILE FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
88 #endif
89 
90 // Use g_system->getEventManager()->pollEvent to
91 // get events, one type of which is keyboard events
92 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_stdin
93 #undef stdin
94 #define stdin FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
95 #endif
96 
97 // Use debug and warning in common/textconsole.h
98 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_stdout
99 #undef stdout
100 #define stdout FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
101 #endif
102 
103 // Use debug and warning in common/textconsole.h
104 // ScummVM also has an error method, but this also
105 // exits the program immediately
106 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_stderr
107 #undef stderr
108 #define stderr FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
109 #endif
110 
111 // Use Common::File in common/file.h
112 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fopen
113 #undef fopen
114 #define fopen(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
115 #endif
116 
117 // Use Common::File in common/file.h
118 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fclose
119 #undef fclose
120 #define fclose(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
121 #endif
122 
123 // Use Common::File in common/file.h
124 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fread
125 #undef fread
126 #define fread(a,b,c,d) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
127 #endif
128 
129 // Use Common::File in common/file.h
130 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fwrite
131 #undef fwrite
132 #define fwrite(a,b,c,d) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
133 #endif
134 
135 // Use Common::File in common/file.h
136 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fseek
137 #undef fseek
138 #define fseek(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
139 #endif
140 
141 // Use Common::File in common/file.h
142 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_ftell
143 #undef ftell
144 #define ftell(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
145 #endif
146 
147 // Use Common::File in common/file.h
148 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_feof
149 #undef feof
150 #define feof(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
151 #endif
152 
153 // Use Common::File in common/file.h
154 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fgetc
155 #undef fgetc
156 #define fgetc(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
157 #endif
158 
159 // For writing to files use the save file manager
160 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fputc
161 #undef fputc
162 #define fputc(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
163 #endif
164 
165 // Use Common::File in common/file.h
166 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fgets
167 #undef fgets
168 #define fgets(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
169 #endif
170 
171 // For writing to files use the save file manager
172 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fputs
173 #undef fputs
174 #define fputs(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
175 #endif
176 
177 // Use g_system->getEventManager()->pollEvent to
178 // get events, one type of which is keyboard events
179 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_getc
180 #undef getc
181 #define getc(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
182 #endif
183 
184 // Use debug and warning in common/textconsole.h
185 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_putc
186 #undef putc
187 #define putc(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
188 #endif
189 
190 // Use g_system->getEventManager()->pollEvent to
191 // get events, one type of which is keyboard events
192 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_gets
193 #undef gets
194 #define gets(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
195 #endif
196 
197 // Use debug and warning in common/textconsole.h
198 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_puts
199 #undef puts
200 #define puts(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
201 #endif
202 
203 // Use g_system->getEventManager()->pollEvent to
204 // get events, one type of which is keyboard events
205 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_getchar
206 #undef getchar
207 #define getchar() FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
208 #endif
209 
210 // Use debug and warning in common/textconsole.h
211 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_putchar
212 #undef putchar
213 #define putchar(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
214 #endif
215 
216 // No equivalent in ScummVM
217 // mingw-w64 uses [set|long]jmp in system headers
218 #if !defined __MINGW64__ && ! defined __MINGW32__
219 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_setjmp
220 #undef setjmp
221 #define setjmp(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
222 #endif
223 
224 // No equivalent in ScummVM
225 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_longjmp
226 #undef longjmp
227 #define longjmp(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
228 #endif
229 #endif // __MINGW64__ __MINGW32__
230 
231 // No equivalent in ScummVM. The functionality of
232 // any system calls need to reimplemented as code
233 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_system
234 #undef system
235 #define system(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
236 #endif
237 
238 // You can either use error in common/textconsole.h
239 // to force stopping your engine, or do a call
240 // g_engine->quitGame(). For the latter, make sure to
241 // do g_engine->shouldQuit() checks in the loops of any
242 // calling methods so execution can break out of them
243 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_exit
244 #undef exit
245 #define exit(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
246 #endif
247 
248 // Use error or quitGame
249 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_abort
250 #undef abort
251 #define abort() FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
252 #endif
253 
254 // Use ConfMan in common/config-manager.h to save
255 // settings rather than environment variables
256 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_getenv
257 #undef getenv
258 #define getenv(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
259 #endif
260 
261 // Use ConfMan in common/config-manager.h to save
262 // settings rather than environment variables
263 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_putenv
264 #undef putenv
265 #define putenv(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
266 #endif
267 
268 // Use ConfMan in common/config-manager.h to save
269 // settings rather than environment variables
270 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_setenv
271 #undef setenv
272 #define setenv(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
273 #endif
274 
275 // Use ConfMan in common/config-manager.h to save
276 // settings rather than environment variables
277 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_unsetenv
278 #undef unsetenv
279 #define unsetenv(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
280 #endif
281 
282 
283 //
284 // Disable various symbols from time.h
285 // Use instead g_system->getTimeAndDate
286 //
287 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_time_h
288 
289  /*
290  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_time_t
291  #undef time_t
292  #define time_t FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
293  #endif
294  */
295 
296  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_asctime
297  #undef asctime
298  #define asctime(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
299  #endif
300 
301  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_clock
302  #undef clock
303  #define clock() FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
304  #endif
305 
306  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_ctime
307  #undef ctime
308  #define ctime(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
309  #endif
310 
311  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_difftime
312  #undef difftime
313  #define difftime(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
314  #endif
315 
316  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_getdate
317  #undef getdate
318  #define getdate(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
319  #endif
320 
321  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_gmtime
322  #undef gmtime
323  #define gmtime(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
324  #endif
325 
326  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_localtime
327  #undef localtime
328  #define localtime(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
329  #endif
330 
331  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_mktime
332  #undef mktime
333  #define mktime(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
334  #endif
335 
336  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_time
337  #undef time
338  #define time(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
339  #endif
340 
341 #endif // FORBIDDEN_SYMBOL_EXCEPTION_time_h
342 
343 //
344 // Disable various symbols from unistd.h
345 //
346 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_unistd_h
347 
348  // ScummVM does not allow changing the current directory
349  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_chdir
350  #undef chdir
351  #define chdir(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
352  #endif
353 
354  // ScummVM has no equivalent for getting the current directory.
355  // However, you can use ConfMan.getPath("path") to get the
356  // running game's directory
357  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_getcwd
358  #undef getcwd
359  #define getcwd(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
360  #endif
361 
362  // ScummVM has no equivalent for getting the current directory.
363  // However, you can use ConfMan.getPath("path") to get the
364  // running game's directory
365 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_getwd
366  #undef getwd
367  #define getwd(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
368  #endif
369 
370  // ScummVM only allows deleting save files, via the
371  // save file manager's removeSavefile method
372  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_unlink
373  #undef unlink
374  #define unlink(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
375  #endif
376 
377 #endif // FORBIDDEN_SYMBOL_EXCEPTION_unistd_h
378 
379 
380 //
381 // Disable various symbols from ctype.h
382 //
383 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_ctype_h
384 
385  // Use Common::isAlnum in common/util.h
386  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isalnum
387  #undef isalnum
388  #define isalnum(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
389  #endif
390 
391  // Use Common::isAlpha in common/util.h
392  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isalpha
393  #undef isalpha
394  #define isalpha(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
395  #endif
396 
397  // Use Common::isCntrl in common/util.h
398  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_iscntrl
399  #undef iscntrl
400  #define iscntrl(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
401  #endif
402 
403  // Use Common::isDigit in common/util.h
404  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isdigit
405  #undef isdigit
406  #define isdigit(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
407  #endif
408 
409  // Use Common::isGraph in common/util.h
410  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isgraph
411  #undef isgraph
412  #define isgraph(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
413  #endif
414 
415  // Use Common::isDigit in common/util.h
416  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isnumber
417  #undef isnumber
418  #define isnumber(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
419  #endif
420 
421  // Use Common::isLower in common/util.h
422  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_islower
423  #undef islower
424  #define islower(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
425  #endif
426 
427  // Use Common::isPrint in common/util.h
428  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isprint
429  #undef isprint
430  #define isprint(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
431  #endif
432 
433  // Use Common::isPunct in common/util.h
434  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_ispunct
435  #undef ispunct
436  #define ispunct(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
437  #endif
438 
439  // Use Common::isSpace in common/util.h
440  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isspace
441  #undef isspace
442  #define isspace(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
443  #endif
444 
445  // Use Common::isUpper in common/util.h
446  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isupper
447  #undef isupper
448  #define isupper(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
449  #endif
450 
451  // Use Common::isXDigit in common/util.h
452  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isxdigit
453  #undef isxdigit
454  #define isxdigit(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
455  #endif
456 
457  // Use Common::isBlank in common/util.h
458  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_isblank
459  #undef isblank
460  #define isblank(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
461  #endif
462 
463 #endif // FORBIDDEN_SYMBOL_EXCEPTION_ctype_h
464 
465 
466 //
467 // Disable various symbols from math.h
468 //
469 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_math_h
470 
471  // Use MIN in common/util.h
472  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fmin
473  #undef fmin
474  #define fmin(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
475  #endif
476 
477  // Use MIN in common/util.h
478  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fminf
479  #undef fminf
480  #define fminf(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
481  #endif
482 
483  // Use MAX in common/util.h
484  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fmax
485  #undef fmax
486  #define fmax(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
487  #endif
488 
489  // Use MAX in common/util.h
490  #ifndef FORBIDDEN_SYMBOL_EXCEPTION_fmaxf
491  #undef fmaxf
492  #define fmaxf(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
493  #endif
494 
495 #endif // FORBIDDEN_SYMBOL_EXCEPTION_math_h
496 
497 // Use Common::String::format
498 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_itoa
499 #undef itoa
500 #define itoa(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
501 #endif
502 
503 // Use Common::String::format
504 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_uitoa
505 #undef uitoa
506 #define uitoa(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
507 #endif
508 
509 // FIXME: Forbid atoi as well?
510 
511 // No equivalent in ScummVM
512 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_mkdir
513 #undef mkdir
514 #define mkdir(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
515 #endif
516 
517 /*
518 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_setlocale
519 #undef setlocale
520 #define setlocale(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
521 #endif
522 */
523 
524 // No equivalent in ScummVM
525 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_setvbuf
526 #undef setvbuf
527 #define setvbuf(a,b,c,d) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
528 #endif
529 
530 // Temporary files must be manually implemented using save files
531 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_tmpfile
532 #undef tmpfile
533 #define tmpfile() FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
534 #endif
535 
536 // Temporary files must be manually implemented using save files
537 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_tmpnam
538 #undef tmpnam
539 #define tmpnam(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
540 #endif
541 
542 // Temporary files must be manually implemented using save files
543 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_tempnam
544 #undef tempnam
545 #define tempnam(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
546 #endif
547 
548 // Define a Common::RandomSource as part of the engine,
549 // which has a getRandomNumber method
550 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_rand
551 #undef rand
552 #define rand() FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
553 #endif
554 
555 // Define a Common::RandomSource as part of the engine,
556 // which has a setSeed method
557 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_srand
558 #undef srand
559 #define srand(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
560 #endif
561 
562 // Define a Common::RandomSource as part of the engine,
563 // which has a getRandomNumber method
564 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_random
565 #undef random
566 #define random() FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
567 #endif
568 
569 // Define a Common::RandomSource as part of the engine,
570 // which has a setSeed method
571 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_srandom
572 #undef srandom
573 #define srandom(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
574 #endif
575 
576 // Use Common::strcat_s or Common::strlcat in common/str.h
577 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strcat
578 #undef strcat
579 #define strcat(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
580 #endif
581 
582 // Use Common::strcpy_s or Common::strlcpy in common/str.h
583 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strcpy
584 #undef strcpy
585 #define strcpy(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
586 #endif
587 
588 // Use Common::vsprintf_s in common/str.h or vsnprintf
589 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_vsprintf
590 #undef vsprintf
591 #define vsprintf(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
592 #endif
593 
594 // Use Common::sprintf_s in common/str.h or snprintf
595 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_sprintf
596 #undef sprintf
597 #define sprintf(a,b,...) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
598 #endif
599 
600 // Use scumm_stricmp in common/str.h
601 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_stricmp
602 #undef stricmp
603 #define stricmp(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
604 #endif
605 
606 // Use scumm_strnicmp in common/str.h
607 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strnicmp
608 #undef strnicmp
609 #define strnicmp(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
610 #endif
611 
612 // Use scumm_stricmp in common/str.h
613 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strcasecmp
614 #undef strcasecmp
615 #define strcasecmp(a,b) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
616 #endif
617 
618 // Use scumm_strnicmp in common/str.h
619 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strncasecmp
620 #undef strncasecmp
621 #define strncasecmp(a,b,c) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
622 #endif
623 
624 // Use scumm_strdup in common/str.h
625 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strdup
626 #undef strdup
627 #define strdup(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
628 #endif
629 
630 // Use Common::String.toLowercase()
631 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strlwr
632 #undef strlwr
633 #define strlwr(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
634 #endif
635 
636 // Use Common::String.toUppercase()
637 #ifndef FORBIDDEN_SYMBOL_EXCEPTION_strupr
638 #undef strupr
639 #define strupr(a) FORBIDDEN_look_at_common_forbidden_h_for_more_info SYMBOL !%*
640 #endif
641 
642 /*
643  * We also would like to disable the following symbols;
644  * however, these are also frequently used in regular code,
645  * e.g. for method names, so we don't override them.
646  * - read
647  * - remove
648  * - write
649  * - ...
650  */
651 
652 
653 #endif
654 
655 
656 #endif