Garbage Collector : Ignoring a reference

Alex Parrill via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Tue Apr 26 05:42:46 PDT 2016


On Tuesday, 26 April 2016 at 09:07:59 UTC, Begah wrote:
> I am trying to create an asset manager for my textures. I had 
> the idea ( it may be a wrong idea ) to create a hashmap of my 
> textures with a string as the key. When the program request a 
> texture, it firts check if it is in the hashmap and then 
> returns if it is :
>
> [...]

What you want are "weak references". I don't think D supports 
them yet.


More information about the Digitalmars-d-learn mailing list