#: 11471 S3/Languages
24-Jul-91 03:34:58
Sb: #11468-#C Compiler Problem
Fm: James Jones 76257,562
To: Pete Lyall 76703,4230 (X)
You may be right, but a quoted string can appear as an initializer for an array
of characters, as long as the array either has its size unspecified, in which
case it can inherit it from the string (don't forget the \0 at the end), or its
size is the length of the string (ditto about the \0, save that in ANSI C, you
*can* forget about the \0 if you want to). I just tried an initializer for a
structure of the sort under discussion here, and it looks like you are right,
and I think it is a bug in the compiler.
There is 1 Reply.
|