[fbcocoa] Re: [fbcocoa] Translation Help - Minus Sign?

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : October 2010 : Group Archive : Group : All Groups

From: Bernie <fbcocoa.bw@...>
Date: Fri, 1 Oct 2010 11:45:28 +0100
On 1 Oct 2010, at 11:13, Deep wrote:

> 
> Take following FB syntax:
> 
>  dim X as UniChar
>  long if ( X > 0 ) and ( X < 100 )
>  ...
>  end if
> 
> 
> The FBtoC translator produces:
> 
>  UniChar X;
>  if ( (-(X > 0)) & ( -(X < 100) )  )
>  {
>  ...
>  }
> 
> 
> Could somebody please explain the "-" minus sign in this situation? Or
> should it simply be amended by hand to say:
> 
>  UniChar X;
>  if ( ( X > 0 ) && ( X < 100 ) )
>  {
>  ...
>  }
> 
> 
> Have read about ObjectiveC and the "methods" which is denoted using the "-"
> minus sign but cannot understand the meaning in the above line? Do not fully
> understand ObjectiveC syntax as yet, but this minus sign is really
> confusing.
> 
> Any hints would be appreciated.
> 

I suspect the minus signs are inserted by FBtoC (maybe Michele or RP will explain). They are nothing to do with Objective-C.

Bernie