mirror of
https://github.com/wren-lang/wren.git
synced 2026-01-11 22:28:45 +01:00
Fix a couple more casts needed in C++.
This commit is contained in:
@ -28,7 +28,7 @@ static char* loadModule(WrenVM* vm, const char* module)
|
||||
source = "System.print(\"ok\")";
|
||||
}
|
||||
|
||||
char* string = malloc(strlen(source) + 1);
|
||||
char* string = (char*)malloc(strlen(source) + 1);
|
||||
strcpy(string, source);
|
||||
return string;
|
||||
}
|
||||
@ -91,7 +91,7 @@ static const char* resolveChange(WrenVM* vm, const char* importer,
|
||||
{
|
||||
// Concatenate importer and name.
|
||||
size_t length = strlen(importer) + 1 + strlen(name) + 1;
|
||||
char* result = malloc(length);
|
||||
char* result = (char*)malloc(length);
|
||||
strcpy(result, importer);
|
||||
strcat(result, "/");
|
||||
strcat(result, name);
|
||||
|
||||
Reference in New Issue
Block a user