[Lazarus] FPDoc Editor fails on namespace dotted unit names?
Anthony Walter
sysrpl at gmail.com
Thu Apr 18 02:56:12 CEST 2013
On Wed, Apr 17, 2013 at 3:10 PM, Marco van de Voort <marcov at stack.nl> wrote:
> True. But the C# namespace concept is totally different from the Pascal
> one, as I wrote in the previous message.
>
> Pascal would have to make an inventory of all files in the searchpath, not
> just in a certain (classpath or GAC) location.
>
There are only 2 differences between what we currently have with dotted
unit names acting as namespaces and C# namespaces.
1) You can't have more than one namespace in a file
2) You can't span a namespace across multiple files
Regarding the code insight you asked me about, those two differences aren't
relevant to the programmer user experience. You could very well do the same
thing in C# (use one namespace per file), and the code insight (just that
aspect) user experience in Visual Studio would be the same. That is, you
still type "MyCompany." and see a list of sub namespaces or classes or
whatever (depending on what precedes "MyCompany.").
No, you don't need a GAC to achieve this. All you need is a list of unit
paths, and the IDE can scan those folders for unit names. Something Lazarus
already does.
And just to be clear, Visual Studio doesn't use the GAC to search for
namespaces,. You have to add a reference to an assembly (somewhat analogous
to adding a package requirement in Lazarus). Once a project references an
assembly (which can be in another folder, copied to the project bin folder,
or it can load the assembly from the GAC), namespaces and types are
determined. That is, potential namespaces are determined by your project
references (again, analogous to adding a package requirement), and not by
scanning the files in the GAC.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20130417/cc3e2320/attachment-0003.html>
More information about the Lazarus
mailing list