J
jankeir
Guest
Marian, generics would allow this: define variable interestingService as ISomeInterestingServiceType no-undo. assign interestingService = Ccs.Common.Application:ServiceManager:getService<>(); Compare that to the current cast stuff and tell me what you like best ;-) There are other use cases where the advantage is bigger (type safety in collection classes comes to mind) as this specific problem can mostly be overcome with a small include but still, it would be a lot cleaner if the syntax were build into the language rather than bolted on. ps.: Logic in includes: Yuck.
Continue reading...
Continue reading...