Skip to content

Commit b231aff

Browse files
committed
Merge branch 'master' of https://github.com/IsaacShelton/Adept
2 parents 6803917 + b3ada78 commit b231aff

File tree

4 files changed

+3
-9
lines changed

4 files changed

+3
-9
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@ ifeq ($(OS), Windows_NT)
336336
@del obj\*.* /S /Q 1> nul 2>&1
337337
@del bin\adept.exe /S /Q 1> nul 2>&1
338338
@del bin\adept_debug.exe /S /Q 1> nul 2>&1
339-
@del unittests\obj\*.* /S /Q 1> nul 2>&1
339+
@if exist unittests\obj @del unittests\obj\*.* /S /Q 1> nul 2>&1
340340
else
341341
@find . -name "*.o" -type f -delete 2> /dev/null
342342
@rm -rf 2> /dev/null bin/adept

include/UTIL/ground.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ extern "C" {
1919
#include <stdlib.h>
2020
#include <string.h>
2121
#include <stdbool.h>
22+
#include <stdint.h>
2223

2324
#ifdef _WIN32
2425
#include <io.h>

src/AST/ast_layout.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,7 @@ bool ast_layout_bone_has_polymorph(ast_layout_bone_t *bone){
286286
default:
287287
internalerrorprintf("ast_layout_bone_has_polymorph() got unknown bone kind\n");
288288
}
289+
return false;
289290
}
290291

291292
strong_cstr_t ast_layout_bone_str(ast_layout_bone_t *bone, ast_field_map_t *field_map, ast_layout_endpoint_t endpoint){

src/INFER/infer.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1090,7 +1090,6 @@ errorcode_t infer_type(infer_ctx_t *ctx, ast_type_t *type){
10901090
switch(elem->id){
10911091
case AST_ELEM_BASE: {
10921092
weak_cstr_t base = ((ast_elem_base_t*) elem)->base;
1093-
ast_composite_t *composite;
10941093

10951094
if(strcmp(base, "void") == 0 && type->elements_length > 1 && e != 0 && type->elements[e - 1]->id == AST_ELEM_POINTER){
10961095
// Substitute '*void' with 'ptr'
@@ -1132,8 +1131,6 @@ errorcode_t infer_type(infer_ctx_t *ctx, ast_type_t *type){
11321131
free(cloned.elements);
11331132
continue; // Don't do normal stuff that follows
11341133
}
1135-
1136-
composite = ast_composite_find_exact(ctx->ast, base);
11371134
}
11381135
break;
11391136
case AST_ELEM_FUNC:
@@ -1143,11 +1140,6 @@ errorcode_t infer_type(infer_ctx_t *ctx, ast_type_t *type){
11431140
if(infer_type(ctx, ((ast_elem_func_t*) elem)->return_type)) return FAILURE;
11441141
break;
11451142
case AST_ELEM_GENERIC_BASE: {
1146-
weak_cstr_t base = ((ast_elem_generic_base_t*) elem)->name;
1147-
ast_polymorphic_composite_t *poly_composite;
1148-
1149-
poly_composite = ast_polymorphic_composite_find_exact(ctx->ast, base);
1150-
11511143
for(length_t a = 0; a != ((ast_elem_generic_base_t*) elem)->generics_length; a++){
11521144
if(infer_type(ctx, &((ast_elem_generic_base_t*) elem)->generics[a])) return FAILURE;
11531145
}

0 commit comments

Comments
 (0)