Commit Graph

25 Commits

Author SHA1 Message Date
Henner Zeller e8218f2db1
Tcl 9 compatibility changes (#414)
* Provide close2proc function to prevent tcl9 from crashing.

Tcl 9 does not test if the close2Proc function pointer is non-null,
but calls it unconditionally:
https://github.com/tcltk/tcl/blob/core-9-0-3/generic/tclIO.c#L384

So we need to provide a non-null function pointer for our code
to not crash with Tcl9.

Use the same implementation as the previous close channel
had.

Signed-off-by: Henner Zeller <h.zeller@acm.org>

* Use non-deprecated trace add variable syntax.

In modern tcl, `trace variable` is now i`trace add variable`,
and `"rw"` should be spelled out as `{read write}`
There were backwards compatible forms in Tcl 8.x but now loudly
complains in Tcl 9

Signed-off-by: Henner Zeller <h.zeller@acm.org>

* Use `Tcl_Size` for all tcl functions returning sizes.

This is the type the Tcl-API provides in its prototypes and
starting from Tcl9 this typedef actually changes from `int` to `long`,
so will no longer compile when passing an `int*`.

So whenever we get a return value of this type, use the
correct typedef to declare the variable. This makes it forward and
backward compatible.

Signed-off-by: Henner Zeller <h.zeller@acm.org>

* Address review comments: compare with `read`/`write` not `r`, `w`

Signed-off-by: Henner Zeller <h.zeller@acm.org>

---------

Signed-off-by: Henner Zeller <h.zeller@acm.org>
2026-04-03 11:02:25 -07:00
James Cherry 6742692876 string squash
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2026-03-28 19:13:35 -07:00
James Cherry 464bc3ae4f Report use string instead of string_view
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2026-03-18 13:01:05 -07:00
James Cherry 134b547501 use std::format squash 2026-03-16 15:01:38 -07:00
James Cherry 981f44db68 update copyright
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2026-03-10 14:57:45 -07:00
James Cherry 2a4fd08211 update copyright
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2025-01-21 18:54:33 -07:00
James Cherry 80ecdf267f ReportTcl const resolves #166
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2025-01-08 11:38:29 -07:00
James Cherry d1d0e097f9 survive tcl9 damage infliced by homebrew/OpenROAD DependencyInstaller
commit b08f24685f52d242985c1c1f48c5b3821728d355
Author: James Cherry <cherry@parallaxsw.com>
Date:   Thu Jan 2 15:18:46 2025 -0800

    tcl9 conditional support

    Signed-off-by: James Cherry <cherry@parallaxsw.com>

commit bc0ebaa856196d09ea95cbd4e12e4d88b8a8d13e
Author: James Cherry <cherry@parallaxsw.com>
Date:   Thu Jan 2 11:33:46 2025 -0800

    tcl9 partial support

    Signed-off-by: James Cherry <cherry@parallaxsw.com>

Signed-off-by: James Cherry <cherry@parallaxsw.com>
2025-01-02 15:20:41 -08:00
James Cherry 422a5819bd update copyright
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2024-01-11 16:34:49 -08:00
James Cherry 44159bbb53 remove deprecated system .h includes
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2023-06-15 08:59:56 -07:00
James Cherry cc2ef1783f update copyright
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2023-02-18 17:55:40 -07:00
James Cherry 2bc6e8f68c update copyright
Signed-off-by: James Cherry <cherry@parallaxsw.com>
2022-01-04 10:17:08 -07:00
James Cherry 2e8f0035dc update copyright 2021-06-25 10:25:49 -07:00
James Cherry abb0243c87 rm tcl_encap_type_stderr 2021-01-03 14:38:14 -08:00
James Cherry af887c3112 debugPrint use __VA_ARGS__ 2021-01-01 11:46:51 -08:00
James Cherry e55b66f60b rm support for tcl <8.4 2020-12-26 09:17:02 -08:00
James Cherry 078d69fc8d rm printError, Report::error throws exception 2020-12-24 16:31:52 -08:00
James Cherry 9a0790d15e cleanup 2020-12-19 17:27:29 -07:00
James Cherry b104aa7138 ReportTcl fmt and rm casts 2020-04-12 19:19:22 -07:00
James Cherry ee326f165c public headers in include/sta 2020-04-05 14:53:44 -07:00
James Cherry 804953e317 mv public headers to include/sta 2020-04-05 11:35:51 -07:00
James Cherry 4a017e86eb update copyright 2020-03-06 18:50:37 -08:00
James Cherry e5c9bc43fd 2.0.10 2019-03-12 17:25:53 -07:00
James Cherry b075ccc783 update copyright 2019-01-01 12:26:11 -08:00
James Cherry 1154fb89fd and then there was light... 2018-09-28 08:54:21 -07:00