Author Topic: classes viewer's bug!  (Read 5850 times)

admott

  • Guest
classes viewer's bug!
« on: October 18, 2006, 09:12:40 AM »
When I try to "Add Member Function ..." in the class viewer, it rise a error "invalid declaration". The function is a virtual destructor in C++.

When i try to add a destructor, like " ~PetriNet(void)", It also warns me "Destructor cannot have arguments".

Is this a bug of slickedit?

Graeme

  • Senior Community Member
  • Posts: 2793
  • Hero Points: 347
Re: classes viewer's bug!
« Reply #1 on: October 18, 2006, 11:42:12 AM »

Technically this is a bug in slickedit since the standard requires a destructor to have an empty parameter list and also says that (void) is equivalent to an empty parameter list (8.3.5/2).  The Comeau compiler, Visual C++ and GCC all accept (void) in a destructor.   Still it's very odd to write (void) in C++ so perhaps you could change your code to ()  - if there's not too many ?

Graeme

admott

  • Guest
Re: classes viewer's bug!
« Reply #2 on: October 19, 2006, 01:45:11 AM »
And what about the bug of virtual destructor ?

Graeme

  • Senior Community Member
  • Posts: 2793
  • Hero Points: 347
Re: classes viewer's bug!
« Reply #3 on: October 19, 2006, 02:30:33 AM »

Sorry, I didn't look at your .jpg.

It doesn't like destructors at all, with or without virtual.  You should report these problems to slickedit support via email.

Graeme

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 6826
  • Hero Points: 526
Re: classes viewer's bug!
« Reply #4 on: October 19, 2006, 06:01:56 PM »
Hey, you found a bug :-) The worst one is not supporting virtual.  The guy who wrote this must have been an OO moron.  Try not to laugh at me too hard :-) I'll take a look at these.