How can we make it easier to experiment with the compiler?

Iain Buclaw ibuclaw at gdcproject.org
Mon May 24 20:00:42 UTC 2021


On Monday, 24 May 2021 at 19:42:00 UTC, user1234 wrote:
> On Monday, 24 May 2021 at 12:38:59 UTC, zjh wrote:
>> [...]
>
> 100 kb is let's say 2500 slocs (or rather 1500 from the 
> D-Scanner pov), that's not too crazy. Many DMD source files are 
> big because they contain a visitor.
> visitors cant be split in several files. Often you only 
> actually are interested by a single method of a visitor so the 
> overhall size of a source does not matter.
>
> Eventually what could be done for the biggest methods of 
> visitors is to extract parts of the content to several 
> **non-nested** free functions, so that no more low level 
> implementation details, like control loops, are visible and 
> instead you just see do_this; do_that; with just a few, 
> nzzcessarily unavoidable, flow statements.
>

Actually, the visitors have been slowly getting converted into 
nested functions and a switch table.


More information about the Digitalmars-d mailing list