meta: replace bluelib with fx
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "lex.h"
|
||||
|
||||
#include <blue/ds/number.h>
|
||||
#include <blue/term/print.h>
|
||||
#include <fx/ds/number.h>
|
||||
#include <fx/term/print.h>
|
||||
#include <ivy/lang/internal.h>
|
||||
#include <ivy/lang/lex.h>
|
||||
#include <stdio.h>
|
||||
@@ -12,23 +12,23 @@ static void print_symbol_node(struct ivy_lexer_symbol_node *node, int depth)
|
||||
fputs(" ", stdout);
|
||||
}
|
||||
|
||||
b_printf("[cyan]%c[reset]", node->s_char);
|
||||
fx_printf("[cyan]%c[reset]", node->s_char);
|
||||
|
||||
if (node->s_def != NULL) {
|
||||
b_printf(
|
||||
fx_printf(
|
||||
" ([magenta]%s[reset])",
|
||||
ivy_symbol_to_string(node->s_def->id));
|
||||
}
|
||||
|
||||
b_printf("\n");
|
||||
fx_printf("\n");
|
||||
|
||||
b_queue_entry *entry = b_queue_first(&node->s_children);
|
||||
fx_queue_entry *entry = fx_queue_first(&node->s_children);
|
||||
while (entry) {
|
||||
struct ivy_lexer_symbol_node *child
|
||||
= b_unbox(struct ivy_lexer_symbol_node, entry, s_entry);
|
||||
= fx_unbox(struct ivy_lexer_symbol_node, entry, s_entry);
|
||||
|
||||
print_symbol_node(child, depth + 1);
|
||||
entry = b_queue_next(entry);
|
||||
entry = fx_queue_next(entry);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -39,14 +39,14 @@ void internal_lexer_print_symbol_tree(struct ivy_lexer *lex)
|
||||
|
||||
void internal_lexer_print_keyword_dict(struct ivy_lexer *lex)
|
||||
{
|
||||
b_iterator *it = b_iterator_begin(lex->lex_keywords);
|
||||
b_foreach_ptr(b_dict_item, item, it)
|
||||
fx_iterator *it = fx_iterator_begin(lex->lex_keywords);
|
||||
fx_foreach_ptr(fx_dict_item, item, it)
|
||||
{
|
||||
const b_string *kw_name = item->key;
|
||||
enum ivy_keyword kw_id = b_number_get_int(item->value);
|
||||
const fx_string *kw_name = item->key;
|
||||
enum ivy_keyword kw_id = fx_number_get_int(item->value);
|
||||
|
||||
b_printf(
|
||||
fx_printf(
|
||||
"([magenta]%s[reset]) = [green]%s[reset]\n",
|
||||
ivy_keyword_to_string(kw_id), b_string_ptr(kw_name));
|
||||
ivy_keyword_to_string(kw_id), fx_string_ptr(kw_name));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user