FLTK native in 'D'. Would that be useful?

Lars Ivar Igesund larsivar at igesund.net
Sun Aug 13 10:21:51 PDT 2006


MatthiasM wrote:

> Carlos Santander wrote:
>> I still get a bus error when pressing Command-Q with rev 5297 (both
>> hello and button):
> 
> Thanks. This should be fixed now.
> 
> I can't get used to the fact that in "D", you can't compare pointers if
> one of them may be null:
> 
> class Fl_Window {
>    ...
> };
> Fl_Window first_window, this_window;
> if (first_window==this_window) ...
> 
> Now if first_window is null, I get a crash that I would not get in C++.
> Ah well ;-)

Heh, well, == is for value comparison (and is implemented (for objects) like
foo.equals(bar)), is for pointers :)

if (foo is null)

-- 
Lars Ivar Igesund
blog at http://larsivi.net
DSource & #D: larsivi



More information about the Digitalmars-d-dwt mailing list