MCPcopy Create free account
hub / github.com/craftzdog/react-native-quick-base64 / constexpr_write_ptr

Class constexpr_write_ptr

cpp/simdutf.h:1427–1455  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1425 * given in the constructor, which is of another type TargetType
1426 */
1427template <typename SrcType, typename TargetType> struct constexpr_write_ptr {
1428 constexpr explicit constexpr_write_ptr(TargetType *raw) : p(raw) {}
1429
1430 constexpr constexpr_write_ptr_proxy<SrcType, TargetType> operator*() const {
1431 return constexpr_write_ptr_proxy<SrcType, TargetType>{p};
1432 }
1433
1434 constexpr constexpr_write_ptr_proxy<SrcType, TargetType>
1435 operator[](std::ptrdiff_t n) const {
1436 return constexpr_write_ptr_proxy<SrcType, TargetType>{p + n};
1437 }
1438
1439 constexpr constexpr_write_ptr &operator++() {
1440 ++p;
1441 return *this;
1442 }
1443
1444 constexpr constexpr_write_ptr operator++(int) {
1445 constexpr_write_ptr old = *this;
1446 ++p;
1447 return old;
1448 }
1449
1450 constexpr std::ptrdiff_t operator-(const constexpr_write_ptr &other) const {
1451 return p - other.p;
1452 }
1453
1454 TargetType *p;
1455};
1456
1457template <typename SrcType, typename TargetType>
1458constexpr auto constexpr_cast_writeptr(TargetType *raw) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected