brintos

brintos / llvm-project-archived public Read only

0
0
Text · 597 B · 778642e Raw
27 lines · cpp
1#include <cstring>2 3template <typename T>4class Foo5{6public:7    Foo () : object() {}8    Foo (T x) : object(x) {}9    T getObject() { return object; }10private:11    T object;12};13 14 15int main (int argc, char const *argv[])16{17    Foo<int> foo_x('a');18    Foo<wchar_t> foo_y(L'a');19    const wchar_t *mazeltov = L"מזל טוב";20    wchar_t *ws_NULL = nullptr;21    wchar_t *ws_empty = L"";22  	wchar_t array[200], * array_source = L"Hey, I'm a super wchar_t string, éõñž";23    wchar_t wchar_zero = (wchar_t)0;24  	memcpy(array, array_source, 39 * sizeof(wchar_t));25    return 0; // break here26}27