#include "refl/vertex.h"
#include "refl/std/sarray.h"
#include <array>
int main() {
	auto cls1 = &TypeInfo<void*>::StaticClass;
	auto cls2 = &TypeInfo<const void*>::StaticClass;
	using type1 = real_type_t<const void*>;
	auto& cls = TypeInfo<vec3>::StaticClass;
	auto field = cls.GetField(GetStaticFieldID<vec3>("norm"));
	auto ov = cls.New();

	int x = 10;
	field->Call(&vec3::norm, ov.ptr, x, x);
	field->Invoke({ov.ptr, x, x});
	std::vector<ArgsView> ArgsList{{}, ov.ptr, x, x};
	field->Invoke(ArgsList);
	sarray<ArgsView> sa(ArgsList);
	field->Invoke(sa);
	UMethod_Auto<void, const void*, int, int*>::Call(field, { ov.ptr, x, x });
	//fetchUMethod(&vec3::norm)->Call(field, ov.ptr, x, &x);
	std::cout << "hello world\n";
	return 0;
}