Equivalent to nullptr

Leonardo via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Wed May 3 20:59:36 PDT 2017


On Thursday, 4 May 2017 at 02:45:30 UTC, Adam D. Ruppe wrote:
> On Thursday, 4 May 2017 at 02:12:13 UTC, Leonardo wrote:
>> nullptr word. How I use this?
>
> Does it work if you just use `null` ?

No.

First I got: source/app.d(45,69): Error: expression 
(*SDL_EnclosePoints)(& mousePos, 1, &ball.bbox, null) of type 
void does not have a boolean value

then I change to:
   event.button.button == SDL_BUTTON_LEFT && SDL_TRUE == 
SDL_EnclosePoints(&mousePos, 1,  &ball.bbox, null)

and got:
source/app.d(45,81): Error: void has no value
source/app.d(45,52): Error: incompatible types for ((SDL_TRUE) == 
((*SDL_EnclosePoints)(& mousePos, 1, &ball.bbox, null))): 'int' 
and 'void'



More information about the Digitalmars-d-learn mailing list