diff src/pt-jit.h @ 15056:bc32288f4a42

Support the end keyword for one dimentional indexing in JIT. * src/jit-ir.cc (jit_magic_end): New class. * src/jit-ir.h (jit_magic_end): New class. (jit_instruction::jit_instruction): New overload. * src/jit-typeinfo.cc (jit_function::call): Throw jit_fail_exception if invalid. (jit_typeinfo::jit_typeinfo): Initialize end_fn. * src/jit-typeinfo.h (jit_typeinfo::end): New function. * src/pt-jit.cc (jit_convert::visit_identifier): Handle magic_end. (jit_convert::resolve): Keep track of end context. (jit_convert::convert_llvm::visit): New overload. * src/pt-jit.h (jit_convert): Add end_context.
author Max Brister <max@2bass.com>
date Mon, 30 Jul 2012 13:05:29 -0500
parents 741d2dbcc117
children df4538e3b50b
line wrap: on
line diff
--- a/src/pt-jit.h	Mon Jul 30 16:23:52 2012 +0100
+++ b/src/pt-jit.h	Mon Jul 30 13:05:29 2012 -0500
@@ -244,6 +244,8 @@
 
   std::list<jit_value *> all_values;
 
+  std::vector<jit_value *> end_context;
+
   size_t iterator_count;
   size_t for_bounds_count;
   size_t short_count;