first off notice that import without it the code will still compile but reflection doesn’t work as expected – anyhow this isn’t needed I just happened to add the virtual test code to a code scrap that was floating about…
Commonly you’d have a method that is entirely abstract, this is entirely without code, but sometimes it can be useful to have some default code that can be optionally used…
Virtual allows this but it is actually more flexible than in some languages, from the D class amethod you can see that using Super I’m calling the original code – not only is that optional, but unlike some other languages Super doesn’t have to be the very first thing you do.
I hope this little scrap allows someone struggling a little extra clue…