+
    q\i                    r   ^ RI Ht ^ RIt^ RIt^ RIHt ^ RIHt ^RIH	t	 ^RI
HtHt ]P                  R8X  dp   ^ RIt^ RIt^ RIHt R	tR
t]P&                  ! RRR7      t]P*                  .]P,                  n        ]P0                  ]P,                  n        R R lt ! R R]	4      tM ! R R]	4      tR.tR# )    )annotationsN)EACCES)cast)BaseFileLock)ensure_directory_existsraise_on_not_writable_filewin32)wintypesi   l    kernel32T)use_last_errorc                    V ^8  d   QhRRRR/# )   pathstrreturnbool )formats   "i/Users/agent/.cache/uv/archive-v0/6ZL4-8mCcRNgGE9wi6M6J/lib/python3.14/site-packages/filelock/_windows.py__annotate__r      s     : : : :    c                    \         P                  V 4      pV\        8X  d*   \        P                  ! 4       pV^8X  d   R# V^8X  d   R# R# \        V\        ,          4      # )z
Check if a path is a reparse point (symlink, junction, etc.) on Windows.

:param path: Path to check

:returns: True if path is a reparse point, False otherwise

:raises OSError: If GetFileAttributesW fails for reasons other than file-not-found

F)	_kernel32GetFileAttributesWINVALID_FILE_ATTRIBUTESctypesget_last_errorr   FILE_ATTRIBUTE_REPARSE_POINT)r   attrserrs   &  r   _is_reparse_pointr!      sS     ,,T2++'')CaxaxE8899r   c                  2    ] tR t^0tRtR R ltR R ltRtR# )WindowsFileLockWUses the :func:`msvcrt.locking` function to hard lock the lock file on Windows systems.c                   V ^8  d   QhRR/# r   r   Noner   )r   s   "r   r   WindowsFileLock.__annotate__3   s     	4 	4d 	4r   c                	   \        V P                  4       \        V P                  4       \        V P                  4      '       d   R V P                   2p\	        V4      h\
        P                  \
        P                  ,          p \
        P                  ! V P                  W P                  4       4      p \        P                  ! V\        P                  ^4       W0P                  n        R#   \         d8   p\
        P                  ! T4       TP                   \"        8w  d   h  Rp?R# Rp?ii ; i  \         d"   pTP                   \"        8w  d   h  Rp?R# Rp?ii ; i)z1Lock file is a reparse point (symlink/junction): N)r   	lock_filer   r!   OSErrorosO_RDWRO_CREATopen
_open_modemsvcrtlockingLK_NBLCK_contextlock_file_fdcloseerrnor   )selfmsgflagsfd	exceptions   &    r   _acquireWindowsFileLock._acquire3   s    &t~~6#DNN3 !00I$..IYZcl" 		** 4WWT^^UOO4EF
4NN2v: 24MM.  HHRL &0 1  ??f, -s0   /D3 6&C. .D09,D++D03E>EEc                   V ^8  d   QhRR/# r&   r   )r   s   "r   r   r(   P   s     	 	d 	r   c                	    \        R V P                  P                  4      pRV P                  n        \        P                  ! V\        P
                  ^4       \        P                  ! V4       R# )intN)r   r4   r5   r1   r2   LK_UNLCKr,   r6   )r8   r;   s   & r   _releaseWindowsFileLock._releaseP   sC    eT]]778B)-DMM&NN2v2HHRLr   r   N__name__
__module____qualname____firstlineno____doc__r=   rC   __static_attributes__r   r   r   r#   r#   0   s    e	4:	 	r   r#   c                  2    ] tR t^XtRtR R ltR R ltRtR# )r#   r$   c                   V ^8  d   QhRR/# r&   r   )r   s   "r   r   r(   [        	& 	&d 	&r   c                	    \         hNNotImplementedErrorr8   s   &r   r=   r>   [       %%r   c                   V ^8  d   QhRR/# r&   r   )r   s   "r   r   r(   ^   rN   r   c                	    \         hrP   rQ   rS   s   &r   rC   rD   ^   rT   r   r   NrE   r   r   r   r#   r#   X   s    e	&	& 	&r   )
__future__r   r,   sysr7   r   typingr   _apir   _utilr   r   platformr   r1   r
   r   r   WinDLLr   LPCWSTRr   argtypesDWORDrestyper!   r#   __all__r   r   r   <module>rc      s    " 	 
    F<<7 $. ( j>I-5-=-=,>I  )+3>>I  (:.$, $P&, & r   