blob: 798b39b02bc7907fa7fd622e30690ba1b2df9333 [file] [log] [blame]
PulkoMandy17fc7592022-07-28 18:27:54 +02001 @item "declaration expected" (Fatal, Error, ANSI-violation)
2
3 Something is pretty wrong with the source.
4
5
6 @item "only one input file allowed" (Fatal)
7
8 vbcc accepts only a single filename to compile. You can use a
9 frontend to compile multiple files or perhaps you mistyped an
10 option.
11
12
13 @item "Flag <%s> specified more than once" ()
14
15 You specified a command line option that should be specified only
16 once more than once. Maybe you have this option in your config-file
17 and used it in the command line, too?
18 The first occurrence will override the latter ones.
19
20
21 @item "Flag <%s> needs string" (Fatal)
22
23 This option hast to be specified with a string parameter, e.g.
24 -flag=foobar
25
26
27 @item "Flag <%s> needs value" (Fatal)
28
29 This option hast to be specified with an integer parameter, e.g.
30 -flag=1234
31
32
33 @item "Unknown Flag <%s>" (Fatal)
34
35 This option is not recognized by vbcc. Perhaps you mistyped it, used
36 the wrong case or specified an option of the frontend to vbcc?
37
38
39 @item "No input file" (Fatal)
40
41 You did not specify an input file. Your source file should not start
42 with a '-' and if you use a frontend make sure it has the proper
43 suffix.
44
45
46 @item "Could not open <%s> for input" (Fatal)
47
48 A file could not be opened.
49
50
51 @item "need a struct or union to get a member" (Error, ANSI-violation)
52
53 The source contains something like a.b where a is not a structure
54 or union.
55
56
57 @item "too many (%d) nested blocks" (Fatal, Error)
58
59 vbcc only allows a maximum number of nested blocks
60 (compund-statements). You can increase this number by changing
61 the line #define MAXN <something> in vbc.h and recompiling vbcc.
62
63
64 @item "left block 0" (Error, ANSI-violation)
65
66 This error should not occur.
67
68
69 @item "incomplete struct <%s>" (Error, ANSI-violation)
70
71 You tried to get a member of an incomplete structure/union.
72 You defined struct x y; somewhere without defining struct x@{...@}.
73
74
75 @item "out of memory" (Fatal, Error)
76
77 Guess what.
78
79
80 @item "redeclaration of struct <%s>" (Error, ANSI-violation)
81
82 You may not redeclare a struct/union in the same block.
83
84
85 @item "incomplete type (%s) in struct" (Error, ANSI-violation)
86
87 Every member in a struct/union declaration must be complete.
88 Perhaps you only wanted a pointer to that type and forgot the '*'?
89
90
91 @item "function (%s) in struct/union" (Error, ANSI-violation)
92
93 Functions cannot be members of structs/unions.
94
95
96 @item "redeclaration of struct/union member <%s>" (Error, ANSI-violation)
97
98 Two members of a struct/union have the same name.
99
100
101 @item "redeclaration of <%s>" (Error, ANSI-violation)
102
103 You used a name already in use in an enumeration.
104
105
106 @item "invalid constant expression" (Error, ANSI-violation)
107
108 ??? Nowhere to find...
109
110
111 @item "array dimension must be constant integer" (Error, ANSI-violation)
112
113 The dimensions of an array must be constants (real constants,
114 const int x=100; int y[x]; is not allowed) and integers
115 (int y[100.0]; is not allowed either).
116
117
118 @item "no declarator and no identifier in prototype" (Error, ANSI-violation)
119
120
121
122 @item "invalid storage-class in prototype" (Error, ANSI-violation)
123
124 Function parameters may only be auto or register.
125
126
127 @item "void not the only function argument" (Error, ANSI-violation)
128
129 You tried to declare a function that has an argument of type void
130 as well as other arguments.
131
132
133 @item "<%s> no member of struct/union" (Error, ANSI-violation)
134
135 The struct/union does not contain a member called like that.
136
137
138 @item "increment/decrement is only allowed for aithmetic and pointer types" (Error, ANSI-violation)
139
140
141
142 @item "functions may not return arrays or functions" (Error, ANSI-violation)
143
144
145
146 @item "only pointers to functions can be called" (Error, ANSI-violation)
147
148 You tried to call something that did not decay into a pointer to
149 a function.
150
151
152 @item "redefinition of var <%s>" (Error, ANSI-violation)
153
154
155
156 @item "redeclaration of var <%s> with new storage-class" (Error, ANSI-violation)
157
158
159
160 @item "first operand of conditional-expression must be arithmetic or pointer type" (Error, ANSI-violation)
161
162
163
164 @item "multiple definitions of var <%s>" (Error, ANSI-violation)
165
166 There have been multiple definitions of a global variable with
167 initialization.
168
169
170 @item "operands of : do not match" (Error, ANSI-violation)
171
172 In an expression of the form a ? b : c
173 - a and b must have the same type or
174 - a and b both must have arithmetic types or
175 - one of them must be a pointer and the other must be void * or 0
176
177
178 @item "function definition in inner block" (Error, ANSI-violation)
179
180 C does not allow nested functions.
181
182
183 @item "redefinition of function <%s>" (Error, ANSI-violation)
184
185 Defining two functions with the same name in one translation-unit
186 is no good idea.
187
188
189 @item "invalid storage-class for function" (Error, ANSI-violation)
190
191 Functions must not have storage-classes register or auto.
192
193
194 @item "declaration-specifiers expected" (Error, ANSI-violation)
195
196
197
198 @item "declarator expected" (Error, ANSI-violation)
199
200
201
202 @item "<%s> is no parameter" (Error, ANSI-violation)
203
204 In an old-style function definition you tried to declare a name as
205 parameter which was not in the identifier-list.
206
207
208 @item "assignment of different structs/unions" (Error, ANSI-violation)
209
210
211
212 @item "invalid types for assignment" (Error, ANSI-violation)
213
214 In an assignment-context (this includes passing arguments to
215 prototyped functions) the source and target must be one of the
216 following types:
217
218 - both are arithmetic types
219 - both are the same struct/union
220 - one of them is a pointer to void and the other one is any pointer
221 - the target is any pointer and the source is an integral
222 constant-expression with the value 0
223 - both are pointer to the same type (here the target may have
224 additional const/volatile qualifiers - not recursively, however)
225
226 Any other combinations should be illegal.
227
228
229 @item "only 0 can be compared against pointer" (Warning, ANSI-violation)
230
231 You may not compare a pointer against any other constant but a
232 0 (null pointer).
233
234
235 @item "pointers do not point to the same type" (Warning, ANSI-violation)
236
237 You tried to compare or assign pointers that point to different
238 types. E.g. the types they point to may have different attributes.
239
240
241 @item "function initialized" (Error, Fatal, ANSI-violation)
242
243 There was a '=' after a function declaration.
244
245
246 @item "initialization of incomplete struct" (Error, Fatal, ANSI-violation)
247
248 A structure is incomplete if the only its name, but not the
249 content is known. You cannot do much with such structures.
250
251
252 @item "initialization of incomplete union" (Error, Fatal, ANSI-violation)
253
254 A union is incomplete if the only its name, but not the
255 content is known. You cannot do much with such unions.
256
257
258 @item "empty initialization" (Error, ANSI-violation)
259
260 There was no valid expression after the '=' in a variable definition.
261
262
263 @item "initializer not a constant" (Error, ANSI-violation)
264
265 Static variables and compound types may only be initialized with
266 constants.
267 Variables with const qualifier are no valid constant-expressions
268 here.
269
270 Addresses of static variables are ok, but casting them may turn
271 them into non-constant-expressions.
272
273
274 @item "double type-specifier" (Warning, ANSI-violation)
275
276
277
278 @item "illegal type-specifier" (Warning, ANSI-violation)
279
280
281
282 @item "multiple storage-classes" (Warning, ANSI-violation)
283
284
285
286 @item "storage-class specifier should be first" (Warning, ANSI-violation)
287
288
289
290 @item "bitfields must be ints" (Warning, ANSI-violation)
291
292
293
294 @item "bitfield width must be constant integer" (Warning, ANSI-violation)
295
296
297
298 @item "struct/union member needs identifier" (Warning, ANSI-violation)
299
300
301
302 @item "; expected" (Warning, ANSI-violation)
303
304 Probably you forgot a ';' or there is a syntactic error in an
305 expression.
306
307
308 @item "struct/union has no members" (Warning, ANSI-violation)
309
310 You defined an empty struct or union.
311
312
313 @item "@} expected" (Warning, ANSI-violation)
314
315
316
317 @item ", expected" (Warning, ANSI-violation)
318
319
320
321 @item "invalid unsigned" (Warning, ANSI-violation)
322
323
324
325 @item ") expected" (Warning, ANSI-violation)
326
327
328
329 @item "array dimension has sidefx (will be ignored)" (Warning, ANSI-violation)
330
331
332
333 @item "array of size 0 (set to 1)" (Warning, ANSI-violation)
334
335 ANSI C does not allow arrays or any objects to have a size of 0.
336
337
338 @item "] expected" (Warning, ANSI-violation)
339
340
341
342 @item "mixed identifier- and parameter-type-list" (Warning, ANSI-violation)
343
344
345
346 @item "var <%s> was never assigned a value" (Warning)
347
348
349
350 @item "var <%s> was never used" (Warning)
351
352
353
354 @item "invalid storage-class" (Warning, ANSI-violation)
355
356
357
358 @item "type defaults to int" (Warning)
359
360
361
362 @item "redeclaration of var <%s> with new type" (Warning, ANSI-violation)
363
364
365
366 @item "redeclaration of parameter <%s>" (Warning, ANSI-violation)
367
368
369
370 @item ": expected" (Warning, ANSI-violation)
371
372
373
374 @item "illegal escape-sequence in string" (Warning, ANSI-violation)
375
376
377
378 @item "character constant contains multiple chars" (Warning)
379
380
381
382 @item "could not evaluate sizeof-expression" (Error, ANSI-violation)
383
384
385
386 @item "" expected (unterminated string)" (Error, ANSI-violation)
387
388
389
390 @item "something wrong with numeric constant" (Error, ANSI-violation)
391
392
393
394 @item "identifier expected" (Fatal, Error, ANSI-violation)
395
396
397
398 @item "definition does not match previous declaration" (Warning, ANSI-violation)
399
400
401
402 @item "integer added to illegal pointer" (Warning, ANSI-violation)
403
404
405
406 @item "offset equals size of object" (Warning)
407
408
409
410 @item "offset out of object" (Warning, ANSI-violation)
411
412
413
414 @item "only 0 should be cast to pointer" (Warning)
415
416
417
418 @item "unknown identifier <%s>" (Error, ANSI-violation)
419
420
421
422 @item "too few function arguments" (Warning, ANSI-violation)
423
424
425
426 @item "division by zero (result set to 0)" (Warning, ANSI-violation)
427
428
429
430 @item "assignment of different pointers" (Warning, ANSI-violation)
431
432
433
434 @item "lvalue required for assignment" (Error, ANSI-violation)
435
436
437
438 @item "assignment to constant type" (Error, ANSI-violation)
439
440
441
442 @item "assignment to incomplete type" (Error, ANSI-violation)
443
444
445
446 @item "operands for || and && have to be arithmetic or pointer" (Error, ANSI-violation)
447
448
449
450 @item "bitwise operations need integer operands" (Error, ANSI-violation)
451
452
453
454 @item "assignment discards const" (Warning, ANSI-violation)
455
456 You assigned something like (const type *) to (type *).
457
458
459 @item "relational expression needs arithmetic or pointer type" (Error, ANSI-violation)
460
461
462
463 @item "both operands of comparison must be pointers" (Error, ANSI-violation)
464
465 You wrote an expression like a == b where one operand was a pointer
466 while the other was not. Perhaps a function is not declared correctly
467 or you used NULL instead of 0?
468
469
470 @item "operand needs arithmetic type" (Error, ANSI-violation)
471
472
473
474 @item "pointer arithmetic with void * is not possible" (Error, ANSI-violation)
475
476 Adding/subtracting from a pointer to void is not possible.
477
478
479 @item "pointers can only be subtracted" (Error, ANSI-violation)
480
481 You cannot add, multiply etc. two pointers.
482
483
484 @item "invalid types for operation <%s>" (Error, ANSI-violation)
485
486
487
488 @item "invalid operand type" (Error, ANSI-violation)
489
490
491
492 @item "integer-pointer is not allowed" (Error, ANSI-violation)
493
494 You may not subtract a pointer from an integer.
495 Adding an integer or subtracting it from a pointer is ok.
496
497
498@item "assignment discards volatile" (Warning, ANSI-violation)
499
500 You assigned something like (volatile type *) to (type *).
501
502
503@item "<<, >> and % need integer operands" (Error, ANSI-violation)
504
505
506
507@item "casting from void is not allowed" (Error, ANSI-violation)
508
509 Casting something of type void to anything makes no sense.
510
511
512@item "integer too large to fit into pointer" (Error, ANSI-violation)
513
514 You tried to assign an integer to a pointer that is too small to
515 hold the integer.
516 Note that assignment of pointers<->integers is never portable.
517
518
519@item "only integers can be cast to pointers" (Error, ANSI-violation)
520
521
522
523@item "invalid cast" (Error, ANSI-violation)
524
525
526
527@item "pointer too large to fit into integer" (Error, ANSI-violation)
528
529 You tried to assign a pointer to an integer that is too small to
530 hold the pointer.
531 Note that assignment of pointers<->integers is never portable.
532
533
534@item "unary operator needs arithmetic type" (Error, ANSI-violation)
535
536
537
538@item "negation type must be arithmetic or pointer" (Error, ANSI-violation)
539
540
541
542@item "complement operator needs integer type" (Error, ANSI-violation)
543
544
545
546@item "pointer assignment with different qualifiers" (Warning, ANSI-violation)
547
548 You tried to assign a pointer to a pointer that points to a type
549 with different qualifiers (e.g. signed<->unsigned).
550
551
552@item "dereferenced object is no pointer" (Error, ANSI-violation)
553
554
555
556@item "dereferenced object is incomplete" (Error, ANSI-violation)
557
558 You tried to dereference a pointer to an incomplete object.
559 Either you had a pointer to an array of unknown size or a pointer
560 to a struct or union that was not (yet) defined.
561
562
563@item "only 0 should be assigned to pointer" (Warning, ANSI-violation)
564
565 You may not assign constants other than a null pointer to any
566 pointer.
567
568
569@item "typedef <%s> is initialized" (Warning, ANSI-violation)
570
571
572
573@item "lvalue required to take address" (Error, ANSI-violation)
574
575 You can only get the address of an object, but not of expressions
576 etc.
577
578
579@item "unknown var <%s>" (Error, ANSI-violation)
580
581
582
583@item "address of register variables not available" (Error, ANSI-violation)
584
585 If a variable is declared as 'register' its address may not be
586 taken (no matter if the variable actually gets assigned to a
587 register).
588
589
590@item "var <%s> initialized after 'extern'" (Warning)
591
592
593
594@item "const var <%s> not initialized" (Warning)
595
596 A constant variable was not initialized in its definition.
597 As there is no other legal way to assign a value to a constant
598 variable this is probable an error.
599
600
601@item "function definition after 'extern'" (Warning, ANSI-violation)
602
603
604
605@item "return type of main is not int" (Warning, ANSI-violation)
606
607 main() should be defined as
608
609 int main(int argc, char **argv)
610
611 Especially the return type of main must be 'int' - 'void' is
612 not allowed by ANSI C.
613
614
615@item "invalid storage-class for function parameter" (Warning, ANSI-violation)
616
617 Function parameters may only have 'auto' or 'register' as
618 storage-class. 'static' or 'extern' are not allowed.
619
620
621@item "formal parameters conflict with parameter-type-list" (Warning, ANSI-violation)
622
623
624
625@item "parameter type defaults to int" (Warning)
626
627 A function definition contains no explicit type specifier.
628 'int' will be assumed.
629
630
631@item "no declaration-specifier, used int" (Warning, ANSI-violation)
632
633 A variable was declared/defined without a type specified.
634 This is not allowed in ANSI C (apart from functions).
635
636
637@item "no declarator in prototype" (Warning, ANSI-violation)
638
639
640
641@item "static var <%s> never defined" (Warning)
642
643
644
645@item "@} expected" (Warning)
646
647
648
649@item "left operand of comma operator has no side-effects" (Warning)
650
651 In an expression of the form a,b a has no side-effects and is
652 therefore superfluous.
653
654
655@item "label empty" (Error, ANSI-violation)
656
657 There was a ':' without an identifier before it.
658
659
660@item "redefinition of label <%s>" (Error, ANSI-violation)
661
662 The label was defined more than once in the same function.
663 Consider that labels can not be hidden in inner blocks.
664
665
666@item "case without switch" (Error, ANSI-violation)
667
668 A case label was found outside of any switch-statements.
669
670
671@item "case-expression must be constant" (Error, ANSI-violation)
672
673 The expression after 'case' must be constant.
674
675
676@item "case-expression must be integer" (Error, ANSI-violation)
677
678 The expression after 'case' must be integer.
679
680
681@item "empty if-expression" (Error, ANSI-violation)
682
683 There was no valid expression after 'if'.
684
685
686@item "if-expression must be arithmetic or pointer" (Error, ANSI-violation)
687
688 The expression after 'if' must be arithmetic (i.e. an integer
689 or floating point type) or a pointer.
690
691
692@item "empty switch-expression" (Error, ANSI-violation)
693
694 There was no valid expression after 'switch'.
695
696
697@item "switch-expression must be integer" (Error, ANSI-violation)
698
699 The expression after 'switch' must be an integer.
700
701
702@item "multiple default labels" (Error, ANSI-violation)
703
704 There was more than one default label in a switch-statement.
705
706
707@item "while-expression must be arithmetic or pointer" (Error, ANSI-violation)
708
709 The expression after the 'while' must be arithmetic (i.e. an integer
710 or floating point type) or a pointer.
711
712
713@item "empty while-expression" (Error, ANSI-violation)
714
715 There was no valid expression after 'while'.
716
717
718@item "for-expression must be arithmetic or pointer" (Error, ANSI-violation)
719
720 The expression inside the 'for' must be arithmetic (i.e. an integer
721 or floating point type) or a pointer.
722
723
724@item "do-while--expression must be arithmetic or pointer" (Error, ANSI-violation)
725
726 The expression after the 'while' must be arithmetic (i.e. an integer
727 or floating point type) or a pointer.
728
729
730@item "goto without label" (Error, ANSI-violation)
731
732 'goto' must be followed by a label.
733
734
735@item "continue not within loop" (Error, ANSI-violation)
736
737 'continue' is only allowed inside of loops.
738 Perhaps there are unbalanced '@{' '@}'.
739
740
741@item "break not in matching construct" (Error, ANSI-violation)
742
743 'break' is only allowed inside of loops or switch-statements.
744 Perhaps there are unbalanced '@{' '@}'.
745
746
747@item "label <%s> was never defined" (Error, ANSI-violation)
748
749 There is a goto to a label that was never defined.
750
751
752@item "label <%s> was never used" (Warning)
753
754 You defined a label, but there is no goto that jumps to it.
755
756
757@item "register %s not ok" (Warning)
758
759 There was an internal error (i.e. a bug in the compiler)!
760 Please report the error to vb@@compilers.de. Thanks!
761
762
763@item "default not in switch" (Warning, ANSI-violation)
764
765 A default label that is not in any switch-statement was found.
766 Perhaps there are unbalanced '@{' '@}'.
767
768
769@item "( expected" (Warning, ANSI-violation)
770
771
772
773@item "loop eliminated" (Warning)
774
775 There was a loop that will never be executed (e.g. while(0)...)
776 and therefore the entire loop was eliminated.
777 I do not know any reason for such loops, so there is probably an
778 error.
779
780
781@item "statement has no effect" (Warning)
782
783 There is a statement that does not cause any side-effects (e.g.
784 assignments, function calls etc.) and is therefore superfluous.
785 E.g. you might have typed a==b; instead of a=b;
786
787
788@item "'while' expected" (Warning, ANSI-violation)
789
790 The 'while' in a do-while loop is missing.
791
792
793@item "function should not return a value" (Warning)
794
795 You specified an argument to return although the function is
796 void. Declare the function as non-void.
797
798
799@item "function should return a value" (Warning)
800
801 You did not specify an argument to return although the function
802 is not void. Declare the function as void or specify a return
803 value.
804
805
806@item "@{ expected" (Warning, ANSI-violation)
807
808
809
810@item "internal error %d in line %d of file %s !!" (Fatal, Error)
811
812 There was an internal error (i.e. a bug in the compiler)!
813 Please report the error to vb@@compilers.de. Thanks!
814
815
816@item "there is no message number %d" (Fatal)
817
818 You tried to activate or suppress a message that does not exist.
819
820
821@item "message number %d cannot be suppressed" (Fatal)
822
823 You cannot suppress a message that displays a real error,
824 ANSI-violation or another real problem.
825 Only 'harmless' warnings can be suppressed.
826
827
828@item "implicit declaration of function <%s>" (Warning)
829
830 A function was called before it was declared and therefore
831 implicitly declared as
832
833 int function();
834
835 This should be avoided in new programs.
836
837
838@item "function call without prototype in scope" (Warning)
839
840 When writing new programs it is probably sensible to use prototypes
841 for every function. If a function is called without a prototype in
842 scope this may cause incorrect type conversions and is usually an
843 error.
844
845
846@item "#pragma used" (Warning)
847
848 Usage of #pragma should be avoided in portable programs.
849
850
851@item "assignment in comparison context" (Warning)
852
853 The expression in an if-, for-, while- or do-while-statement
854 is an assignment, e.g.
855
856 if(i=0)...
857
858 This could an error, if you wanted if(i==0).
859 If you turned on this warning and want it to shut up for a
860 certain expression you can cast it to its type, e.g.
861
862 if((int)(i=0))...
863
864 Note that only assignments with '=' will be warned, not '+=' etc.
865
866
867@item "comparison redundant because operand is unsigned" (Warning)
868
869 A comparison with an unsigned variable is redundant, because
870 the result will always be constant, e.g.
871
872 unsigned int i;
873 if(i<0)...
874
875 This usually is a programming error and can be avoided in all cases.
876
877
878@item "cast to narrow type may cause loss of precision" (Warning)
879
880 A variable is cast to a type smaller than its original type, so
881 that some information may get lost.
882 However this warning will be displayed in lots of cases where
883 no problem can arise, e.g. (short)(a==b).
884
885
886@item "pointer cast may cause alignment problems" (Warning)
887
888 A pointer is cast to a pointer to a type with stricter alignment
889 requirements, i.e. the new pointer might be invalid if you do not
890 know what you are doing.
891 Those casts should be avoidable in all 'usual' cases.
892
893
894@item "no declaration of global variable <%s> before definition" (Warning)
895
896 It is usually good to declare all global variables (including
897 functions) in header files.
898
899
900@item "'extern' inside function" (Warning)
901
902 Declaration of external variables in inner blocks is usually
903 not a good idea.
904
905
906@item "dead assignment to <%s> eliminated" (Warning)
907
908 A variable is assigned a value that is never used or gets
909 overwritten before it is used. If this occurs in real code then
910 there is either an error or an unnecessary assignment.
911
912 This is detected only in optimizing compilation.
913
914
915@item "var <%s> is used before defined" (Warning)
916
917 The variable is used before it was assigned a value and therefore
918 is undefined. It cannot be detected if the code where it is used
919 can be reached, but if it is reached it will cause undefined
920 behaviour. So it is most probably an error either way (see 170).
921
922 However not all uninitialized usages can be found.
923
924 Also note that the compiler may choose convenient values for
925 uninitialized variables. Example:
926
927 int f(int a)
928 @{
929 int x;
930 if(a) x=0;
931 return(x);
932 @}
933
934 Here the optimizer may choose that x==0 if it is uninitialized and
935 then only generate a return(0);
936 It can also happen that you get different values if you read an
937 uninitialized variable twice although it was not assigned a value
938 in between.
939
940 This is only detected in optimizing compilation.
941
942
943@item "would need more than %ld optimizer passes for best results" (Warning)
944
945 The optimizer would probably be able to do some further
946 optimizations if you increased the number of allowed passes
947 with the -optpasses=n option.
948
949
950@item "function <%s> has no return statement" (Warning)
951
952 A non-void function has no return statement. Either this function
953 never returns (then better declare it as void) or it reaches
954 end of control which would be an error.
955
956 As main() cannot be declared as void you will not be warned if
957 main has no return statement. If you want a warning for main, too,
958 you can turn on warning 174.
959
960
961@item "function <main> has no return statement" (Warning)
962
963 The same like 173 for main, so you can turn it on/off separately.
964
965
966@item "this code is weird" (Warning)
967
968 The code has a very strange control flow. There is probably a
969 jump inside a loop or something similar and the optimizer will
970 not make any loop optimization and perhaps worse register
971 allocation on this construct.
972 There must be goto statements in the source.
973
974 This warning is only detected in optimizing compilation.
975
976
977@item "size of incomplete type not available" (Warning, ANSI-violation)
978
979 An incomplete type must not be the argument for sizeof.
980
981
982@item "line too long" (FATAL, Error, ANSI-violation, Preprocessor)
983
984
985
986@item "identifier must begin with a letter or underscore" (FATAL, Error, ANSI-violation, Preprocessor)
987
988
989
990@item "cannot redefine macro" (Error, ANSI-violation, Preprocessor)
991
992
993
994@item "missing ) after argumentlist" (Error, ANSI-violation, Preprocessor)
995
996
997
998@item "identifier expected" (Error, ANSI-violation, Preprocessor)
999
1000
1001
1002@item "illegal character in identifier" (Error, ANSI-violation, Preprocessor)
1003
1004
1005
1006@item "missing operand before/after ##" (Error, ANSI-violation, Preprocessor)
1007
1008
1009
1010@item "no macro-argument after #-operator" (Error, ANSI-violation, Preprocessor)
1011
1012
1013
1014@item "macro redefinition not allowed" (Error, ANSI-violation, Preprocessor)
1015
1016
1017
1018@item "unexpected end of file (unterminated comment)" (FATAL, Error, Preprocessor)
1019
1020
1021
1022@item "too many nested includes" (FATAL, Error, Preprocessor)
1023
1024
1025
1026@item "#else without #if/#ifdef/#ifndef" (FATAL, Error, ANSI-violation, Preprocessor)
1027
1028
1029
1030@item "#else after #else" (Error, ANSI-violation, Preprocessor)
1031
1032
1033
1034@item "#endif without #if" (Error, ANSI-violation, Preprocessor)
1035
1036
1037
1038@item "cannot include file" (FATAL, Error, Preprocessor)
1039
1040
1041
1042@item "expected \" or < in #include-directive" (Error, ANSI-violation, Preprocessor)
1043
1044
1045
1046@item "unknown #-directive" (Warning, Preprocessor)
1047
1048
1049
1050@item "wrong number of macro arguments" (Error, ANSI-violation, Preprocessor)
1051
1052
1053
1054@item "macro argument expected" (Error, ANSI-violation, Preprocessor)
1055
1056
1057
1058@item "out of memory" (FATAL, Error, Preprocessor)
1059
1060
1061
1062@item "macro redefinition" (Warning, Preprocessor)
1063
1064
1065
1066@item "/* in comment" (Warning, Preprocessor)
1067
1068
1069
1070@item "cannot undefine macro" (Error, ANSI-violation, Preprocessor)
1071
1072
1073
1074@item "characters after #-directive ignored" (Warning, Preprocessor)
1075
1076
1077
1078@item "duplicate case labels" (Warning, ANSI-violation)
1079
1080 Each case-label in a switch-statement must have a distinct constant
1081 value attached (after converting it to the type of the
1082 switch-expression).
1083
1084
1085@item "var <%s> is incomplete" (Warning, ANSI-violation)
1086
1087 An incomplete var was defined. probably you wrote something like:
1088
1089 int a[];
1090
1091
1092@item "long float is no longer valid" (Warning, ANSI-violation)
1093
1094 'long float' was a synonym for double in K&R C, but this is no longer
1095 allowed in ANSI C.
1096
1097
1098@item "long double is not really supported by vbcc" (Warning)
1099
1100 vbcc does not know about long double yet and therefore will use it
1101 simply as a synonym for double. This should not break any legal code,
1102 but you will not get error messages if you e.g. assign a pointer to
1103 double to a pointer to long double.
1104
1105
1106@item "empty struct-declarations are not yet handled correct" (Warning)
1107
1108 obsolete
1109
1110
1111@item "identifier too long (only %d characters are significant)" (Warning)
1112
1113
1114
1115@item "illegal initialization of var <%s>" (Warning, ANSI-violation)
1116
1117 Perhaps you tried to initialize a variable with external linkage
1118 in an inner block.
1119
1120
1121@item "suspicious loop" (Warning)
1122
1123 vbcc thinks a loop-condition looks suspicious. A possible example
1124 could be for(i=0;i!=7;i+=2)
1125
1126
1127@item "ansi/iso-mode turned on" (Warning)
1128
1129 You turned on the ANSI/ISO-conforming mode. This warning is always
1130 displayed unless it is suppressed. So vbcc cannot be blamed to miss
1131 a diagnostic for any constraint violation. :-)
1132
1133
1134@item "division by zero (result set to 0)" (Warning, ANSI-violation)
1135
1136 Similar to warning 84.
1137
1138
1139@item "constant out of range" (Warning, ANSI-violation)
1140
1141 An integral constant is too large to fit into an unsigned long.
1142
1143
1144@item "constant is unsigned due to size" (Warning)
1145
1146 If an integral constant is so large that it cannot be represented
1147 as long its type is promoted to unsigned long.
1148
1149
1150@item "varargs function called without prototype in scope" (Warning)
1151
1152 A function which takes a variable number of arguments must not be
1153 called without a prototype in scope. E.g. calling printf() without
1154 #include <stdio.h> may cause this warning.
1155
1156
1157@item "suspicious format string" (Warning)
1158
1159 The format-string of a printf-/scanflike function seems to be corrupt
1160 or not matching the type of the arguments.
1161
1162
1163@item "format string contains \'\\0\'" (Warning)
1164
1165 The format string for a printf-/scanflike function contains an
1166 embedded '\0' character.
1167
1168
1169@item "illegal use of keyword <%s>" (Warning, ANSI-violation)
1170
1171 The reserved keywords of C may not be used as identifier.
1172
1173
1174@item "register <%s> used with wrong type" (Error)
1175
1176
1177@item "register <%s> is not free" (Error)
1178
1179
1180@item "'__reg' used in old-style function definition" (Warning)
1181
1182
1183@item "unknown register \"%s\"" (Warning)
1184
1185
1186@item "'...' only allowed with prototypes" (Warning, ANSI-violation)
1187
1188
1189@item "Hey, do you really know the priority of '&&' vs. '||'?" (Warning)
1190
1191
1192@item "be careful with priorities of <</>> vs. +/-" (Warning)
1193
1194
1195@item "address of auto variable returned" (Warning)
1196
1197
1198@item "void function returns a void expression" (Warning)
1199
1200
1201@item "redeclaration of typedef <%s>" (Warning, ANSI-violation)
1202
1203
1204@item "multiple specification of attribute \"%s\"" (Warning)
1205
1206
1207@item "redeclaration of var \"%s\" with differing setting of attribute \"%s\"" (Warning)
1208
1209@item "string-constant expected" (Error)
1210
1211@item "tag \"%s\" used for wrong type" (Warning, ANSI-violation)
1212
1213@item "member after flexible array member" (Error, ANSI-violation)
1214
1215@item "illegal number" (Error, ANSI-violation)
1216
1217@item "void character constant" (Preprocessor, Error, ANSI-violation)
1218
1219@item "spurious tail in octal character constant" (Preprocessor, Error, ANSI-violation)
1220
1221@item "spurious tail in hexadecimal character constant" (Preprocessor, Error, ANSI-violation)
1222
1223@item "illegal escape sequence in character constant" (Preprocessor, Error, ANSI-violation)
1224
1225@item "invalid constant integer value" (Preprocessor, Error, ANSI-violation)
1226
1227@item "a right parenthesis was expected" (Preprocessor, Error, ANSI-violation)
1228
1229@item "a colon was expected" (Preprocessor, Error, ANSI-violation)
1230
1231@item "truncated constant integral expression" (Preprocessor, Error, ANSI-violation)
1232
1233@item "rogue operator '%s' in constant integral expression" (Preprocessor, Error, ANSI-violation)
1234
1235@item "invalid token in constant integral expression" (Preprocessor, Error, ANSI-violation)
1236
1237@item "trailing garbage in constant integral expression" (Preprocessor, Error, ANSI-violation)
1238
1239@item "void condition for a #if/#elif" (Preprocessor, Error, ANSI-violation)
1240
1241@item "void condition (after expansion) for a #if/#elif" (Preprocessor, Error, ANSI-violation)
1242
1243@item "invalid '#include'" (Preprocessor, Error, ANSI-violation)
1244
1245@item "macro expansion did not produce a valid filename for #include" (Preprocessor, Error, ANSI-violation)
1246
1247@item "file '%s' not found" (Preprocessor, Error, ANSI-violation)
1248
1249@item "not a valid number for #line" (Preprocessor, Error, ANSI-violation)
1250
1251@item "not a valid filename for #line" (Preprocessor, Error, ANSI-violation)
1252
1253@item "rogue '#'" (Preprocessor, Error, ANSI-violation)
1254
1255@item "rogue #else" (Preprocessor, Error, ANSI-violation)
1256
1257@item "rogue #elif" (Preprocessor, Error, ANSI-violation)
1258
1259@item "unmatched #endif" (Preprocessor, Error, ANSI-violation)
1260
1261@item "unknown cpp directive '#%s'" (Preprocessor, Error, ANSI-violation)
1262
1263@item "unterminated #if construction" (Preprocessor, Error, ANSI-violation)
1264
1265@item "could not flush output (disk full ?)" (Preprocessor, Error, ANSI-violation)
1266
1267@item "truncated token" (Preprocessor, Error, ANSI-violation)
1268
1269@item "illegal character '%c'" (Preprocessor, Error, ANSI-violation)
1270
1271@item "unfinished string at end of line" (Preprocessor, Error, ANSI-violation)
1272
1273@item "missing macro name" (Preprocessor, Error, ANSI-violation)
1274
1275@item "trying to redefine the special macro %s" (Preprocessor, Error, ANSI-violation)
1276
1277@item "truncated macro definition" (Preprocessor, Error, ANSI-violation)
1278
1279@item "'...' must end the macro argument list" (Preprocessor, Error, ANSI-violation)
1280
1281@item "void macro argument" (Preprocessor, Error, ANSI-violation)
1282
1283@item "missing comma in macro argument list" (Preprocessor, Error, ANSI-violation)
1284
1285@item "invalid macro argument" (Preprocessor, Error, ANSI-violation)
1286
1287@item "duplicate macro argument" (Preprocessor, Error, ANSI-violation)
1288
1289@item "'__VA_ARGS__' is forbidden in macros with a fixed number of arguments" (Preprocessor, Error, ANSI-violation)
1290
1291@item "operator '##' may neither begin nor end a macro" (Preprocessor, Error, ANSI-violation)
1292
1293@item "operator '#' not followed by a macro argument" (Preprocessor, Error, ANSI-violation)
1294
1295@item "macro '%s' redefined unidentically" (Preprocessor, Error, ANSI-violation)
1296
1297@item "not enough arguments to macro" (Preprocessor, Error, ANSI-violation)
1298
1299@item "unfinished macro call" (Preprocessor, Error, ANSI-violation)
1300
1301@item "too many argument to macro" (Preprocessor, Error, ANSI-violation)
1302
1303@item "operator '##' produced the invalid token '%s%s'" (Preprocessor, Error, ANSI-violation)
1304
1305@item "quad sharp" (Preprocessor, Error, ANSI-violation)
1306
1307@item "void macro name" (Preprocessor, Error, ANSI-violation)
1308
1309@item "macro %s already defined" (Preprocessor, Error, ANSI-violation)
1310
1311@item "trying to undef special macro %s" (Preprocessor, Error, ANSI-violation)
1312
1313@item "illegal macro name for #ifdef" (Preprocessor, Error, ANSI-violation)
1314
1315@item "unfinished #ifdef" (Preprocessor, Error, ANSI-violation)
1316
1317@item "illegal macro name for #undef" (Preprocessor, Error, ANSI-violation)
1318
1319@item "unfinished #undef" (Preprocessor, Error, ANSI-violation)
1320
1321@item "illegal macro name for #ifndef" (Preprocessor, Error, ANSI-violation)
1322
1323@item "unfinished #ifndef" (Preprocessor, Error, ANSI-violation)
1324
1325@item "reconstruction of <foo> in #include" (Preprocessor, Warning)
1326
1327@item "comment in the middle of a cpp directive" (Preprocessor, Warning)
1328
1329@item "null cpp directive" (Preprocessor, Warning)
1330
1331@item "rogue '#' in code compiled out" (Preprocessor, Warning)
1332
1333@item "rogue '#' dumped" (Preprocessor, Warning)
1334
1335@item "#error%s" (Preprocessor, ANSI-violation, Error)
1336
1337@item "trigraph ?""?%c encountered" (Preprocessor, Warning)
1338
1339@item "unterminated #if construction (depth %ld)" (Preprocessor, Error, ANSI-violation)
1340
1341@item "malformed identifier with UCN: '%s'" (Preprocessor, Warning, ANSI-violation)
1342
1343@item "truncated UTF-8 character" (Preprocessor, Warning, ANSI-violation)
1344
1345@item "identifier not followed by whitespace in #define" (Preprocessor, Warning, ANSI-violation)
1346
1347@item "assignment discards restrict" (Warning, ANSI-violation)
1348
1349@item "storage-class in declaration within for() converted to auto" (Warning, ANSI-violation)
1350
1351@item "corrupted special object" (ANSI-violation, Fatal)
1352
1353@item "<inline> only allowed in function declarations" (Error, ANSI-violation)
1354
1355@item "reference to static variable <%s> in inline function with external linkage" (Error, ANSI-violation)
1356
1357@item "underflow of pragma popwarn" (Error, ANSI-violation)
1358
1359@item "invalid argument to _Pragma" (Preprocessor, Error, ANSI-violation)
1360
1361@item "missing comma before '...'" (Preprocessor, Error, ANSI-violation)
1362
1363@item "padding bytes behind member <%s>" (Warning)
1364
1365@item "member <%s> does not have natural alignment" (Warning)
1366
1367@item "function <%s> exceeds %s limit" (Warning)
1368
1369@item "%s could not be calculated for function <%s>" (Warning)
1370
1371@item "offsetof applied to non-struct" (Error, ANSI-violation)
1372
1373@item "trailing garbage in #ifdef" (Preprocessor, Warning, ANSI-violation)
1374
1375@item "too many arguments to macro" (Preprocessor, Warning, ANSI-violation)
1376
1377@item "truncated comment" (Preprocessor, Warning|ANSI-violation)
1378
1379@item "trailing garbage in preprocessing directive" (Preprocessor, Warning, ANSI-violation)
1380
1381@item "variable-length array must have auto storage-class" (Error, ANSI-violation)
1382
1383@item "member <%s> has type with zero alignment/size (probably void)" (Error, ANSI-violation, Fatal)
1384
1385@item "stack information for target <%s> unavailable" (Warning)
1386
1387@item "used registers information unavailable for target <%s>" (Warning)
1388
1389@item "computed %sstack usage %d but set to %d" (Warning)
1390
1391@item "unable to compute call targets" (Warning)
1392
1393@item "computed register usage differs from specified one" (Warning)
1394
1395@item "trailing garbage in #include" (Preprocessor, Warning ,ANSI-violation)
1396
1397@item "target-warning: %s" (Warning)
1398
1399@item "target-error: %s" (Error)