RESERVEDDATATYPES(3clc)
β¨ RESERVED DATA TYPES β¨
okay bestie, welcome to the OpenCL Manual π this one is the reserved data types page, and it's short but important β these are the names you are NOT allowed to claim as your own. no cap.
πΈ NAME πΈ
Reserved_Data_Types β Built-in reserved Data Types. π
π¦ DESCRIPTION π¦
so here's the tea, bestie: every single data type name in the list below is reserved. that means you literally cannot use them as user-defined type names in your application. they're taken. they're booked. they're the main characters and you are not casting them. π
and it gets deeper β the vector data type names defined over in vectorDataTypes(3clc) are also reserved whenever n is any value other than 2, 3, 4, 8 and 16. so like, the whole n-situation is off-limits unless it's one of those five numbers. iykyk. β¨
here's the full rundown, one by one:
boolnβ a boolean vector. πhalfnβ a 16-bit float vector.quad,quadnβ a 128-bit floating-point number and vectors.complex half,complex halfn,imaginary half,imaginary halfnβ complex and imaginary 16-bit floating-point scalar and vector. πcomplex float,complex floatn,imaginary float,imaginary floatnβ complex and imaginary 32-bit floating-point scalar and vector.complex double,complex doublen,imaginary double,imaginary doublenβ complex and imaginary 64-bit floating-point scalar and vector.complex quad,complex quadn,imaginary quad,imaginary quadnβ complex and imaginary 128-bit floating-point scalar and vector. πfloatnxmβ an n x m matrix of single precision floating-point values stored in column-major order. β¨doublenxmβ an n x m matrix of double precision floating-point values stored in column-major order.long double,long doublenβ a floating-point scalar and vector type with at least as much precision and range as adoubleand no more precision and range than aquad. π«Άlong long,long longnβ a 128-bit signed integer scalar and vector. π₯unsigned long long,ulong long,ulong longnβ a 128-bit unsigned integer scalar and vector. π₯
bestie, this is not a suggestion list. it's a do-not-touch list. pick a different name or the compiler will simply not have it. π
π SPECIFICATION π
OpenCL Specification[1] β that's the source of truth, girl. go read it.
π SEE ALSO π
macroLimits(3clc)scalarDataTypes(3clc)vectorDataTypes(3clc)otherDataTypes(3clc)abstractDataTypes(3clc)enums(3clc)
π AUTHORS π
The Khronos Group β¨
π COPYRIGHT π
Copyright Β© 2007-2011 The Khronos Group Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and/or associated documentation files (the "Materials"), to deal in the Materials without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Materials, and to permit persons to whom the Materials are furnished to do so, subject to the condition that this copyright notice and permission notice shall be included in all copies or substantial portions of the Materials.
π NOTES π
- OpenCL Specification β page 200, section 6.1.4 - Reserved Data Types
okay that's the whole page, bestie, you ate it π π«Ά this was the OpenCL Manual reserved data types situation, brought to you by The Khronos Group, dated 01/14/2021. now go pick a type name that isn't on the forbidden list, mwah ππΈ
π¦ where this page comes from
- ubuntu jammy: opencl-1.2-man-doc 1.0~svn33624-5 Β· other
- ubuntu noble: opencl-1.2-man-doc 1.0~svn33624-5 Β· other
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms