[Pythonjp-checkins] [python-doc-ja] push by songo****@gmail***** - Update 2.7.2: c-api/string on 2011-11-09 10:05 GMT

Zurück zum Archiv-Index

pytho****@googl***** pytho****@googl*****
2011年 11月 9日 (水) 19:21:39 JST


Revision: ca862c18d858
Author:   Naoki INADA  <inada****@klab*****>
Date:     Wed Nov  9 02:05:55 2011
Log:      Update 2.7.2: c-api/string
http://code.google.com/p/python-doc-ja/source/detail?r=ca862c18d858

Modified:
  /c-api/string.rst

=======================================
--- /c-api/string.rst	Wed Jun 15 15:57:42 2011
+++ /c-api/string.rst	Wed Nov  9 02:05:55 2011
@@ -65,13 +65,6 @@
     値とする Python 文字列にして返します。可変個の引数部は C のデータ型でな 
くてはならず、かつ *format* 文字列内の書式指定文字 (format
     character) に一致する型でなくてはなりません。利用できる書式化文字は以下 
の通りです:

-   .. % This should be exactly the same as the table in PyErr_Format.
-   .. % One should just refer to the other.
-   .. % The descriptions for %zd and %zu are wrong, but the truth is  
complicated
-   .. % because not all compilers support the %z width modifier -- we fake  
it
-   .. % when necessary via interpolating PY_FORMAT_SIZE_T.
-   .. % %u, %lu, %zu should have "new in Python 2.5" blurbs.
-
      
+--------------+---------------+----------------------------------------------+
     | 書式指定文字 | 型            | コメン 
ト                                     |
      
+==============+===============+==============================================+
@@ -86,6 +79,11 @@
     | :attr:`%ld`  | long          | C の ``printf("%ld")`` と全く同 
じ。          |
      
+--------------+---------------+----------------------------------------------+
     | :attr:`%lu`  | unsigned long | C の ``printf("%lu")`` と全く同 
じ。          |
+    
+--------------+---------------+----------------------------------------------+
+   | :attr:`%lld` | long long     | C の ``printf("%lld")`` と全く同 
じ。         |
+    
+--------------+---------------+----------------------------------------------+
+   | :attr:`%llu` | unsigned      | C の ``printf("%llu")`` と全く同 
じ。         |
+   |              | long long      
|                                              |
      
+--------------+---------------+----------------------------------------------+
     | :attr:`%zd`  | Py_ssize_t    | C の ``printf("%zd")`` と全く同 
じ。          |
      
+--------------+---------------+----------------------------------------------+
@@ -106,6 +104,14 @@

     識別できない書式指定文字があった場合、残りの書式文字列はそのまま出力文字 
列にコピーされ、残りの引数は無視されます。

+   .. note::
+
+      `"%lld"` と `"%llu"` 書式指定文字は :const:`HAVE_LONG_LONG`
+      が定義されている時だけ利用できます。
+
+   .. versionchanged:: 2.7
+      `"%lld"` と `"%llu"` のサポートが追加されました。
+

  .. c:function:: PyObject* PyString_FromFormatV(const char *format, va_list  
vargs)




Pythonjp-checkins メーリングリストの案内
Zurück zum Archiv-Index