On 21/08/2025 18:19, Harald Oehlmann wrote:
I don't find any reference to CreateEnsemble expect in the library/
tclEnsemble.c file.
One of the references in library/tclEnsemble.c is in the function TclMakeEnsemble(). Tthat is the function that most core ensembles use.
Schelte.
I don't find any reference to CreateEnsemble expect in the library/ tclEnsemble.c file.
While I am neutral on implementation as ensembles, I will point out that extending core command ensembles with user / package defined ones has
the potential for conflicts for the same reasons as adding commands to
the global or tcl namespaces.
/Ashok
On 8/22/2025 3:39 PM, Harald Oehlmann wrote:
Am 22.08.2025 um 11:45 schrieb Schelte:
On 21/08/2025 18:19, Harald Oehlmann wrote:Great pointer, thanks, I appreciate.
I don't find any reference to CreateEnsemble expect in the library/
tclEnsemble.c file.
One of the references in library/tclEnsemble.c is in the function
TclMakeEnsemble(). Tthat is the function that most core ensembles use.
Schelte.
Yes, binary, string, namespace, they are all there.
That is great, thank you !
Take care,
Harald
Am 22.08.2025 um 11:45 schrieb Schelte:
On 21/08/2025 18:19, Harald Oehlmann wrote:Great pointer, thanks, I appreciate.
I don't find any reference to CreateEnsemble expect in the library/
tclEnsemble.c file.
One of the references in library/tclEnsemble.c is in the function
TclMakeEnsemble(). Tthat is the function that most core ensembles use.
Schelte.
Yes, binary, string, namespace, they are all there.
That is great, thank you !
Take care,
Harald
Just to clarify, I was not referring to the command syntax but only to
the implementation as ensembles that can be extended. Implementing
commands with subcommands via good old Tcl_GetIndexFromObj is often
simpler and faster. What you lose is user-extensibility which imo is not always desirable. Still, I suppose the fact most core commands are implemented that way now would imply I am in the minority in that opinion.
/Ashok
On 8/30/2025 12:02 PM, Ashok wrote:
While I am neutral on implementation as ensembles, I will point out
that extending core command ensembles with user / package defined ones
has the potential for conflicts for the same reasons as adding
commands to the global or tcl namespaces.
/Ashok
On 8/22/2025 3:39 PM, Harald Oehlmann wrote:
Am 22.08.2025 um 11:45 schrieb Schelte:
On 21/08/2025 18:19, Harald Oehlmann wrote:Great pointer, thanks, I appreciate.
I don't find any reference to CreateEnsemble expect in the library/
tclEnsemble.c file.
One of the references in library/tclEnsemble.c is in the function
TclMakeEnsemble(). Tthat is the function that most core ensembles use. >>>>
Schelte.
Yes, binary, string, namespace, they are all there.
That is great, thank you !
Take care,
Harald
Just to clarify, I was not referring to the command syntax but only to
the implementation as ensembles that can be extended. Implementing
commands with subcommands via good old Tcl_GetIndexFromObj is often
simpler and faster. What you lose is user-extensibility which imo is not >always desirable. Still, I suppose the fact most core commands are >implemented that way now would imply I am in the minority in that opinion.
| Sysop: | Keyop |
|---|---|
| Location: | Huddersfield, West Yorkshire, UK |
| Users: | 715 |
| Nodes: | 16 (3 / 13) |
| Uptime: | 156:14:39 |
| Calls: | 12,093 |
| Calls today: | 1 |
| Files: | 15,000 |
| Messages: | 6,517,729 |