|
From: Andreas K. <and...@Ac...> - 2006-01-31 17:31:14
|
> On Tue, 31 Jan 2006 at 13:18, Neil Madden wrote:
>
> > I'd vote for directly into the "fileutil" namespace.
>
> me too. I see no need here to make the command names even longer by
> adding a level of sub-namespaces.
I am not convinced of that argument for not using a namespace. We can always
use 'namespace export/import' + aliases to create short names.
> > Perhaps mapfile or filemap or even just map (i.e. [fileutil::map])
> > as it is quite similar to [string map]? The copy version can be done
> > as an option: fileutil map -copy $outfile $infile key val ...
>
> How about this signature?
>
> fileutil::map {key value ...} infile ?outfile?
> It would be a mixture of [string map] (regarding the mapping list) and
> [regsub] (regarding the optional "to" argument).
I like that signature ... Noted now.
>
> Off-topic remark:
This is for c.l.t., or tcl-core. Having said that, my opinion: No, I do not
think so.
--
Andreas Kupries <and...@Ac...>
Developer @ http://www.ActiveState.com, a division of Sophos
Tel: +1 604 484 6491
|