+/* ... op => source position map ........................................... */
+
+typedef struct {
+ char *buf;
+ STRLEN pos;
+ STRLEN size;
+ STRLEN len;
+ line_t line;
+} indirect_op_info_t;
+
+#define PTABLE_NAME ptable
+#define PTABLE_VAL_FREE(V) if (V) { indirect_op_info_t *oi = (V); XSH_LOCAL_FREE(oi->buf, oi->size, char); XSH_LOCAL_FREE(oi, 1, indirect_op_info_t); }
+#define PTABLE_NEED_DELETE 1
+#define PTABLE_NEED_WALK 0
+
+#include "xsh/ptable.h"
+
+/* XSH_LOCAL_FREE() always need aTHX */
+#define ptable_store(T, K, V) ptable_store(aTHX_ (T), (K), (V))
+#define ptable_delete(T, K) ptable_delete(aTHX_ (T), (K))
+#define ptable_clear(T) ptable_clear(aTHX_ (T))
+#define ptable_free(T) ptable_free(aTHX_ (T))
+
+/* ... Lexical hints ....................................................... */
+
+#define XSH_HINTS_TYPE_SV 1
+
+#include "xsh/hints.h"
+
+/* ... Thread-local storage ................................................ */
+
+typedef struct {
+ ptable *map;
+ SV *global_code;
+} xsh_user_cxt_t;
+
+#define XSH_THREADS_USER_CONTEXT 1
+#define XSH_THREADS_USER_CLONE_NEEDS_DUP 1
+#define XSH_THREADS_COMPILE_TIME_PROTECTION 1
+
+#if XSH_THREADSAFE
+
+static void xsh_user_clone(pTHX_ const xsh_user_cxt_t *old_cxt, xsh_user_cxt_t *new_cxt, CLONE_PARAMS *params) {
+ new_cxt->map = ptable_new(32);
+ new_cxt->global_code = xsh_dup_inc(old_cxt->global_code, params);
+
+ return;
+}
+
+#endif /* XSH_THREADSAFE */
+
+#include "xsh/threads.h"
+
+/* ... Lexical hints, continued ............................................ */
+
+static SV *indirect_hint(pTHX) {
+#define indirect_hint() indirect_hint(aTHX)
+ SV *hint;