some type system updates
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
#include "string.h"
|
||||
|
||||
kerepTypeId_define(kerepTypeId_string);
|
||||
kerepTypeId_define(kerepTypeId_stringPtr);
|
||||
|
||||
// copies str content to new char pointer value (adding '\0' at the end)
|
||||
char* string_extract(string str){
|
||||
if(str.length==0) return NULL;
|
||||
|
||||
@@ -12,6 +12,8 @@ typedef struct string{
|
||||
char* ptr; // char pointer
|
||||
uint32 length; // amount of chars in ptr value
|
||||
} string;
|
||||
kerepTypeId_declare(kerepTypeId_string);
|
||||
kerepTypeId_declare(kerepTypeId_stringPtr);
|
||||
|
||||
static const string stringNull={NULL,0};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user