Steven Schveighoffer Wrote: > > Yes, they have to be. There are reasons besides overloading for including > other attributes in the naming. > > For example, if a function is pure, then becomes unpure, you don't > existing code that is expecting a pure function to link against it. > > In other words, the linker is dumb. It only knows how to match symbols, > so you have to embed into the symbols the important pieces of the > interface that you want the linker to consider important. > > To answer Don's point, there is nothing saying that the compiler can't > read attributes and change its behavior. Of course, those would have to > be builtin attributes. > > My opinion on removing existing keywords is -- don't. There's little to > no gain. Let that ship sail, and concentrate on future keyword proposals. > > -Steve
If we are willing to have our own specialized linker format than the compiler can output data structures that contain a symbol with an assosiated map of attributes (meta-data). This will remove the need to have mangled symbols. For example, the compiler can provide to the linker the dependency graph as attributes.
