W Twoim przykładzie `retain` mówi tylko "utrzymuj zmienną", więc nie tworzy tej zmiennej, Żeby `d` się "zmaterializowała" potrzebny jest jakiś kawałek kodu który ją utworzy. I może to być np. `d=17;` ale może być to `retain d 0`, który zostanie zinterpretowany "utrzymuj zmienną, dla której inicjacja ustala wartość 0".