updated for clang compilation