And here&#39;s another reason to use new-style:&nbsp; I forgot the sauerkraut!&nbsp; Oh, the horror!<br><br><div class="gmail_quote">On Nov 15, 2007 1:42 PM, Marc Tompkins &lt;<a href="mailto:marc.tompkins@gmail.com">marc.tompkins@gmail.com
</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">I thought of an analogy I like better than my sign-painting one: ordering a sandwich.&nbsp; 
<br>Imagine: you&#39;re at the deli, and your waitron asks what you want.&nbsp; (Granted, this is a silly example.)<br>&nbsp; &quot;Classic&quot; order: &quot;I&#39;d like a sandwich with two slices of rye bread, Russian dressing, corned beef, and Swiss cheese.&nbsp; Oh, and I&#39;d like that grilled.&quot;&nbsp; 
<br>&nbsp; &quot;New-style&quot; order: &quot;Reuben, please.&quot;<br><br>Now, I speak not of the time and materials required to construct the above-mentioned tasty treat - in my analogy, Python is the long-suffering waitron, not the cook - but I gotta figure that the second option will take less space to write on the check.&nbsp; Perhaps about 134 bytes&#39; worth.
<br><br>For some reason I&#39;m hungry now...<div><div></div><div class="Wj3C7c"><br><br><div class="gmail_quote">On Nov 15, 2007 11:22 AM, Kent Johnson &lt;<a href="mailto:kent37@tds.net" target="_blank">kent37@tds.net</a>
&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>Marc Tompkins wrote:<br>&gt; I didn&#39;t mean that exactly literally - for goodness&#39; sake, this is a<br>&gt; high-level, object-oriented, interpreted language! &nbsp;We&#39;re not writing<br>&gt; machine language here.
<br><br></div>Yes, I was thinking I should re-word my email, it was worded a bit too<br>strongly...<br><div><br>&gt; What I did mean, and will probably still not express as clearly as I&#39;d<br>&gt; like, is that when you create a &quot;classic&quot; class, lots of options remain
<br>&gt; unresolved - slots vs. dict comes to mind - and Python needs to reserve<br>&gt; extra space accordingly. &nbsp; About 134 extra bytes, it would appear.<br><br></div>Still not sure I know what you mean. AFAIK old-style classes don&#39;t
<br>support slots, at least not user-defined slots. I do remember talk of<br>new-style classes and properties allowing a much cleaner implementation<br>of the class mechanisms, and it seems plausible that such generalization
<br>would lead to fewer options and streamlining of the class structure, but<br>I don&#39;t know enough about the specifics to know if that is right.<br><br>I poked around a bit in the source to see if I could figure it out but
<br>got tired of trying to sift through the header files...<br><br>Kent<br><div>&gt;<br>&gt; On Nov 15, 2007 9:32 AM, Kent Johnson &lt;<a href="mailto:kent37@tds.net" target="_blank">kent37@tds.net</a><br></div><div>
&gt; &lt;mailto:<a href="mailto:kent37@tds.net" target="_blank">kent37@tds.net</a>&gt;&gt; wrote:<br>&gt;<br>&gt; &nbsp; &nbsp; Marc Tompkins wrote:<br>&gt;<br>&gt; &nbsp; &nbsp; &nbsp;&gt; class B is a &quot;new-style&#39; class, meaning that it inherits from a base,
<br>&gt; &nbsp; &nbsp; &nbsp;&gt; pre-existing class (in this case &quot;object&quot;, which is as basic and<br>&gt; &nbsp; &nbsp; generic<br>&gt; &nbsp; &nbsp; &nbsp;&gt; as you can get!). &nbsp;class A has to start from nothing, which is why it<br>&gt; &nbsp; &nbsp; &nbsp;&gt; consumes more memory yet has less functionality.
<br>&gt;<br>&gt; &nbsp; &nbsp; I don&#39;t think it is really accurate to say that an old-style class<br>&gt; &nbsp; &nbsp; &quot;starts from nothing&quot;. It doesn&#39;t have an explicit base class but it<br>&gt; &nbsp; &nbsp; does have all the old-style class machinery which is built in to Python.
<br>&gt;<br>&gt; &nbsp; &nbsp; I don&#39;t know why new-style classes are smaller though. My guess is that<br>&gt; &nbsp; &nbsp; it is because there was an opportunity to streamline the class structure<br>&gt; &nbsp; &nbsp; based on experience.<br>&gt;
<br>&gt; &nbsp; &nbsp; Kent<br>&gt;<br>&gt;<br>&gt;<br>&gt;<br>&gt; --<br></div>&gt; <a href="http://www.fsrtechnologies.com" target="_blank">www.fsrtechnologies.com</a> &lt;<a href="http://www.fsrtechnologies.com" target="_blank">

http://www.fsrtechnologies.com</a>&gt;<br><br></blockquote></div><br><br clear="all"><br></div></div><font color="#888888">-- <br><a href="http://www.fsrtechnologies.com" target="_blank">www.fsrtechnologies.com</a>
</font></blockquote></div><br><br clear="all"><br>-- <br><a href="http://www.fsrtechnologies.com">www.fsrtechnologies.com</a>