try to find a solution that works on all compilers