mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-23 07:51:10 +01:00
Add operator char * to the naked array types as well
This commit is contained in:
1 parent
d6fdae310f
commit
db889c182e
2 files changed
+5
-1
No files matched your search
+3
-1
@@ -553,8 +553,10 @@ struct hb_array_t
|
||||
|
||||
inline unsigned int get_size (void) const { return len * sizeof (Type); }
|
||||
|
||||
template <typename T> inline operator T * (void) { return arrayZ; }
|
||||
template <typename T> inline operator T * (void) { return arrayZ; }
|
||||
template <typename T> inline operator const T * (void) const { return arrayZ; }
|
||||
inline operator char * (void) { return (char *) arrayZ; }
|
||||
inline operator const char * (void) const { return (const char *) arrayZ; }
|
||||
|
||||
inline Type * operator & (void) { return arrayZ; }
|
||||
inline const Type * operator & (void) const { return arrayZ; }
|
||||
|
||||
@@ -342,6 +342,8 @@ struct UnsizedArrayOf
|
||||
|
||||
template <typename T> inline operator T * (void) { return arrayZ; }
|
||||
template <typename T> inline operator const T * (void) const { return arrayZ; }
|
||||
inline operator char * (void) { return (char *) arrayZ; }
|
||||
inline operator const char * (void) const { return (const char *) arrayZ; }
|
||||
|
||||
inline unsigned int get_size (unsigned int len) const
|
||||
{ return len * Type::static_size; }
|
||||
|
||||
Reference in new issue
Block a user