Re: [Vala] Math.exp2 not portable



On Wed, Jan 30, 2008 at 09:48:11PM +0100, J?rg Billeter wrote:
On Wed, 2008-01-23 at 11:10 +0100, pancake wrote:
But the reality is another:

 http://www.gnu.org/software/gnulib/manual/html_node/exp2.html

We don't guarantee that all functionality provided in Vala bindings is
available on all platforms. exp2 is a standard C function, I don't see
an issue in keeping it in the bindings, it's hardly an exotic function.

it's only a GNU standard. btw i'm thinking about the possibility to mark
some methods as deprecated with an associated explanatory string.

This would be nice to develop, so you can mark a method as deprecated, and
all the times you call it the compiler will show you the 'error message':

[Deprecated (reason="foo() method has been deprecated, please use bar()")]
public void foo() {
        ...
}


or something like that :) what do you think?

it has nothing to do with the exp2 problem, but maybe we should warn or alias
exp2(x) as pow(2,x) that performs the same operation...so a tip like that can
be added into the vapi as [Deprecated] or [Tip] or whatever else, to let this
decission relay on the developer.

--pancake



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