<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1256">
</head>
<body>
<div>
<div style="font-size:11pt; font-family:Calibri,sans-serif">So is exec(tokenize.open(file).read()) the actual replacement for execfile()? Not too bad, but still not obvious (or widely promoted - I'd never heard of it).<br>
<br>
Top-posted from my Windows Phone</div>
</div>
<div dir="ltr">
<hr>
<span style="font-size:11pt; font-family:Calibri,sans-serif; font-weight:bold">From:
</span><span style="font-size:11pt; font-family:Calibri,sans-serif"><a href="mailto:ncoghlan@gmail.com">Nick Coghlan</a></span><br>
<span style="font-size:11pt; font-family:Calibri,sans-serif; font-weight:bold">Sent:
</span><span style="font-size:11pt; font-family:Calibri,sans-serif">ý6/ý14/ý2014 18:31</span><br>
<span style="font-size:11pt; font-family:Calibri,sans-serif; font-weight:bold">To:
</span><span style="font-size:11pt; font-family:Calibri,sans-serif"><a href="mailto:Steve.Dower@microsoft.com">Steve Dower</a></span><br>
<span style="font-size:11pt; font-family:Calibri,sans-serif; font-weight:bold">Cc:
</span><span style="font-size:11pt; font-family:Calibri,sans-serif"><a href="mailto:greg.ewing@canterbury.ac.nz">Greg Ewing</a>;
<a href="mailto:python-dev@python.org">python-dev@python.org</a></span><br>
<span style="font-size:11pt; font-family:Calibri,sans-serif; font-weight:bold">Subject:
</span><span style="font-size:11pt; font-family:Calibri,sans-serif">Re: [Python-Dev] Criticism of execfile() removal in Python3</span><br>
<br>
</div>
<div>
<p dir="ltr"><br>
On 15 Jun 2014 09:37, "Steve Dower" <<a href="mailto:Steve.Dower@microsoft.com">Steve.Dower@microsoft.com</a>> wrote:<br>
><br>
> I think the point is that the encoding may be embedded in the file as a coding comment and there's no obvious way to deal with that.</p>
<p dir="ltr">Opening source files correctly is the intended use case for tokenize.open().</p>
<p dir="ltr">Cheers,<br>
Nick.</p>
</div>
</body>
</html>