Subject: Make obj-free bytecode maker available to rest of compile-related files.

From: dgp <[email-masked]>
Date: Fri, 29 Apr 2016 17:58:33 +0000

---
 generic/tclCompile.c | 3 ++-
 generic/tclCompile.h | 1 +
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/generic/tclCompile.c b/generic/tclCompile.c
index 8837f06..32a09b2 100644
--- a/generic/tclCompile.c
+++ b/generic/tclCompile.c
@@ -677,6 +677,7 @@ static void		FreeSubstCodeInternalRep(Tcl_Obj *objPtr);
 static int		GetCmdLocEncodingSize(CompileEnv *envPtr);
 static int		IsCompactibleCompileEnv(Tcl_Interp *interp,
 			    CompileEnv *envPtr);
+static void		PreventCycle(Tcl_Obj *objPtr, CompileEnv *envPtr);
 #ifdef TCL_COMPILE_STATS
 static void		RecordByteCodeStats(ByteCode *codePtr);
 #endif /* TCL_COMPILE_STATS */
@@ -2741,7 +2742,7 @@ PreventCycle(
     }
 }
 
-static ByteCode *
+ByteCode *
 TclInitByteCode(
     register CompileEnv *envPtr)/* Points to the CompileEnv structure from
 				 * which to create a ByteCode structure. */
diff --git a/generic/tclCompile.h b/generic/tclCompile.h
index 86a9db0..af8d60f 100644
--- a/generic/tclCompile.h
+++ b/generic/tclCompile.h
@@ -1118,6 +1118,7 @@ MODULE_SCOPE int	TclFixupForwardJump(CompileEnv *envPtr,
 			    int distThreshold);
 MODULE_SCOPE void	TclFreeCompileEnv(CompileEnv *envPtr);
 MODULE_SCOPE void	TclFreeJumpFixupArray(JumpFixupArray *fixupArrayPtr);
+MODULE_SCOPE ByteCode *	TclInitByteCode(CompileEnv *envPtr);
 MODULE_SCOPE void	TclInitByteCodeObj(Tcl_Obj *objPtr,
 			    CompileEnv *envPtr);
 MODULE_SCOPE void	TclInitCompileEnv(Tcl_Interp *interp,
-- 
cgit v0.12