Article View: pl.comp.lang.python
Article #28528Re: Definicje funkcji do modułów
From: Jordan Szubert
Date: Thu, 16 Apr 2015 12:44
Date: Thu, 16 Apr 2015 12:44
48 lines
1555 bytes
1555 bytes
Dnia 16-04-2015 o 12:37:20 <grizleyd@gmail.com> napisał(a):
> witam
> mam zbiór roznych modułów i chce z nich wyłuskać
> wszystkie definicje funkcji stały klas itp
>
> tak jak jest to w c++
> czy jest jakies narzedzie do tego ??
>
>
> z test.py chce otrzymac test_definicje.py
>
> np
>
> test.py
>
> def foo():
> print("aaa")
> def foo2():
> print("aaa")
> def foo3():
> print("aaa")
>
>
>
> test_definicje.py
>
>
> def foo()
> def foo2()
> def foo3()
>
>
> # i tak samo dla klas , stalych
jaki powinien byc wynik dla kodu:
import random
if random.random()<0.5:
def a(x,y):
pass
else:
class B(dict):
pass
--
Jordan Szubert
Technical Details
Message-ID:
<op.xw6q0vydhilul8@asus7h.home>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!agh.edu.pl!news.agh.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!goblin1!goblin.stu.neva.ru!newsfeed.neostrada.pl!unt-exc-02.news.neostrada.pl!unt-spo-a-01.news.neostrada.pl!news.neostrada.pl.POSTED!not-for-mailReferences:
<56b6d08e-a730-4997-a48c-ddff0309e295@googlegroups.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!agh.edu.pl!news.agh.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!goblin1!goblin.stu.neva.ru!newsfeed.neostrada.pl!unt-exc-02.news.neostrada.pl!unt-spo-a-01.news.neostrada.pl!news.neostrada.pl.POSTED!not-for-mail Newsgroups: pl.comp.lang.python Subject: Re: Definicje funkcji do modułów References: <56b6d08e-a730-4997-a48c-ddff0309e295@googlegroups.com> Date: Thu, 16 Apr 2015 14:44:45 +0200 MIME-Version: 1.0 From: "Jordan Szubert" <usenet@joru.us.to> Organization: HELL inc. Message-ID: <op.xw6q0vydhilul8@asus7h.home> User-Agent: Opera Mail/1.0 (Win32) Lines: 49 NNTP-Posting-Host: 83.22.29.23 X-Trace: 1429188286 unt-rea-a-01.news.neostrada.pl 2203 83.22.29.23:63870 X-Complaints-To: abuse@news.neostrada.pl Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit