Move types to Core_Ctx
This commit is contained in:
@@ -213,7 +213,7 @@ gen_value(Token *pos, Value a){
|
||||
gen("%s%Q", string, postfix);
|
||||
}break;
|
||||
case TYPE_POINTER:{
|
||||
if(a.type == type_pointer_to_char){
|
||||
if(a.type == pctx->type_pointer_to_char){
|
||||
gen("\"%Q\"", a.intern_val);
|
||||
}
|
||||
else{
|
||||
@@ -377,7 +377,7 @@ gen_expr(Ast_Expr *ast){
|
||||
CASE(INDEX, Index){
|
||||
gen("(");
|
||||
gen_expr(node->expr);
|
||||
if(node->index_original_type == type_string || node->index_original_type == untyped_string){
|
||||
if(node->index_original_type == pctx->type_string || node->index_original_type == pctx->untyped_string){
|
||||
gen(".str");
|
||||
}
|
||||
else if(is_slice(node->index_original_type)){
|
||||
|
||||
Reference in New Issue
Block a user