Richard Kenner
6f38f669d0
(decl_attribute): Verify that alignment and format argument numbers are all integer constants.
...
(decl_attribute): Verify that alignment and format argument numbers are all
integer constants.
Continue on to next attribute if one is in error.
From-SVN: r6300
1993-12-24 07:38:37 -05:00
Richard Kenner
df8a401ad5
(T_ST): Fix typo in last change.
...
From-SVN: r6284
1993-12-23 17:19:33 -05:00
Richard Kenner
af3c5588ab
(T_ST): New macro.
...
(scan_char_table): With s, c and [, allow `a' flag.
(print_char_table): Accept Z and m codes.
(check_format_info): Handle the `a' flag.
From-SVN: r6258
1993-12-22 07:11:59 -05:00
Richard Stallman
b7c9c707a6
(shorten_compare): Correct typo from last change.
...
From-SVN: r6157
1993-11-24 23:14:43 +00:00
Richard Kenner
f577532561
(check_format_info): When we have INTEGER_TYPEs...
...
(check_format_info): When we have INTEGER_TYPEs, save result of
signed_type or unsigned_type for later comparison with the various
forms of char types.
From-SVN: r6146
1993-11-23 17:32:21 -05:00
Richard Stallman
309ffab61f
(check_format_info): Make warning nicer for mismatch of int vs long, etc.
...
Don't warn if field width is an unsigned int.
From-SVN: r5981
1993-11-03 20:09:12 +00:00
Richard Stallman
94dccd9d27
(shorten_compare): Undo previous change.
...
Instead, just suppress warnings if both args are constant.
From-SVN: r5957
1993-10-31 20:19:31 +00:00
Richard Stallman
8396a8d6fa
(shorten_compare): Do nothing if both args constant.
...
From-SVN: r5954
1993-10-31 03:13:52 +00:00
Richard Stallman
22ba338b8f
(convert_and_check): Don't warn converting 0xff
...
to a signed char, etc., unless pedantic.
From-SVN: r5944
1993-10-30 08:34:05 +00:00
Richard Kenner
60e02b1e4e
(check_format_info): Consider "char", "signed char", and "unsigned
...
char" types as equivalent.
From-SVN: r5849
1993-10-20 21:44:35 -04:00
Richard Kenner
9b69f523a7
(check_format_info): Support X/Open formats like "%1$d".
...
From-SVN: r5707
1993-10-10 08:56:49 -04:00
Richard Stallman
4215e49850
(check_format_info): Avoid ?: conditional for function to be called.
...
From-SVN: r5704
1993-10-10 05:28:35 +00:00
Richard Kenner
95216deccf
(check_function_format): Correct error in last change.
...
From-SVN: r5680
1993-10-08 10:40:59 -04:00
Richard Kenner
1ccf251f97
Include <ctype.h>; avoid home-grown ISDIGIT.
...
(decl_attributes): Call record_function_format with DECL_NAME and also
DECL_ASSEMBLER_NAME.
(struct format_char_info): Moved here from c-typeck.c.
(print_char_table): Likewise; renamed from print_table.
(scan_char_table): Likewise; renamed from scan_table.
(struct function_format_info): Likewise; add assembler_name.
(function_format_list): Make list, not array.
(init_function_format_info): Likewise; renamed from init_format_info_table.
(record_function_format): Likewise; renamed from record_format_info;
record assembler_name.
(check_format_info): Likewise; renamed from check_format.
(check_function_format): New interface that does not require knowledge of
struct function_format_info.
From-SVN: r5607
1993-10-05 15:14:50 -04:00
Richard Kenner
90b5a681ce
(c_build_type_variant): Allocate new type in same obstack as old one.
...
From-SVN: r5278
1993-09-07 19:11:15 -04:00
Richard Kenner
b839fb3fe9
(truthvalue_conversion): A complex value is nonzero if either part is
...
nonzero, not if both parts are nonzero.
From-SVN: r5259
1993-09-04 11:16:10 -04:00
Richard Stallman
4724b3dea0
(declare_hidden_char_array): New function to factor out duplicate code in declare_function_name.
...
(declare_hidden_char_array): New function to
factor out duplicate code in declare_function_name.
Don't set DECL_EXTERNAL (which is illegal without TREE_PUBLIC)
to prevent output; instead, set TREE_ASM_WRITTEN.
(declare_function_name): Use declare_hidden_char_array.
From-SVN: r5161
1993-08-15 09:30:20 +00:00
Richard Stallman
34d6bae3ee
(declare_function_name): Set DECL_EXTERNAL in the decls.
...
From-SVN: r5106
1993-08-08 08:33:48 +00:00
Richard Stallman
3550617cd5
(decl_attributes): Support attributes `volatile'
...
with alias `noreturn', and `const'.
From-SVN: r5082
1993-08-06 01:08:12 +00:00
Paul Eggert
90c939d4ee
(unsigned_conversion_warning): Just use `warning',
...
not `pedwarn'; these diagnostics are not required by Standard C.
From-SVN: r4909
1993-07-12 21:10:27 +00:00
Paul Eggert
7193bce22f
(constant_expression_warning, overflow_warning,
...
convert_and_check): Distinguish between TREE_OVERFLOW, which is just
for warnings, and TREE_CONSTANT_OVERFLOW, which is for required
pedantic diagnostics.
From-SVN: r4827
1993-07-02 01:26:01 +00:00
Richard Stallman
68a91d8d3a
(decl_attributes): If first_arg_num is 0, no error for it.
...
From-SVN: r4720
1993-06-24 03:36:08 +00:00
Richard Stallman
14aadfe88a
(constant_expression_warning)
...
(overflow_warning, convert_and_check): Change pedwarn to warning.
From-SVN: r4529
1993-05-21 19:31:40 +00:00
Richard Stallman
d7c837272e
(truthvalue_conversion): Turn off Apr 29 change.
...
From-SVN: r4356
1993-05-06 15:58:59 +00:00
Jim Wilson
f87550e01b
(truthvalue_conversion): Don't optimize subtract of reals when target uses
...
IEEE arithmetic.
From-SVN: r4311
1993-05-03 16:33:42 -07:00
Richard Stallman
257e61ed70
(truthvalue_conversion): Specific error message when the "truthvalue" of a struct...
...
(truthvalue_conversion): Specific error message when the
"truthvalue" of a struct, union, or array type operand is needed.
From-SVN: r4293
1993-05-01 04:09:06 +00:00
Jim Wilson
677ff44144
(decl_attributes...
...
(decl_attributes, format case): Error if num_arg does
not point to a string type argument, or if first_arg_num not the
anonymous argument.
From-SVN: r4032
1993-04-06 12:30:45 -07:00
Richard Stallman
1bb8e5b1b8
#include "obstack.h".
...
From-SVN: r3811
1993-03-21 18:58:22 +00:00
Richard Stallman
f0b996c50c
(truthvalue_conversion): Fix handling of COMPLEX_EXPR.
...
Handle all complex values specially.
From-SVN: r3645
1993-03-04 20:34:56 +00:00
Richard Stallman
766f6c304d
(truthvalue_conversion): Handle COMPLEX_EXPR.
...
From-SVN: r3638
1993-03-04 19:36:42 +00:00
Richard Stallman
d74154d508
(constant_expression_warning): Suppress duplicate warnings.
...
(convert_and_check, overflow_warning, unsigned_conversion_warning):
New functions. Prototypes added to c-tree.h.
From-SVN: r3405
1993-02-02 04:40:43 +00:00
Niklas Hallqvist
0b73773ce6
c-common.c (c_build_type_variant): Moved here from c-decl.c.
...
* c-common.c (c_build_type_variant): Moved here from c-decl.c.
Redirected the TYPE_MAIN_VARIANT to the "real" main variant.
Build the possibly new array type on the permanent obstack if it
the original type was permanent.
(permanent_obstack): Added extern declaration.
From-SVN: r3388
1993-01-30 06:06:09 +00:00
Richard Kenner
97d17ac21c
(declare_function_name): If char_array_type_node isn't large enough
...
for the name, make a larger type.
From-SVN: r3368
1993-01-27 19:21:01 -05:00
Richard Kenner
9379fac9a2
(truthvalue_conversion): Handle TRUTH_XOR_EXPR.
...
From-SVN: r2993
1992-12-30 06:01:57 -05:00
Richard Stallman
b9a24ad42e
(declare_function_name): __FUNC__ variables
...
are compiler-created, so set DECL_SOURCE_LINE to zero.
From-SVN: r2300
1992-10-01 19:01:26 +00:00
Richard Stallman
6152f87688
(declare_function_name): Allow for anonymous function.
...
From-SVN: r2095
1992-09-10 05:33:47 +00:00
Brendan Kehoe
9657188305
Moved constant_expression_warning into c-common.c.
...
From-SVN: r2076
1992-09-07 19:42:39 -04:00
Richard Stallman
bc690db148
(check_case_value): Call constant_expression_warning.
...
From-SVN: r2070
1992-09-07 06:07:30 +00:00
Richard Stallman
e2aab13d8a
(truthvalue_conversion): Optionally warn if an
...
unparenthesized assignment is used as a truth value.
From-SVN: r1853
1992-08-14 23:45:09 +00:00
Richard Stallman
ef57b1e9f0
(decl_attributes): Call layout_decl with two arguments.
...
From-SVN: r1711
1992-07-29 03:46:49 +00:00
Richard Stallman
1394aabdaa
Renamed TREE_INLINE...
...
Renamed TREE_INLINE, TREE_NONLOCAL, TREE_REGDECL, TREE_EXTERNAL
to DECL_INLINE, DECL_NONLOCAL, DECL_REGISTER, DECL_EXTERNAL.
From-SVN: r1569
1992-07-12 02:56:45 +00:00
Richard Stallman
8493738bcc
(check_case_value): Strip the new nops with STRIP_TYPE_NOPS.
...
From-SVN: r1549
1992-07-10 01:50:20 +00:00
Richard Kenner
18a799ccb1
Changes to support 64-bit hosts: Remove definition of NULL.
...
From-SVN: r1494
1992-07-06 22:02:07 -04:00
Richard Stallman
176e81ebf9
> (declare_function_name): For __FUNCTION__ and __PRETTY_FUNCTION__...
...
> (declare_function_name): For __FUNCTION__ and __PRETTY_FUNCTION__,
set DECL_IN_SYSTEM_HEADER instead of TREE_USED to supress `unused' warnings.
From-SVN: r1491
1992-07-07 01:46:27 +00:00
Richard Stallman
9b4e97b0d0
(decl_attributes): Don't set DECL_PACKED on VAR_DECL.
...
From-SVN: r1480
1992-07-06 20:45:11 +00:00
Richard Stallman
3fc7e39030
(type_for_size): If no ANSI type matches, check for matches with built-in mode-related types.
...
(type_for_size): If no ANSI type matches, check for
matches with built-in mode-related types.
(type_for_mode): Likewise.
From-SVN: r1397
1992-07-03 06:41:07 +00:00
Richard Stallman
4db3b35d80
fix typo in last change.
...
From-SVN: r1380
1992-07-01 21:44:28 +00:00
Richard Stallman
f3ee8ad133
(decl_attributes): For `packed' on VAR_DECL, set DECL_PACKED and DECL_ALIGN.
...
From-SVN: r1354
1992-06-30 02:25:17 +00:00
Richard Stallman
53e9d52c51
entered into RCS
...
From-SVN: r1090
1992-05-26 19:22:26 +00:00
Richard Kenner
101777b6cb
*** empty log message ***
...
From-SVN: r1059
1992-05-22 18:08:21 -04:00