3 ms·Also defer runs even if your code panic which is great.by Thaxll 6y agoAlso defer runs even if your code panic which is great.jcelerier 6y ago... which is exactly how C++ RAII behaves when there is an exception ?gusttedt 6y agoIIRC in C++ this is only so if there is a try/catch underneath.