On 25/08/07, <b class="gmail_sendername">Jeff Rogers</b> <<a href="mailto:dvrsn@diphi.com">dvrsn@diphi.com</a>> wrote:<div><span class="gmail_quote"></span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Mats Cronqvist wrote:<br>> On 2007-08-16 10:52, Joe Armstrong wrote:<br>>> [...]<br>>> (Actually we dont use ? any more so we could say A ? B instead of A !! B<br>>> this might be even better - it saves one character and the ? clearly
<br>>> indicates the intent)<br>><br>> if only... but as far as i know '?' is munched by the preprocessor.<br>><br>> also, i think that if anything '?' should be used instead of<br>
> 'receive' (the way God, or at least Tony Hoare, intended).<br>><br>> mats<br><br>Could a parse transform recognize the case where the value A ! B is not<br>discarded and change those cases into some kind of synchronous call? So
<br>that<br><br>A = spawn(...),<br>A ! whatever,<br>ok.<br><br>is a async call but<br><br>A = spawn(...),<br>B = A ! whatever,<br>B.<br><br>is a synchronous call. The return value of ! is normally just the value<br>that was sent, which doesn't seem very useful. The only places where it
<br>would not be immediately evident if the return value is ignored is when<br>a function or Fun evaluates to a send. Even so, ! normally looks like<br>an imperative operator more than a functional one so this seems to make
<br>it more functional (but also lazy in some respects, which is<br>anti-erlang/soft-rt)</blockquote><div><br>That would result in forcing people to write some really weird code. I could never for example just end a function with a normal async send as that would be interpreted as sync send.
<br><br>Generally the idea of having the semantics of something change depending on what comes after seems a little off.<br><br>Robert <br></div><br></div><br>