]> gitweb.factorcode.org Git - factor.git/commitdiff
VM: make return_takes_param() a function
authorBjörn Lindqvist <bjourne@gmail.com>
Sun, 24 Apr 2016 12:19:35 +0000 (14:19 +0200)
committerBjörn Lindqvist <bjourne@gmail.com>
Sun, 24 Apr 2016 12:19:35 +0000 (14:19 +0200)
vm/callbacks.cpp
vm/callbacks.hpp

index 56dc171d75ac9bab66def332407d42157486143c..e6b5ad368d3f6034126fafc0dec73dfae0c5165f 100644 (file)
@@ -2,6 +2,14 @@
 
 namespace factor {
 
+bool return_takes_param_p() {
+#if defined(FACTOR_X86) || defined(FACTOR_AMD64)
+  return true;
+#else
+  return false;
+#endif
+}
+
 callback_heap::callback_heap(cell size, factor_vm* parent) {
   seg = new segment(size, true);
   if (!seg)
@@ -18,14 +26,6 @@ callback_heap::~callback_heap() {
   seg = NULL;
 }
 
-bool callback_heap::return_takes_param_p() {
-#if defined(FACTOR_X86) || defined(FACTOR_AMD64)
-  return true;
-#else
-  return false;
-#endif
-}
-
 instruction_operand callback_heap::callback_operand(code_block* stub,
                                                     cell index) {
   tagged<array> code_template(parent->special_objects[CALLBACK_STUB]);
index 17b9f397604c940e480a0f54cb552b528e4fd143..0de5cad91fea3910df242d0308f8c98425e516f5 100644 (file)
@@ -31,7 +31,6 @@ struct callback_heap {
   callback_heap(cell size, factor_vm* parent);
   ~callback_heap();
 
-  bool return_takes_param_p();
   instruction_operand callback_operand(code_block* stub, cell index);
   void store_callback_operand(code_block* stub, cell index, cell value);
   void update(code_block* stub);