[nem-en] Integration issues
Igor Tkachev
it at rsdn.ru
Thu Aug 31 21:52:13 CEST 2006
Hello Kamil,
> Maybe we should create a subtype of Typer, like CompletionTyper,
> which could do the "different" stuff for various parts of
> implementation. Manager could have a "factory" method to create Typer
> / CompletionTyper depending on the actual engine being used.
> I guess completion runs only on Typer (or maybe also Typer2), so for
> the pure completion purpose this will be ok.
As far as it does not require support the same code in different
places, it's OK.
> I don't like the idea... This will make things more complicated in
> many places (keeping track of these objects and their changes), cause
> addition of quite unreadable code in many places, etc.
> I think we should rather try to set the locations of TExpr more
> correctly - this is similar problem btw, because to track the original
> PExpr you would need to write all the code which would now be enough
> to correct locations. And in case of locations we have something to
> begin with.
Sometimes TExpr totally lose the original location information. Lets
take macro, for instance.
>> How precise do you need this information to be? I could think of using
>> something similar to Location stack (or maybe turning this Location
>> stack into Located-object stack and saving a reference to a Located in
>> TExpr). I'm affraid about performance (no GC-ing PExprs) but maybe I
>> shouldn't...
> Probably we already leak them, but this might hit performance somewhat.
You can always use profiling tools to figure out what is going on.
--
Best regards,
Igor mailto:it at rsdn.ru
More information about the devel-en
mailing list