Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
acc802b1
Kaydet (Commit)
acc802b1
authored
Şub 05, 2009
tarafından
Georg Brandl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
#5144: document that PySys_SetArgv prepends the script directory (or the empty string) to sys.path.
üst
174fbe77
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
7 deletions
+11
-7
init.rst
Doc/c-api/init.rst
+11
-7
No files found.
Doc/c-api/init.rst
Dosyayı görüntüle @
acc802b1
...
@@ -353,13 +353,17 @@ Initialization, Finalization, and Threads
...
@@ -353,13 +353,17 @@ Initialization, Finalization, and Threads
single: Py_FatalError()
single: Py_FatalError()
single: argv (in module sys)
single: argv (in module sys)
Set ``sys.argv`` based on *argc* and *argv*. These parameters are similar to
Set :data:`sys.argv` based on *argc* and *argv*. These parameters are
those passed to the program's :cfunc:`main` function with the difference that
similar to those passed to the program's :cfunc:`main` function with the
the first entry should refer to the script file to be executed rather than the
difference that the first entry should refer to the script file to be
executable hosting the Python interpreter. If there isn't a script that will be
executed rather than the executable hosting the Python interpreter. If there
run, the first entry in *argv* can be an empty string. If this function fails
isn't a script that will be run, the first entry in *argv* can be an empty
to initialize ``sys.argv``, a fatal condition is signalled using
string. If this function fails to initialize :data:`sys.argv`, a fatal
:cfunc:`Py_FatalError`.
condition is signalled using :cfunc:`Py_FatalError`.
This function also prepends the executed script's path to :data:`sys.path`.
If no script is executed (in the case of calling ``python -c`` or just the
interactive interpreter), the empty string is used instead.
.. XXX impl. doesn't seem consistent in allowing 0/NULL for the params;
.. XXX impl. doesn't seem consistent in allowing 0/NULL for the params;
check w/ Guido.
check w/ Guido.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment