Merge pull request #3310 from robinsonb5-PRs/master master
authorMiodrag Milanović <mmicko@gmail.com>
Tue, 17 May 2022 07:33:20 +0000 (09:33 +0200)
committerGitHub <noreply@github.com>
Tue, 17 May 2022 07:33:20 +0000 (09:33 +0200)
Now calls Tcl_Init after creating the interp, fixes clock format.

kernel/yosys.cc

index 09909696be1df467585471e1fd021565220088ab..4e1a3ca7e2d883175e8d778629f297352c2d7d63 100644 (file)
@@ -733,6 +733,8 @@ extern Tcl_Interp *yosys_get_tcl_interp()
 {
        if (yosys_tcl_interp == NULL) {
                yosys_tcl_interp = Tcl_CreateInterp();
+               if (Tcl_Init(yosys_tcl_interp)!=TCL_OK)
+                       log_warning("Tcl_Init() call failed - %s\n",Tcl_ErrnoMsg(Tcl_GetErrno()));
                Tcl_CreateCommand(yosys_tcl_interp, "yosys", tcl_yosys_cmd, NULL, NULL);
        }
        return yosys_tcl_interp;