File tree Expand file tree Collapse file tree 1 file changed +10
-6
lines changed
llvm/include/llvm/Support Expand file tree Collapse file tree 1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -74,12 +74,16 @@ class SYCLPropertyValue {
7474 SYCLPropertyValue () = default ;
7575
7676 SYCLPropertyValue (Type Ty) {
77- if (Ty == UInt32)
78- Val = (uint32_t )0 ;
79- else if (Ty == ByteArray)
80- Val = std::unique_ptr<std::byte, Deleter>(new std::byte[1 ], Deleter{});
81- else
82- llvm_unreachable_internal (" unsupported SYCL property type" );
77+ switch (Ty) {
78+ case UInt32:
79+ Val = (uint32_t )0 ;
80+ break ;
81+ case ByteArray:
82+ Val = std::unique_ptr<std::byte, Deleter>(new std::byte[1 ], Deleter{});
83+ break ;
84+ default :
85+ llvm_unreachable_internal (" unsupported SYCL property type" );
86+ }
8387 }
8488 SYCLPropertyValue (uint32_t Val) : Val({Val}) {}
8589 SYCLPropertyValue (const std::byte *Data, SizeTy DataBitSize);
You can’t perform that action at this time.
0 commit comments