Overview
| Artifact ID: | af5e299fd81eadbba940d0af53a5006eeaeb8524 |
|---|---|
| Ticket: | 971976ffffffffffffffffffffffffffffffffff
Inconsistent naming in [file exists] |
| User & Date: | vincentdarley on 2004-07-06 21:27:53 |
Changes
- icomment:
Logged In: YES user_id=32170 Just one more datapoint: (ActiveTcl8.3) 5 % file exists bin 1 (ActiveTcl8.3) 6 % file exists bin/ 1 (ActiveTcl8.3) 7 % file exists bin/. 1 (ActiveTcl8.3) 8 % cd bin (bin) 9 % file exists tcl83.dll 1 (bin) 10 % file exists tcl83.dll/ 1 (bin) 11 % file exists tcl83.dll/. 1 (bin) 12 % So, this behaviour (including the "odder bug" below) has been there since Tcl 8.3 (i.e. pre 'file normalize'), at least on Windows. This probably means it has been there since even earlier on Windows (in possible contradiction to the behaviour on Solaris 9/tclsh 7.4p3). I'm completely in two minds about which of the two anomalies below is preferable. I agree that: file exists someFile/. == 1 is just wrong. The easiest way to ensure the above result changes is to have 'file normalize someFile/.' be 'someFile/', but that then has the anomaly I first raised. On balance I tend to prefer this anomaly than the one where 'file norm $path' refers to a different filesystem object to $path -- that just seems to contradict the documentation of 'file normalize'.
- login: "vincentdarley"
- mimetype: "text/plain"
- username: "vincentdarley"