annotate runtime/proghead.inc @ 34:a10f1b049193

Working closures, but need to rethink method call strategy
author Mike Pavone <pavone@retrodev.com>
date Mon, 09 Jul 2012 08:57:50 -0700
parents 668f533e5284
children bf5e88f6419d
rev   line source
pavone@31 1 #include "object.h"
pavone@31 2 #include <stddef.h>
pavone@31 3 #include <stdlib.h>
pavone@31 4 #include <stdio.h>
pavone@31 5
pavone@34 6 object * main_module;
pavone@34 7
pavone@31 8 object * no_impl(uint32_t method_id, uint32_t num_args, object ** params)
pavone@31 9 {
pavone@34 10 printf("method %d is not implemented on object %p\n", method_id, params[0]);
pavone@34 11 printf("main_module %p\n", main_module);
pavone@31 12 exit(0);
pavone@31 13 return NULL;
pavone@31 14 }
pavone@31 15
pavone@31 16 obj_meta lambda_meta = {
pavone@31 17 sizeof(closure),
pavone@31 18 {no_impl, no_impl, no_impl, no_impl, no_impl, no_impl, no_impl, no_impl,
pavone@31 19 no_impl, no_impl, no_impl, no_impl, no_impl, no_impl, no_impl, no_impl}
pavone@31 20 };