mirror of
https://github.com/CloverHackyColor/CloverBootloader.git
synced 2024-12-29 17:17:42 +01:00
28 lines
545 B
C++
28 lines
545 B
C++
#include <Platform.h> // Only use angled for Platform, else, xcode project won't compile
|
|
#include "../cpp_foundation/XBuffer.h"
|
|
|
|
int XBuffer_tests()
|
|
{
|
|
|
|
#ifdef JIEF_DEBUG
|
|
// printf("XBuffer_tests -> Enter\n");
|
|
#endif
|
|
|
|
XBuffer<UINT8> xb_uint8;
|
|
|
|
void* p = (void*)1;
|
|
char* p2 = (char*)2;
|
|
xb_uint8.cat(p);
|
|
xb_uint8.cat(p2);
|
|
xb_uint8.cat(uintptr_t(0));
|
|
|
|
XBuffer<UINT8> xb_uint8_2;
|
|
xb_uint8_2.cat(uintptr_t(1));
|
|
xb_uint8_2.cat(uintptr_t(2));
|
|
xb_uint8_2.cat(uintptr_t(0));
|
|
|
|
if ( xb_uint8_2 != xb_uint8 ) return 1;
|
|
|
|
return 0;
|
|
}
|