changed some log messages
This commit is contained in:
parent
37e8fdcd6a
commit
982a79a052
@ -44,6 +44,7 @@ typedef enum{
|
|||||||
kerepTypeDescriptorsState initState=NotInitialized;
|
kerepTypeDescriptorsState initState=NotInitialized;
|
||||||
|
|
||||||
void kerepTypeDescriptors_beginInit(){
|
void kerepTypeDescriptors_beginInit(){
|
||||||
|
printf("\e[94mtype descriptors initializing...\n");
|
||||||
__kerepTypeDescriptors=Autoarr_create(kerepTypeDescriptor, 256, 256);
|
__kerepTypeDescriptors=Autoarr_create(kerepTypeDescriptor, 256, 256);
|
||||||
if(__kerepTypeDescriptors==NULL) throw(ERR_NULLPTR);
|
if(__kerepTypeDescriptors==NULL) throw(ERR_NULLPTR);
|
||||||
}
|
}
|
||||||
@ -52,14 +53,16 @@ void kerepTypeDescriptors_endInit(){
|
|||||||
typeDescriptors=Autoarr_toArray(__kerepTypeDescriptors);
|
typeDescriptors=Autoarr_toArray(__kerepTypeDescriptors);
|
||||||
Autoarr_free(__kerepTypeDescriptors,true);
|
Autoarr_free(__kerepTypeDescriptors,true);
|
||||||
if(typeDescriptors==NULL) throw(ERR_NULLPTR);
|
if(typeDescriptors==NULL) throw(ERR_NULLPTR);
|
||||||
|
printf("\e[92minitialized %u type descriptors\n", kerepTypeId_last);
|
||||||
}
|
}
|
||||||
|
|
||||||
void __kerepType_register(char* name, int16 size, void (*free_members)(void*)){
|
void __kerepType_register(char* name, int16 size, void (*free_members)(void*)){
|
||||||
kerepTypeDescriptor typeDesc={
|
kerepTypeDescriptor typeDesc={
|
||||||
.name=name,
|
.name=name,
|
||||||
.size=size,
|
.size=size,
|
||||||
.free_members=free_members,
|
.free_members=free_members,
|
||||||
.id=++kerepTypeId_last
|
.id=++kerepTypeId_last
|
||||||
}; dbg(kerepTypeId_last);
|
};
|
||||||
Autoarr_add(__kerepTypeDescriptors, typeDesc);
|
Autoarr_add(__kerepTypeDescriptors, typeDesc);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -16,7 +16,7 @@ int main(){
|
|||||||
kerepTypeDescriptors_beginInit();
|
kerepTypeDescriptors_beginInit();
|
||||||
kerepTypeDescriptors_initKerepTypes();
|
kerepTypeDescriptors_initKerepTypes();
|
||||||
kerepTypeDescriptors_endInit();
|
kerepTypeDescriptors_endInit();
|
||||||
printf("\e[92mkerep tests are starting!\e[97m\n");
|
printf("\e[97mkerep tests are starting!\n");
|
||||||
optime("test_all",1,test_all());
|
optime("test_all",1,test_all());
|
||||||
printf("\e[0m\n");
|
printf("\e[0m\n");
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@ -6,8 +6,9 @@ void printstnode(STNode* node){
|
|||||||
IFWIN("%llu", "%lu")
|
IFWIN("%llu", "%lu")
|
||||||
"\n address: %p\n value: ",sizeof(STNode),node);
|
"\n address: %p\n value: ",sizeof(STNode),node);
|
||||||
printuni(node->value);
|
printuni(node->value);
|
||||||
|
printf("\n");
|
||||||
// prints pointers to all existing branches
|
// prints pointers to all existing branches
|
||||||
/* printf("\n branches: %p\n", node->branches);
|
/* printf(" branches: %p\n", node->branches);
|
||||||
if(node->branches) for(uint8 i=0;i<8;i++){
|
if(node->branches) for(uint8 i=0;i<8;i++){
|
||||||
printf(" \e[90m[%u]=%p\n",i,node->branches[i]);
|
printf(" \e[90m[%u]=%p\n",i,node->branches[i]);
|
||||||
if(node->branches[i])
|
if(node->branches[i])
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user