Cleanup and size reduction of Ast/Expr.

This commit is contained in:
Christoffer Lerno
2023-08-18 01:57:56 +02:00
parent 7a39933c97
commit 957ce320ae
36 changed files with 148 additions and 162 deletions

View File

@@ -17,7 +17,6 @@
#define NO_ARENA 0
#define MAX_VECTOR_WIDTH 65536
#define MAX_ARRAY_SIZE INT64_MAX
#define MAX_IDENTIFIER_LENGTH 31
#define MAX_SOURCE_LOCATION_LEN 255
#define PROJECT_JSON "project.json"

View File

@@ -36,7 +36,7 @@
#endif
uint16_t *win_utf8to16(const char *value)
uint16_t *win_utf8to16(const char *value UNUSED)
{
#if (_MSC_VER)
size_t len = strlen(value);
@@ -57,7 +57,7 @@ uint16_t *win_utf8to16(const char *value)
}
#include <wchar.h>
char *win_utf16to8(const uint16_t *wname)
char *win_utf16to8(const uint16_t *wname UNUSED)
{
#if (_MSC_VER)
size_t len = wcslen(wname);

View File

@@ -329,7 +329,6 @@ void scratch_buffer_append_double(double d)
scratch_buffer.len += len_needed;
//removing unused zeroes and dot
size_t i = scratch_buffer.len;
while (scratch_buffer.len > 0)
{
if (scratch_buffer.str[scratch_buffer.len - 1] != '0' && scratch_buffer.str[scratch_buffer.len - 1] != '.')

View File

@@ -16,7 +16,6 @@ typedef struct TaskQueue_
static void *taskqueue_thread(void *data)
{
TaskQueue *task_queue = data;
bool is_active = false;
while (1)
{
pthread_mutex_lock(&task_queue->lock);

View File

@@ -211,9 +211,7 @@ static int get_executable_path_raw(char *out, int capacity, int *dirname_length)
#include <mach-o/dyld.h>
#include <limits.h>
#include <stdlib.h>
#include <string.h>
#include <dlfcn.h>
#include "lib.h"