Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#81 closed bug (fixed)

Build problem - code error?

Reported by: katisu@… Owned by: axeld
Priority: normal Milestone: R1
Component: - General Version:
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All


C++ generated/objects/haiku/x86/release/kits/tracker/GroupedMenu.o /boot/home/haiku/trunk/src/kits/tracker/GroupedMenu.cpp: In method `class BMenuItem * BPrivate::TMenuItemGroup::RemoveItem(long int)': /boot/home/haiku/trunk/src/kits/tracker/GroupedMenu.cpp:122: return to BMenuItem *' from bool' ...failed C++ generated/objects/haiku/x86/release/kits/tracker/ GroupedMenu.o ...

The code is:

BMenuItem * TMenuItemGroup::RemoveItem(int32 index) {

BMenuItem *item = ItemAt(index); if (item == NULL)

return false;

if (RemoveItem(item))

return item;

return NULL;


I'm still trying to get my programming skills up to task and understand the current structure. But it would seem the first return should be NULL.

Change History (4)

comment:1 by axeld, 14 years ago

Status: newclosed

comment:2 by axeld, 14 years ago

Even though "false" and "NULL" should be converted to the same numerical value, you're absolutely right. Strange that it failed for you, though.

comment:3 by axeld, 14 years ago

Resolution: fixed

comment:4 by katisu@…, 14 years ago

Thought I had installed latest gcc - turns out I only had 2.9-beos-991026 Sorry for the confusion.

Note: See TracTickets for help on using tickets.