I used: apt-get purge apt-get purge g++ g++-10
then installed again build-enential and installed again build-essential. Problem is gone. Compilation works without any issues. What is strange is that I didn't mess in any configuration files for gcc or clang. I don't know the reason why it failed and why it works again.