Path: utzoo!utgpu!attcan!uunet!auspex!guy From: guy@auspex.UUCP (Guy Harris) Newsgroups: comp.lang.c Subject: Re: hardcoded constants Message-ID: <789@auspex.UUCP> Date: 23 Dec 88 08:53:46 GMT References: <1988Dec8.173158.11839@utzoo.uucp> <846@starfish.Convergent.COM> <1988Dec21.133910.23182@ateng.ateng.com> <77@attibr.UUCP> Reply-To: guy@auspex.UUCP (Guy Harris) Organization: Auspex Systems, Santa Clara Lines: 8 >Last I heard sizeof("/") == sizeof(char *) I don't know who you heard that from, but I suggest you take anything else they have to say about C with a grain of salt; it is not true. "/" is an array of "char" with two elements, not a pointer to "char". In some contexts, that "array of 'char'" expression gets converted to a "pointer to 'char'" that points to the array's first member; however, "argument of the 'sizeof' operator" is not one of those contexts.