Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

417 lines
19 KiB

  1. /************************************************************************/
  2. /* */
  3. /* RCPP - Resource Compiler Pre-Processor for NT system */
  4. /* */
  5. /* GETMSG.H - Include File for the message return function */
  6. /* */
  7. /* 28-Nov-90 w-BrianM Created to replace need for MKMSG.EXE */
  8. /* */
  9. /************************************************************************/
  10. /************************************************************************/
  11. /**** ****/
  12. /**** NOTE - All changes in this file MUST be duplicated in MSGS.H! ****/
  13. /**** ****/
  14. /************************************************************************/
  15. #include "msgs.h"
  16. #define LASTMSG -1
  17. struct msgtable {
  18. int usmsgnum;
  19. char * pmsg;
  20. } MSG_TABLE[] = {
  21. /****************************************************************/
  22. /* Messages */
  23. /****************************************************************/
  24. {MSG_LEFT, "left"},
  25. {MSG_RIGHT, "right"},
  26. {MSG_UC_UNNAMED, "UNNAMED"},
  27. {MSG_LC_UNNAMED, "<unnamed>"},
  28. {MSG_COMMA, "trailing ',' used for variable argument list"},
  29. {MSG_CAST_LVAL, "cast on lvalue"},
  30. {MSG_EXT_INIT, "extended initializer form"},
  31. {MSG_TYPEDEF, "benign typedef redefinition"},
  32. {MSG_EXT_REDEF, "redefined extern to static"},
  33. {MSG_MAC_FORMALS, "macro formals in strings"},
  34. {MSG_NO_SEMI, "missing ';' following last struct/union member"},
  35. {MSG_BITFIELDS, "bitfield types other than int"},
  36. {MSG_WARN, "warning"},
  37. {MSG_ERROR, "error"},
  38. {MSG_FATAL, "fatal error"},
  39. {MSG_BLOCK_FUNCDECL, "function given file scope"},
  40. {MSG_CASTTO_FUNC, "cast of data pointer to function pointer"},
  41. {MSG_CASTTO_NONFUNC, "cast of function pointer to data pointer"},
  42. {MSG_ELLIPSIS, "function declaration used ellipsis"},
  43. {MSG_TOLEVEL0, "used function declaration from a previous block"},
  44. /****************************************************************/
  45. /* Fatals */
  46. /****************************************************************/
  47. {1001, "Internal Compiler Error\n\t\t(compiler file '%s', line %d)\n\t\tPlease report this error to your local dealer"},
  48. {1002, "out of heap space"},
  49. {1003, "error count exceeds %d; stopping compilation"},
  50. {1004, "unexpected EOF"},
  51. {1005, "string too big for buffer"},
  52. {1006, "write error on compiler intermediate file"},
  53. {1007, "unrecognized flag '%s' in '%s'"},
  54. {1008, "no input file specified"},
  55. {1009, "compiler limit : macros too deeply nested"},
  56. {1010, "compiler limit : macro expansion too big"},
  57. {1011, "no output file specified"},
  58. {1012, "bad parenthesis nesting - missing '%c'"},
  59. {1013, "cannot open source file '%s'"},
  60. {1014, "too many include files"},
  61. {1015, "cannot open include file '%s'"},
  62. {1016, "#if[n]def expected an identifier"},
  63. {1017, "invalid integer constant expression"},
  64. {1018, "unexpected '#elif'"},
  65. {1019, "unexpected '#else'"},
  66. {1020, "unexpected '#endif'"},
  67. {1021, "bad preprocessor command '%s'"},
  68. {1022, "expected '#endif'"},
  69. {1023, "Could not open output file"},
  70. {1026, "parser stack overflow, please simplify your program"},
  71. {1027, "DGROUP data allocation exceeds 64K" /* QC, c23 */},
  72. {1028, "%s segment allocation exceeds 64K" /* QC */},
  73. {1031, "compiler limit : function calls too deeply nested" /* QC, c23 */},
  74. {1032, "cannot open object listing file '%s'" /* QC, c23 */},
  75. {1035, "expression too complex, please simplify" /* QC, c23 */},
  76. {1037, "cannot open object file '%s'" /* QC, c23 */},
  77. {1041, "cannot open compiler intermediate file - no more files"},
  78. {1042, "cannot open compiler intermediate file - no such file or directory"},
  79. {1043, "cannot open compiler intermediate file"},
  80. {1044, "out of disk space for compiler intermediate file"},
  81. {1045, "floating point overflow"},
  82. {1047, "too many %s flags, '%s'"},
  83. {1048, "unknown option '%c' in '%s'"},
  84. {1049, "invalid numerical argument '%s'"},
  85. {1052, "too many #if/#ifdef's"},
  86. {1053, "compiler limit : struct/union nesting"},
  87. {1054, "compiler limit : initializers too deeply nested"},
  88. {1055, "compiler limit : out of keys"},
  89. {1056, "compiler limit : out of macro expansion space"},
  90. {1057, "unexpected EOF in macro expansion (missing ')'?)"},
  91. {1059, "out of near heap space"},
  92. {1060, "out of far heap space"},
  93. {1061, "compiler limit : blocks too deeply nested" /* QC */},
  94. {1062, "error writing to preprocessor output file"},
  95. {1063, "compiler limit : compiler stack overflow" /* QC */},
  96. {1065, "compiler limit : '%s': macro definition too big"},
  97. {1067, "compiler limit : identifier overflowed internal buffer"},
  98. {1068, "compiler error : possible binary file for input"},
  99. {1000, "UNKNOWN FATAL ERROR\n\t\tPlease report this error to your local dealer"},
  100. /****************************************************************/
  101. /* Errors */
  102. /****************************************************************/
  103. {2001, "newline in constant"},
  104. {2003, "expected 'defined id'"},
  105. {2004, "expected 'defined(id)'"},
  106. {2005, "#line expected a line number, found '%s'"},
  107. {2006, "#include expected a file name, found '%s'"},
  108. {2007, "#define syntax"},
  109. {2008, "'%c' : unexpected in macro definition"},
  110. {2009, "reuse of macro formal '%s'"},
  111. {2010, "'%c' : unexpected in formal list"},
  112. {2012, "missing name following '<'"},
  113. {2013, "missing '>'"},
  114. {2014, "preprocessor command must start as first non-whitespace"},
  115. {2015, "too many chars in constant"},
  116. {2016, "no closing single quote"},
  117. {2017, "illegal escape sequence"},
  118. {2018, "unknown character '0x%x'"},
  119. {2019, "expected preprocessor command, found '%c'"},
  120. {2020, "illegal digit '%c' for base %d"},
  121. {2021, "expected exponent value, not '%c'"},
  122. {2022, "'%ld' : too big for char"},
  123. {2023, "divide by 0"},
  124. {2024, "mod by 0"},
  125. {2025, "'%s' : enum/struct/union type redefinition"},
  126. {2026, "'%s' : member of enum redefinition"},
  127. {2028, "struct/union member needs to be inside a struct/union"},
  128. {2029, "'%Fs' : bit-fields only allowed in structs"},
  129. {2030, "'%Fs' : struct/union member redefinition"},
  130. {2031, "'%Fs' : function cannot be struct/union member"},
  131. {2033, "'%Fs' : bit-field cannot have indirection"},
  132. {2034, "'%Fs' : bit-field type too small for number of bits"},
  133. {2035, "struct/union '%Fs' : unknown size"},
  134. {2036, "left of '%s%s' must have a struct/union type"},
  135. {2037, "left of '%s' specifies undefined struct/union '%Fs'"},
  136. {2038, "'%s' : not struct/union member"},
  137. {2039, "'->' requires struct/union pointer"},
  138. {2040, "'.' requires struct/union name"},
  139. {2042, "signed/unsigned keywords mutually exclusive"},
  140. {2043, "illegal break"},
  141. {2044, "illegal continue"},
  142. {2045, "'%s' : label redefined"},
  143. {2046, "illegal case"},
  144. {2047, "illegal default"},
  145. {2048, "more than one default"},
  146. {2050, "non-integral switch expression"},
  147. {2051, "case expression not constant"},
  148. {2052, "case expression not integral"},
  149. {2053, "case value %d already used"},
  150. {2054, "expected '(' to follow '%Fs'"},
  151. {2055, "expected formal parameter list, not a type list"},
  152. {2056, "illegal expression"},
  153. {2057, "expected constant expression"},
  154. {2058, "constant expression is not integral"},
  155. {2059, "syntax error : '%s'"},
  156. {2060, "syntax error : EOF"},
  157. {2061, "syntax error : identifier '%s'"},
  158. {2062, "type '%s' unexpected"},
  159. {2063, "'%s' : not a function"},
  160. {2064, "term does not evaluate to a function"},
  161. {2065, "'%s' : undefined"},
  162. {2066, "cast to function returning . . . is illegal"},
  163. {2067, "cast to array type is illegal"},
  164. {2068, "illegal cast"},
  165. {2069, "cast of 'void' term to non-void"},
  166. {2070, "'%Fs' : storage class must be 'extern'"},
  167. {2071, "'%Fs' : bad storage class"},
  168. {2072, "'%Fs' : initialization of a function"},
  169. {2075, "'%Fs' : array initialization needs curly braces"},
  170. {2076, "'%Fs' : struct/union initialization needs curly braces"},
  171. {2077, "non-scalar field initializer '%Fs'"},
  172. {2078, "too many initializers"},
  173. {2079, "'%Fs' uses undefined struct/union '%Fs'"},
  174. {2082, "redefinition of formal parameter '%Fs'"},
  175. {2084, "function '%Fs' already has a body"},
  176. {2085, "'%Fs' : not in formal parameter list"},
  177. {2086, "'%Fs' : redefinition"},
  178. {2087, "'%Fs' : missing subscript"},
  179. {2088, "use of undefined enum/struct/union '%Fs'"},
  180. {2090, "function returns array"},
  181. {2091, "function returns function"},
  182. {2092, "array element type cannot be function"},
  183. {2093, "cannot initialize a static or struct with address of automatic vars"},
  184. {2094, "label '%Fs' was undefined"},
  185. {2095, "'%Fs' : actual has type 'void' : parameter %d"},
  186. {2096, "struct/union comparison illegal"},
  187. {2097, "illegal initialization"},
  188. {2098, "non-address expression"},
  189. {2099, "non-constant offset"},
  190. {2100, "illegal indirection"},
  191. {2101, "'&' on constant"},
  192. {2102, "'&' requires lvalue"},
  193. {2103, "'&' on register variable"},
  194. {2104, "'&' on bit-field ignored"},
  195. {2105, "'%s' needs lvalue"},
  196. {2106, "'%s' : left operand must be lvalue"},
  197. {2107, "illegal index, indirection not allowed"},
  198. {2108, "non-integral index"},
  199. {2109, "subscript on non-array"},
  200. {2110, "'+' : 2 pointers"},
  201. {2111, "pointer + non-integral value"},
  202. {2112, "illegal pointer subtraction"},
  203. {2113, "'-' : right operand pointer"},
  204. {2114, "'%s' : pointer on left; needs integral right"},
  205. {2115, "'%s' : incompatible types"},
  206. {2116, "'%s' : bad %s operand"},
  207. {2117, "'%s' : illegal for struct/union"},
  208. {2118, "negative subscript"},
  209. {2119, "'typedefs' both define indirection"},
  210. {2120, "'void' illegal with all types"},
  211. {2125, "%Fs : allocation exceeds 64K" /* QC, c23 */},
  212. {2126, "%Fs : auto allocation exceeds %s" /* QC, c23 */},
  213. {2127, "parameter allocation exceeds 32K" /* QC, c23 */},
  214. {2130, "#line expected a string containing the file name, found '%s'"},
  215. {2131, "attributes specify more than one near/far/huge"},
  216. {2132, "syntax error : unexpected identifier"},
  217. {2133, "'%Fs' : unknown size"},
  218. {2134, "'%Fs' : struct/union too large"},
  219. {2137, "empty character constant"},
  220. {2138, "unmatched close comment '*/'"},
  221. {2139, "type following '%s' is illegal"},
  222. {2140, "argument type cannot be function returning . . ."},
  223. {2141, "value out of range for enum constant"},
  224. {2142, "ellipsis requires three periods"},
  225. {2143, "syntax error : missing '%s' before '%s'"},
  226. {2144, "syntax error : missing '%s' before type '%Fs'"},
  227. {2145, "syntax error : missing '%s' before identifier"},
  228. {2146, "syntax error : missing '%s' before identifier '%s'"},
  229. {2147, "unknown size"},
  230. {2148, "array too large"},
  231. {2149, "'%Fs' : named bit-field cannot have 0 width"},
  232. {2150, "'%Fs' : bit-field must have type int, signed int, or unsigned int"},
  233. {2151, "more than one cdecl/fortran/pascal attribute specified"},
  234. {2152, "'%s' : pointers to functions with different attributes"},
  235. {2153, "hex constants must have at least 1 hex digit"},
  236. {2154, "'%s' : does not refer to a segment name"},
  237. {2155, "'%s' : already in a segment"},
  238. {2156, "pragma must be at outer level"},
  239. {2157, "'%s' : must be declared before use in pragma list"},
  240. {2158, "'%s' : is a function"},
  241. {2159, "more than one storage class specified"},
  242. {2160, "## cannot occur at the beginning of a macro definition"},
  243. {2161, "## cannot occur at the end of a macro definition"},
  244. {2162, "expected macro formal parameter"},
  245. {2163, "'%s' : not available as an intrinsic"},
  246. {2164, "'%s' : intrinsic was not declared"},
  247. {2165, "'%s' : cannot modify pointers to data"},
  248. {2166, "lval specifies 'const' object"},
  249. {2167, "'%Fs' : too many actual parameters for intrinsic"},
  250. {2168, "'%Fs' : too few actual parameters for intrinsic"},
  251. {2169, "'%Fs' : is an intrinsic, it cannot be defined"},
  252. {2170, "'%s' : intrinsic not declared as a function"},
  253. {2171, "'%s' : bad operand"},
  254. {2172, "'%Fs' : actual is not a pointer : parameter %d"},
  255. {2173, "'%Fs' : actual is not a pointer : parameter %d, parameter list %d"},
  256. {2174, "'%Fs' : actual has type 'void' : parameter %d, parameter list %d"},
  257. {2175, "'%Fs' : unresolved external" /* QC */},
  258. {2176, "static far data not supported" /* QC */},
  259. {2177, "constant too big"},
  260. {2178, "'%s' : storage class for same_seg variables must be 'extern'"},
  261. {2179, "'%Fs' : was used in same_seg, but storage class is no longer 'extern'"},
  262. {2180, "controlling expression has type 'void'"},
  263. {2181, "pragma requires command line option '%s'" /* QC */},
  264. {2182, "'%Fs' : has type 'void'"},
  265. {2183, "'interrupt' function must be 'far'"},
  266. {2184, "'%s' function cannot be 'pascal/fortran'"},
  267. {2186, "'saveregs/interrupt' modifiers mutually exclusive"},
  268. {2187, "cast of near function pointer to far function pointer"},
  269. {2188, "#error : %s"},
  270. {2190, "'%s' : is a text segment"},
  271. {2191, "'%s' : is a data segment"},
  272. {2198, "'%Fs' : tried to be allocated in code segment '%Fs'"},
  273. {2199, "'%Fs' : tried to be allocated in data segment '%Fs'"},
  274. {2200, "'%Fs' : function has already been defined"},
  275. {2205, "'%Fs' : cannot initialize 'extern' block scoped variables"},
  276. {2400, "inline syntax error %s, found '%Fs'"},
  277. {2401, "'%s' : register must be base %s"},
  278. {2402, "'%s' : register must be index %s"},
  279. {2403, "'%s' : register must be base/index %s"},
  280. {2404, "'%s' : illegal register %s"},
  281. {2405, "illegal short forward reference with offset"},
  282. {2406, "'%s' : name undefined %s"},
  283. {2407, "illegal float register %s"},
  284. {2408, "illegal type on PTR operator %s"},
  285. {2409, "illegal type used as operator %s"},
  286. {2410, "'%s' : ambiguous member name %s"},
  287. {2411, "'%s' : illegal struct/union member %s"},
  288. {2412, "'%s' : label redefined"},
  289. {2413, "'%s' : illegal align size"},
  290. {2414, "illegal number of operands"},
  291. {2415, "improper operand type"},
  292. {2416, "'%s' : illegal opcode for processor"},
  293. {2417, "divide by zero %s"},
  294. {2419, "mod by zero %s"},
  295. {2420, "'%s' : illegal symbol %s"},
  296. {2421, "PTR operator used with register %s"},
  297. {2422, "illegal segment override %s"},
  298. {2424, "'%s' : improper expression %s"},
  299. {2425, "'%s' : non-constant expression %s"},
  300. {2426, "'%s' : illegal operator %s"},
  301. {2427, "'%Fs' : jump referencing label is out of range" /* QC */},
  302. {2428, "_asm not implemented"},
  303. {2000, "UNKNOWN ERROR\n\t\tPlease report this error to your local dealer"},
  304. /****************************************************************/
  305. /* Warnings */
  306. /****************************************************************/
  307. {4002, "too many actual parameters for macro '%s'"},
  308. {4003, "not enough actual parameters for macro '%s'"},
  309. {4004, "missing close parenthesis after 'defined'"},
  310. {4005, "'%s' : redefinition"},
  311. {4006, "#undef expected an identifier"},
  312. {4009, "string too big, trailing chars truncated"},
  313. {4011, "identifier truncated to '%s'"},
  314. {4012, "float constant in a cross compilation"},
  315. {4014, "'%Fs' : bit-field type must be unsigned"},
  316. {4015, "'%Fs' : bit-field type must be integral"},
  317. {4016, "'%s' : no function return type, using 'int' as default"},
  318. {4017, "cast of int expression to far pointer"},
  319. {4020, "'%Fs' : too many actual parameters"},
  320. {4021, "'%Fs' : too few actual parameters"},
  321. {4022, "'%Fs' : pointer mismatch : parameter %d"},
  322. {4024, "'%Fs' : different types : parameter %d"},
  323. {4026, "function was declared with formal argument list"},
  324. {4027, "function was declared without formal argument list"},
  325. {4028, "parameter %d declaration different"},
  326. {4029, "declared parameter list different from definition"},
  327. {4030, "first parameter list is longer than the second"},
  328. {4031, "second parameter list is longer than the first"},
  329. {4032, "unnamed struct/union as parameter"},
  330. {4033, "function must return a value"},
  331. {4034, "sizeof returns 0"},
  332. {4035, "'%Fs' : no return value"},
  333. {4037, "'%Fs' : formal parameters ignored"},
  334. {4038, "'%Fs' : formal parameter has bad storage class"},
  335. {4039, "'%Fs' : function used as an argument"},
  336. {4040, "near/far/huge on '%Fs' ignored"},
  337. {4042, "'%Fs' : has bad storage class"},
  338. {4044, "huge on '%Fs' ignored, must be an array"},
  339. {4045, "'%s' : array bounds overflow"},
  340. {4046, "'&' on function/array, ignored"},
  341. {4047, "'%s' : different levels of indirection"},
  342. {4048, "array's declared subscripts different"},
  343. {4049, "'%s' : indirection to different types"},
  344. {4051, "data conversion"},
  345. {4053, "at least one void operand"},
  346. {4058, "address of frame variable taken, DS != SS" /* QC, c23 */},
  347. {4060, "conversion of long address to short address" /* QC, c23 */},
  348. {4061, "long/short mismatch in argument : conversion supplied" /* QC, c23 */},
  349. {4062, "near/far mismatch in argument : conversion supplied" /* QC, c23 */},
  350. {4067, "unexpected characters following '%s' directive - newline expected"},
  351. {4068, "unknown pragma"},
  352. {4071, "'%Fs' : no function prototype given"},
  353. {4074, "non standard extension used - '%s'"},
  354. {4075, "size of switch expression or case constant too large - converted to int"},
  355. {4076, "'%s' : may be used on integral types only"},
  356. {4077, "unknown check_stack option"},
  357. {4079, "unexpected token '%s'"},
  358. {4080, "expected 'identifier' for segment name, found '%s'"},
  359. {4081, "expected a comma, found '%s'"},
  360. {4082, "expected an identifier, found '%s'"},
  361. {4083, "expected '(', found '%s'"},
  362. {4084, "expected a pragma keyword, found '%s'"},
  363. {4085, "expected [on | off]"},
  364. {4086, "expected [1 | 2 | 4]"},
  365. {4087, "'%Fs' : declared with 'void' parameter list"},
  366. {4088, "'%Fs' : pointer mismatch : parameter %d, parameter list %d"},
  367. {4089, "'%Fs' : different types : parameter %d, parameter list %d"},
  368. {4090, "different 'const' attributes"},
  369. {4091, "no symbols were declared"},
  370. {4092, "untagged enum/struct/union declared no symbols"},
  371. {4093, "unescaped newline in character constant in non-active code"},
  372. {4095, "expected ')', found '%s'"},
  373. {4098, "void function returning a value"},
  374. {4100, "'%Fs' : unreferenced formal parameter"},
  375. {4101, "'%Fs' : unreferenced local variable"},
  376. {4102, "'%Fs' : unreferenced label"},
  377. {4104, "'%s' : near data in same_seg pragma, ignored"},
  378. {4105, "'%Fs' : code modifiers only on function or pointer to function"},
  379. {4106, "pragma requires integer between 1 and 127"},
  380. {4107, "pragma requires integer between 15 and 255"},
  381. {4108, "pragma requires integer between 79 and 132"},
  382. {4109, "unexpected identifier '%s'"},
  383. {4110, "unexpected token 'int constant'"},
  384. {4111, "unexpected token 'string'"},
  385. {4112, "macro name '%s' is reserved, %s ignored"},
  386. {4113, "function parameter lists differed"},
  387. {4114, "same type qualifier used more than once"},
  388. {4115, "'%Fs' : type definition in formal parameter list"},
  389. {4116, "<no tag> : type definition in formal parameter list"},
  390. {4118, "pragma not supported"},
  391. {4401, "'%s' : member is bitfield"},
  392. {4402, "must use PTR operator"},
  393. {4403, "illegal PTR operator"},
  394. {4404, "period on directive ignored"},
  395. {4405, "'%s' : identifier is reserved word"},
  396. {4406, "operand on directive ignored"},
  397. {4407, "operand size conflict"},
  398. {4408, "'%s' : ambiguous label"},
  399. {4409, "illegal instruction size"},
  400. {4410, "illegal size for operand"},
  401. {4411, "'%s' : symbol resolves to displacement register"},
  402. {4412, "'%s' : identifier is also assembler mnemonic"},
  403. {4413, "Cannot determine file type for '%s' : assuming 8-bit ascii"},
  404. {4000, "UNKNOWN WARNING\n\t\tPlease report this error to your local dealer"},
  405. {LASTMSG, ""}
  406. };