Clean up some outdated TODOs.
This commit is contained in:
parent
b36b71d3c6
commit
72baefe497
@ -2393,7 +2393,6 @@ void namedSignature(Compiler* compiler, Signature* signature)
|
|||||||
// Compiles a method signature for a constructor.
|
// Compiles a method signature for a constructor.
|
||||||
void constructorSignature(Compiler* compiler, Signature* signature)
|
void constructorSignature(Compiler* compiler, Signature* signature)
|
||||||
{
|
{
|
||||||
// TODO: How should nullary constructors be handled?
|
|
||||||
signature->type = SIG_GETTER;
|
signature->type = SIG_GETTER;
|
||||||
|
|
||||||
// Add the parameters, if there are any.
|
// Add the parameters, if there are any.
|
||||||
|
|||||||
@ -1508,15 +1508,11 @@ void wrenInitializeCore(WrenVM* vm)
|
|||||||
PRIMITIVE(vm->boolClass, "toString", bool_toString);
|
PRIMITIVE(vm->boolClass, "toString", bool_toString);
|
||||||
PRIMITIVE(vm->boolClass, "!", bool_not);
|
PRIMITIVE(vm->boolClass, "!", bool_not);
|
||||||
|
|
||||||
// TODO: Make fibers inherit Sequence and be iterable.
|
|
||||||
vm->fiberClass = defineClass(vm, "Fiber");
|
vm->fiberClass = defineClass(vm, "Fiber");
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "<instantiate>", fiber_instantiate);
|
PRIMITIVE(vm->fiberClass->obj.classObj, "<instantiate>", fiber_instantiate);
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "new(_)", fiber_new);
|
PRIMITIVE(vm->fiberClass->obj.classObj, "new(_)", fiber_new);
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "abort(_)", fiber_abort);
|
PRIMITIVE(vm->fiberClass->obj.classObj, "abort(_)", fiber_abort);
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "current", fiber_current);
|
PRIMITIVE(vm->fiberClass->obj.classObj, "current", fiber_current);
|
||||||
/*
|
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "suspend()", fiber_suspend);
|
|
||||||
*/
|
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "yield()", fiber_yield);
|
PRIMITIVE(vm->fiberClass->obj.classObj, "yield()", fiber_yield);
|
||||||
PRIMITIVE(vm->fiberClass->obj.classObj, "yield(_)", fiber_yield1);
|
PRIMITIVE(vm->fiberClass->obj.classObj, "yield(_)", fiber_yield1);
|
||||||
PRIMITIVE(vm->fiberClass, "call()", fiber_call);
|
PRIMITIVE(vm->fiberClass, "call()", fiber_call);
|
||||||
|
|||||||
@ -45,8 +45,6 @@
|
|||||||
#define STACK_SIZE 1024
|
#define STACK_SIZE 1024
|
||||||
#define MAX_CALL_FRAMES 256
|
#define MAX_CALL_FRAMES 256
|
||||||
|
|
||||||
// TODO: Can we eliminate this and use the classObj pointers to tell an object's
|
|
||||||
// type instead?
|
|
||||||
// Identifies which specific type a heap-allocated object is.
|
// Identifies which specific type a heap-allocated object is.
|
||||||
typedef enum {
|
typedef enum {
|
||||||
OBJ_CLASS,
|
OBJ_CLASS,
|
||||||
|
|||||||
@ -200,10 +200,8 @@ struct WrenMethod
|
|||||||
WrenMethod* next;
|
WrenMethod* next;
|
||||||
};
|
};
|
||||||
|
|
||||||
// TODO: Move into wren_vm.c?
|
|
||||||
struct WrenVM
|
struct WrenVM
|
||||||
{
|
{
|
||||||
// TODO: Use an array for some of these.
|
|
||||||
ObjClass* boolClass;
|
ObjClass* boolClass;
|
||||||
ObjClass* classClass;
|
ObjClass* classClass;
|
||||||
ObjClass* fiberClass;
|
ObjClass* fiberClass;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user