mirror of
				https://github.com/python/cpython.git
				synced 2025-11-03 19:34:08 +00:00 
			
		
		
		
	Added doc for errorcode dictionary.
This commit is contained in:
		
							parent
							
								
									5d68e8e312
								
							
						
					
					
						commit
						5de64883d8
					
				
					 2 changed files with 12 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -5,11 +5,16 @@
 | 
			
		|||
 | 
			
		||||
This module makes available standard errno system symbols.
 | 
			
		||||
The value of each symbol is the corresponding integer value.
 | 
			
		||||
The names and descriptions are borrowed from linux/include/errno.h,
 | 
			
		||||
The names and descriptions are borrowed from \file{linux/include/errno.h},
 | 
			
		||||
which should be pretty all-inclusive.  Of the following list, symbols
 | 
			
		||||
that are not used on the current platform are not defined by the
 | 
			
		||||
module.
 | 
			
		||||
 | 
			
		||||
The module also defines the dictionary variable \code{errorcode} which
 | 
			
		||||
maps numeric error codes back to their symbol names, so that e.g.
 | 
			
		||||
\code{errno.errorcode[errno.EPERM] == 'EPERM'}.  To translate a
 | 
			
		||||
numeric error code to an error message, use \code{os.strerror()}.
 | 
			
		||||
 | 
			
		||||
Symbols available can include:
 | 
			
		||||
\begin{datadesc}{EPERM} Operation not permitted \end{datadesc}
 | 
			
		||||
\begin{datadesc}{ENOENT} No such file or directory \end{datadesc}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -5,11 +5,16 @@
 | 
			
		|||
 | 
			
		||||
This module makes available standard errno system symbols.
 | 
			
		||||
The value of each symbol is the corresponding integer value.
 | 
			
		||||
The names and descriptions are borrowed from linux/include/errno.h,
 | 
			
		||||
The names and descriptions are borrowed from \file{linux/include/errno.h},
 | 
			
		||||
which should be pretty all-inclusive.  Of the following list, symbols
 | 
			
		||||
that are not used on the current platform are not defined by the
 | 
			
		||||
module.
 | 
			
		||||
 | 
			
		||||
The module also defines the dictionary variable \code{errorcode} which
 | 
			
		||||
maps numeric error codes back to their symbol names, so that e.g.
 | 
			
		||||
\code{errno.errorcode[errno.EPERM] == 'EPERM'}.  To translate a
 | 
			
		||||
numeric error code to an error message, use \code{os.strerror()}.
 | 
			
		||||
 | 
			
		||||
Symbols available can include:
 | 
			
		||||
\begin{datadesc}{EPERM} Operation not permitted \end{datadesc}
 | 
			
		||||
\begin{datadesc}{ENOENT} No such file or directory \end{datadesc}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue