<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 3, 2016 at 9:38 AM, Richard Purdie <span dir="ltr">&lt;<a href="mailto:richard.purdie@linuxfoundation.org" target="_blank">richard.purdie@linuxfoundation.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Wed, 2016-02-03 at 09:29 -0700, Christopher Larson wrote:<br>
&gt; &gt;  The actual getVar syntax on the other handy is more than cosmetic,<br>
&gt; &gt; people don&#39;t understand what this &quot;True&quot; they keep adding means, or<br>
&gt; &gt; why<br>
&gt; &gt; they need it. You tend to know when you don&#39;t want expansion on the<br>
&gt; &gt; other hand. So a cleaner syntax which does what the user most<br>
&gt; &gt; likely<br>
&gt; &gt; needs is more than cosmetic.<br>
&gt; I&#39;d agree with that, passing booleans as arguments sucks all around,<br>
&gt; since it loses context. *If* someone is going to do it, it&#39;s best to<br>
&gt; pass it with the argument name in keyword form in the caller, and<br>
&gt; obviously we don&#39;t want to do that here.<br>
&gt;<br>
&gt; That said, I&#39;m rather inclined toward thinking about alternative<br>
&gt; DataSmart APIs in general, in the long term. For example, it&#39;s a<br>
&gt; MutableMapping, so it acts dict-like, so we should be able to use<br>
&gt; .get() and get an expanded value, and then the case would line up<br>
&gt; with PEP8 (CamelCase for functions is frowned upon). I.e. we could<br>
&gt; have get() and get_unexpanded().<br>
<br>
</span>I&#39;m just thinking out loud here, I think the above is worth seriously<br>
considering. One big advantage &quot;getVar&quot; has is that its pretty unique<br>
and the python parsing code therefore doesn&#39;t get a lot of false<br>
positives with function names. &quot;get&quot; on the other hand, I can see being<br>
a nightmare.</blockquote></div><br></div><div class="gmail_extra">That&#39;s a good point, I&#39;ll admit I didn&#39;t think about the codeparsing in that regard. I wonder how much work it&#39;d be to track what variable(s) hold DataSmart instances.. we know &#39;d&#39; starts that way, that&#39;s an assumption we can make, but it wouldn&#39;t traverse createCopy().. *Ponders*<br>-- <br><div class="gmail_signature">Christopher Larson<br>clarson at kergoth dot com<br>Founder - BitBake, OpenEmbedded, OpenZaurus<br>Maintainer - Tslib<br>Senior Software Engineer, Mentor Graphics</div>
</div></div>