tcl expert needed

Bradley Giesbrecht pixilla at macports.org
Fri Jun 1 11:02:22 PDT 2012


On Jun 1, 2012, at 12:44 AM, Bjarne D Mathiesen wrote:

> Gustaf Neumann wrote:
>> On 01.06.12 04:20, Bjarne D Mathiesen wrote:
>>> Joshua Root wrote:
>>>> On 2012-6-1 10:21 , Bjarne D Mathiesen wrote:
>>>> The try command is not standard Tcl, it's defined in
>>>> base/src/macports1.0/macports_util.tcl.
>>> it's in the tcl we've got ... but a little different than the one
>>> described on http://tmml.sourceforge.net/doc/tcl/try.html as there's no
>>> /on error/
>> 
>> Be aware, that there are myn versions of "try" around and there
>> is a "try" command in Tcl 8.6.
>> 
>> http://www.tcl.tk/man/tcl8.6/TclCmd/try.htm
>> 
>> The usual technique to handle multiple implementations of a command
>> in tcl is to use multiple namespaces and "namespace path" or
>> imports/exports
>> into namespaces.
> 
> well, in this case it simply turned out that I luckily didn't need to
> use /try/ /catch/ at all ;-)
> 
> the finished code is this :
> 
> +++ script start +++
> #
> # this proc recurses down through a file system

FYI, if this is for port to execute we have fs-traverse.

man portfile


Regards,
Bradley Giesbrecht (pixilla)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 2763 bytes
Desc: not available
URL: <http://lists.macosforge.org/pipermail/macports-dev/attachments/20120601/2f77cebb/attachment.bin>


More information about the macports-dev mailing list