TLIMONCE%DREW.BITNET@CUNYVM.CUNY.EDU (12/24/87)
After reading all the recent posts about noalias I have come to the following conclusions: - Leave it out. It's not worth all this debating. - Leave it out of the standard. If someone wants to write an optimizer that would require it they will add it and it will create some prior art for the next revision. (actually, I like that person's idea about computing where it is needed and think that it can be done) ----- Why would someone want to include a \000 in the middle of a string? I've seen a pull-down menu routine (was it in DDJ?) that had something like: foo(3,"MenuItem1\000MenuItem2\000MenuItem3"); (or maybe that was in a structure?) This allowed the progammer to specify the text for each item in the menu easily. This has advantages over variable # of parameters (a bit easier to code). I prefer: foo("Thing1\000Thing2\000Thing3\000\000"); It's more like an empty-string terminated list of strings (a "null terminated null terminated string" perhaps?) ----- Someone made a comment about a typo of mine. Please, I do most of my net-ing late at night and proofing is difficult at 2AM. I suggest something better than const, register and noalias: "violet:" -- "I was blue when I wrote this code." (sorry) ____________________________________________________________________ ! Real World: Tom Limoncelli Computer World: ! ! Drew University BITNET: tlimonce@drew ! ! Box 1060 /--------------------------------------! ! Madison, NJ 07940 / Disclaimer: These are exclusively my ! !=======================\< opinions. That's the only thing ! ! Season's Greatings \\ my boss and I can agree about. ! !========================/ \---------------------------------------!
rbutterworth@watmath.waterloo.edu (Ray Butterworth) (12/24/87)
In article <10989@brl-adm.ARPA>, TLIMONCE%DREW.BITNET@CUNYVM.CUNY.EDU writes: > After reading all the recent posts about noalias I have come to the following > conclusions: > - Leave it out. It's not worth all this debating. > - ... A small number of compiler writers seem to think that it is necessary to have noalias as a part of the language (e.g. those that share a common code generator with fortran or want to use vector hardware). On most compilers, noalias would probably have no effect, and it is fairly simple to add to the grammar. But why bother making things more complicated than they need to be? There isn't really any reason to make noalias part of the language. Those compiler writers that think they need it are already allowed to do something like adding a "_noalias" symbol to their compiler. They simply have to put a warning into their manuals indicating that any code written for this compiler should have something like #if !defined(_XYZ_COMPILER) # define _noalias /*nothing*/ #endif at the top if it is to be ported to any other vendor's compiler. This is only one suggestion. There are many variations on this. The important point is that it can be done by those that need it without requiring any additions to the language by the ANSI standard while still allowing code that takes advantage of their compiler's optimizations to be portable to other ANSI compilers.