Sealed classes - would you want them in D?
rikki cattermole
rikki at cattermole.co.nz
Sat May 12 04:11:59 UTC 2018
On 12/05/2018 3:02 PM, KingJoffrey wrote:
> On Saturday, 12 May 2018 at 00:39:29 UTC, Mike Parker wrote:
>>
>> Again, they're in the same module. From an encapsulation stand point,
>> what does it matter that private members are within or without any
>> specific set of curly braces? It only matters if you want to adhere to
>> a purely conceptual view of encapsulation. From a practical view, it
>> matters not one whit.
>>
>>>
>
> It matters, in the same sense, that it matters if you have a module,
> full of functions (which are encapsulated units of code), but your
> module has a whole bunch of goto statements (not necessarily within a
> function). Now...you've essentially no idea now which functions are
> truly encapsulated, and which aren't. You now have to take into view,
> 'the whole module' - which goes against the very principle of problem
> solving by breaking down the problem into smaller pieces.
>
> I have looked a D source code modules. I challenge anyone to get there
> head around whole modules.
Its actually pretty easy.
I have yet to find a D module I couldn't understand.
Now IntelliJ IDEA on the other hand...
I gave up on my recent iteration of a plugin for D when discovering I
really did not understand how its setup enough to add something to the
configuration dialog. Let alone SDK and what not.
More information about the Digitalmars-d
mailing list