D Compiler as a Library

Marco Leise Marco.Leise at gmx.de
Thu Apr 19 09:38:31 PDT 2012


Am Thu, 19 Apr 2012 11:24:34 +0200
schrieb Jacob Carlborg <doob at me.com>:

> On 2012-04-19 10:48, Roman D. Boiko wrote:
> 
> > Convenience interface on top of low-level core functionality can be
> > provided and would suffice for many typical situations.
> 
> In that case I think something like this might work:
> 
> Foo.renameSymbol("file.d:16:4", "bar");
> 
> Where "file.d" is the file in which the symbol is located. ":16:4" would 
> be the row and column number. "bar" would be the new name of the symbol.

Doesn't the D module system make symbols unique? I thought with a set of open/relevant files (call it a project if you will) a symbol name can be given without ambiguities. This might go into bike shedding, but it looks like dropping one of D's strengths here. It is of course still necessary to have code to look up symbols under the cursor, no question.

-- 
Marco



More information about the Digitalmars-d mailing list