I only base my expectation on the fact that D is an open source language maintained by a community that comes from many other areas of programming, has a tendency to respond to user feedback, and generally seems to do it's best to cherry pick the best bits from virtually every other language I can think of. I'm just surprised this isn't constantly requested, and I see no harm in adding it.<div>
I'm sure an unambiguous syntax can be invented (although I don't like the current proposal using EVEN MORE parentheses)... D has a bit of an obsession with parenthesis... ;)<br><br>Regardless, I'd like to put a strong +1 towards proper multiple return values. The point is NOT just to have the syntactical feature (ie. struct return value semantics via tuples). The point is a language guarantee that the architecture will do its best job to return each value in consecutive registers OF ITS OWN TYPE, avoiding allocation&writing to the stack. This is a common problem in C where the only solution is to make functions inline or pay the cost of hitting the stack (LHS hazard, very expensive on many RISC architectures).<div>
It would lead to many optimisations in lots of code in my experience.<br><br><div class="gmail_quote">On 4 January 2012 05:46, Jonathan M Davis <span dir="ltr"><<a href="mailto:jmdavisProg@gmx.com">jmdavisProg@gmx.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Tuesday, January 03, 2012 19:48:53 bearophile wrote:<br>
> Jonathan M Davis:<br>
> > I'm not saying anything about the value of the feature. I'm just saying<br>
> > that given D's lineage, it's not at all suprising that it doesn't<br>
> > support multiple return values. In fact, it would be very abnormal if<br>
> > it did. The OP seems to expect that modern languages would support such<br>
> > a feature, whereas many do not - particularly the C-based ones.<br>
><br>
> OK.<br>
> For fun here is a slightly modified version of your text:<br>
><br>
> "I'm not saying anything about the value of the feature. I'm just saying<br>
> that given D's lineage, it's not at all suprising that it doesn't support<br>
> nested functions. In fact, it would be very abnormal if it did. The OP<br>
> seems to expect that modern languages would support such a feature, whereas<br>
> many do not - particularly the C-based ones."<br>
> :-)<br>
<br>
</div></div>Well, yeah. Having nested functions in C-based languages is not normal, and I<br>
don't believe that most other "modern" languages have them either, so it's<br>
arguably unreasonable to _expect_ that D would have nested functions, because<br>
it's a modern language. That doesn't mean that it _won't_ have nested<br>
functions (or multiple return values), but _expecting_ that it will simply<br>
because it's a modern programming language is arguably unreasonable.<br>
<span class="HOEnZb"><font color="#888888"><br>
- Jonathan M Davis<br>
</font></span></blockquote></div><br></div></div>