How do I create classes dynamically?

Mario cbarch at protonmail.com
Wed Apr 14 20:57:45 UTC 2021


On Wednesday, 14 April 2021 at 20:47:57 UTC, Steven Schveighoffer 
wrote:
> There is no good supported way to do this with the current 
> runtime.
>
> The way this is normally done is to use your own reflection 
> system, and build a mechanism to create classes based on their 
> name.
>
> There was an old way, using Object.factory, but I would not 
> recommend that, it's brittle and doesn't always work.
>
> -Steve

Too bad. Nevertheless, thank you for your quick answer to my 
question.

-Mario


More information about the Digitalmars-d-learn mailing list