Path: utzoo!censor!geac!jtsv16!uunet!lll-winken!brutus.cs.uiuc.edu!usc!cs.utexas.edu!asuvax!ncar!tank!msuinfo!frith!magnani From: magnani@frith.uucp (Steven Magnani) Newsgroups: comp.lang.c Subject: Question on ANSI-C "typedefs" Summary: Can you declare array size in typedef? Message-ID: <1990Apr5.211601.27328@msuinfo.cl.msu.edu> Date: 5 Apr 90 21:16:01 GMT Sender: news@msuinfo.cl.msu.edu Distribution: usa Organization: Michigan State University, East Lansing Lines: 30 Hello, net -- it's been awhile, but I'm back. A question. Is it legal in ANSI-C to make the following statement: typedef char FOO_TYPE[size_of_foo]; If so, what is the resulting type of the declaration FOO_TYPE thing[size_of_thing]; ...and the function FOO_TYPE *some_func(void); I am somewhat confused -- my reading of the K&R draft-'C' standard is that a typedef construction such as above is illegal. However, the book "Programming in 'C'" by Kochan gives an example of such a declaration. We are having problems with our Microsoft-'C' compiler (V5.0) gagging on statements related to these, so any help is much appreciated! adTHANKSvance, Steve -- Steven J. Magnani "I claim this network for MARS! Earthling, return my space modulator!" With a domain server: magnani@frith.egr.msu.edu