Path: utzoo!attcan!uunet!peregrine!elroy.jpl.nasa.gov!usc!wuarchive!hsdndev!cmcl2!adm!smoke!gwyn From: gwyn@smoke.brl.mil (Doug Gwyn) Newsgroups: comp.lang.c Subject: Re: SUMMARY OF confusion with char *a and char a[NUM] Message-ID: <14665@smoke.brl.mil> Date: 5 Dec 90 22:45:21 GMT References: <1990Dec4.214845.18949@ccu.umanitoba.ca> <28341@mimsy.umd.edu> <7676@umd5.umd.edu> Organization: U.S. Army Ballistic Research Laboratory, APG, MD. Lines: 14 In article <7676@umd5.umd.edu> jjk@astro.umd.edu (Jim Klavetter) writes: >I guess my followup question is more theoretical in nature: is this a >good thing? Why shouldn't > strcpy(string, a); >also send an error message ... This feature of C certainly can't be changed, as there are billions of lines of existing source code written with the assumption that C works like that. As to why Dennis made arrays second-class citizens (which is really at the root of this kludgery), I don't know. I would guess that since he didn't plan to fully support them (as assignable, etc.) anyway, but still wanted to allow the programmer to use arrays, he settled on the simplest method of dealing with them, given that pointers are fundamental to the C language.