Path: utzoo!yunexus!geac!syntron!jtsv16!uunet!seismo!sundc!pitstop!sun!decwrl!labrea!rutgers!cmcl2!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn ) Newsgroups: comp.std.c Subject: Re: Typedef names vs. new types. Message-ID: <8755@smoke.BRL.MIL> Date: 26 Oct 88 09:35:48 GMT Article-I.D.: smoke.8755 References: <3355@pt.cs.cmu.edu> <10006@haddock.ima.isc.com> Reply-To: gwyn@brl.arpa (Doug Gwyn (VLD/VMB) ) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 14 In article <10006@haddock.ima.isc.com> karl@haddock.ima.isc.com (Karl Heuer) writes: >Let's enhance the syntax of declarations to include a dimension-specifier... Unfortunately this is too simplistic. For example, there are several ways to combine the Cartesian-projected elements of a tensor to produce a quantity having different dimension, but the resulting dimension is not ascertainable from a syntactic analysis of the combination. Also, units that people usually consider different turn out to be the same when one has a sufficiently powerful physical theory. Thus it is better to provide definitional facilities along the lines of classes, whereby one can specify the allowed operations and the properties of the results. In general structured types are necessary to encode all the possibly relevant dimensional attributes of a quantity.