[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Using "return" values or "out" arguments

From: Duke Normandin
Subject: Using "return" values or "out" arguments
Date: Sun, 4 Mar 2012 14:49:56 -0700


it says that Sather forces the use of return values, i.e. something
like the following needs to exist:

blah := some_method() + 4;

Yet, down the page a bit, the "divide" function is declared, and
simply "called" to load up the "div" and "rem" variables.

divide(a,b,out div, out rem);

So, am I to understand that an *out* argument in a function, is a
way to get around *having* to use use an explicit "return"
value/statement? Any benefit to doing this way, rather than
following the Sather "return a value and use it" discipline?


reply via email to

[Prev in Thread] Current Thread [Next in Thread]