Skip to content

Instantly share code, notes, and snippets.

View sethhorsley's full-sized avatar
🦾
who knows

Seth Horsley sethhorsley

🦾
who knows
View GitHub Profile
@sethhorsley
sethhorsley / parse_prism.c
Created February 10, 2025 04:34
Parse ruby from c using prism
#include <prism.h>
#include <stdlib.h>
void erbx_parse(const uint8_t *source, size_t length) {
pm_parser_t parser;
pm_parser_init(&parser, source, length, NULL);
pm_node_t *root = pm_parse(&parser);
const char *hh = pm_token_type_name(root->type);