<div dir="ltr"><div><span style="font-size:13px">> First of all, Python is not a "he". Python is an "it".<br></span></div><div><span style="font-size:13px"><br></span></div><div><span style="font-size:13px">Thank you, </span>I will remember.</div><span style="font-size:13px"><div><br></div>> Seems very strange that Python checks ordinary blocks like 'if', 'else',<br>> 'def' statement and others..We could just have a big amount of tools to<br>> check this.<br><br></span><span style="font-size:13px">> So now you're arguing for Python to stop checking the Syntax of the</span><br style="font-size:13px"><span style="font-size:13px">> program for errors? I'm confused.</span><br><div><span style="font-size:13px"><br></span></div><div>I am just kidding.<br></div><div><br></div><div>Well, I understood.</div><div><br></div><div>Thank you all for your participation.<br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-02-10 23:12 GMT+02:00 Chris Barker <span dir="ltr"><<a href="mailto:chris.barker@noaa.gov" target="_blank">chris.barker@noaa.gov</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span class="">On Tue, Feb 10, 2015 at 11:53 AM, Eduard Bondarenko <span dir="ltr"><<a href="mailto:eduardbpy@gmail.com" target="_blank">eduardbpy@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Well, Perl also dynamic language, but except the usage of the additional analyser tools he provides 'use warning' directive and many Perl's developers use this feature.<div><br></div><div>Why you do not want to add such feature in Python ?</div></div></blockquote><div><br></div></span><div>I don't think anyone is saying that pre-run-time static analysis isn't useful.</div><div><br></div><div>And I'd bet that most of the folks on this list use some or all of the tools mentioned.</div><div><br></div><div>So the question is -- should some small subset of such analysis be built-in to the interpreter? -- and I. for one, don't think it should, at least at this point.</div><span class=""><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Seems very strange that Python checks ordinary blocks like 'if', 'else', 'def' statement and others..We could just have a big amount of tools to check this.</div></div></blockquote><div><br></div></span><div>Python checks syntax before it compiles (or while it compiles), because, well, it literally can't compile the code without correct syntax. It doesn't check things like names existing because those names could be created at run time.</div><div><br></div><div>If a line of code never runs during testing, then it can only be assumed to be incorrect.</div><div><br></div><div>If it does run during tests, then the really quick and easy stuff like mis-typed names will be caught right away. As there is no long compile-link step, there isn't much to be gained by the interpreter catching these things (that may not actually be errors) in the compile step.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>-Chris</div><div><br></div><div><br></div></font></span></div><span class="">-- <br><div><br>Christopher Barker, Ph.D.<br>Oceanographer<br><br>Emergency Response Division<br>NOAA/NOS/OR&R <a href="tel:%28206%29%20526-6959" value="+12065266959" target="_blank">(206) 526-6959</a> voice<br>7600 Sand Point Way NE <a href="tel:%28206%29%20526-6329" value="+12065266329" target="_blank">(206) 526-6329</a> fax<br>Seattle, WA 98115 <a href="tel:%28206%29%20526-6317" value="+12065266317" target="_blank">(206) 526-6317</a> main reception<br><br><a href="mailto:Chris.Barker@noaa.gov" target="_blank">Chris.Barker@noaa.gov</a></div>
</span></div></div>
</blockquote></div><br></div>