There is a default bug : E0018 expected a')'

“Atomic.h”
struct alignas(UE4Atomic_Private::TIsSupportedSize<sizeof(T)>::Value ? alignof(UE4Atomic_Private::TUnderlyingIntegerType_T<T>) : alignof(T)) TAtomicBase_Basic
I use UE4.21 and visual studio 2017,there is an error E0018 expected a’)’ pointed to this line.I can fixed it by add a pair of ‘()’.But I wonder if there is something wrong with my Installation of UE or visual studio.Does everyone has this bug?And does everybody fixed it manually like me?

和你一样

Yup, I also have this bug :frowning:
I am just starting out with UE4 aand C++ so when the base code doesn’t work I have no clue what to do :frowning:
Thankfully there are two solutions offered here: https://answers.unrealengine.com/questions/822711/atomich-error-in-all-new-projects.html

I’ll save you the read: Visual Studio no longer automatically casts enums to ints so all you have to do is prefix “UE4Atomic_Private” with a cast like so “(int)” and now Value becomes an int and everybody’s happy :slight_smile: