It seems there were both my mistake and problem in `_getDeclName` func, added more conditions, now works ok.