Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: fdbf6ce568e83b8e7ca377131d9a741306364a9384a9a9e360574f20a7b443d7
Ticket: 7eb6b3a53f963364c3c6f29d7622d70ddf8dd610
glob on UNC path requires additional slash
User & Date: apnadkarni on 2026-05-29 11:54:36
Changes

  1. icomment:
    That is not a UNC path. As far as I can see, UNC paths work correctly.
    
    ```
    % llength [glob //IO/src/*]
    124
    % llength [glob {\\IO\src\*}]
    124
    % llength [glob "\\\\IO\\src\\*"]
    124
    ```
    
    The `\\?\` notation follows different syntax rules and semantics. For example, `C:\foo\..\bar` and `\\?\C:\foo\..\bar` are *different* paths as are `C:\foo/bar` and `\\?\C:\foo/bar`, or `C:\foo\bar.` and `\\?\C:\foo\bar.`
    
    Tcl does not really support the `\\?\` syntax. There are some hacks (sorry, but they really are hacks) within Tcl that attempt to deal with this in piecemeal fashion. They lead you to believe that syntax is supported but it isn't. Moreover, in my opinion this is actually not fixable because not even all Win32 API's that Tcl uses understand the syntax.
    
    See [bc7925fc50](https://core.tcl-lang.org/tcl/tktview/bc7925fc50) for other cases.
    
  2. login: "apnadkarni"
  3. mimetype: "text/x-markdown"