[Doc][OpenCL] Fixed typos in code examples
authorAnastasia Stulova <anastasia.stulova@arm.com>
Thu, 22 Sep 2022 16:46:47 +0000 (17:46 +0100)
committerAnastasia Stulova <anastasia.stulova@arm.com>
Thu, 22 Sep 2022 16:46:47 +0000 (17:46 +0100)
clang/docs/LanguageExtensions.rst

index 17b2f8a..bbaf31c 100644 (file)
@@ -2136,7 +2136,7 @@ between the host and device is known to be compatible.
   struct OnlySL {
     int a;
     int b;
-    NotPod() : a(0), b(0) {}
+    OnlySL() : a(0), b(0) {}
   };
 
   // Not standard layout type because of two different access controls.
@@ -2144,16 +2144,17 @@ between the host and device is known to be compatible.
     int a;
   private:
     int b;
-  }
+  };
 
+  #pragma OPENCL EXTENSION __cl_clang_non_portable_kernel_param_types : enable
   kernel void kernel_main(
     Pod a,
-  #pragma OPENCL EXTENSION __cl_clang_non_portable_kernel_param_types : enable
+
     OnlySL b,
     global NotSL *c,
-  #pragma OPENCL EXTENSION __cl_clang_non_portable_kernel_param_types : disable
-    global OnlySL *d,
+    global OnlySL *d
   );
+  #pragma OPENCL EXTENSION __cl_clang_non_portable_kernel_param_types : disable
 
 Remove address space builtin function
 -------------------------------------