From 1595f3257e9b194c86b9e790c2d58f46ae907bae Mon Sep 17 00:00:00 2001
From: Damien <damien.p.george@gmail.com>
Date: Sat, 19 Oct 2013 15:09:32 +0100
Subject: [PATCH] Make rt_fun_table const, so it goes in .text section.

---
 py/runtime.c | 2 +-
 py/runtime.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/py/runtime.c b/py/runtime.c
index d367530ccc..01fd92fcff 100644
--- a/py/runtime.c
+++ b/py/runtime.c
@@ -1546,7 +1546,7 @@ py_obj_t rt_iternext(py_obj_t o_in) {
     }
 }
 
-void *rt_fun_table[RT_F_NUMBER_OF] = {
+const void *const rt_fun_table[RT_F_NUMBER_OF] = {
     rt_load_const_str,
     rt_load_name,
     rt_load_global,
diff --git a/py/runtime.h b/py/runtime.h
index e676f14c08..86d59f24e5 100644
--- a/py/runtime.h
+++ b/py/runtime.h
@@ -76,7 +76,7 @@ typedef enum {
     RT_F_NUMBER_OF,
 } rt_fun_kind_t;
 
-extern void *rt_fun_table[RT_F_NUMBER_OF];
+extern const void *const rt_fun_table[RT_F_NUMBER_OF];
 
 typedef machine_ptr_t py_obj_t; // must be of pointer size
 typedef py_obj_t (*py_fun_0_t)();
-- 
GitLab