@@ -716,7 +716,7 @@ private function hSetupProc _
716716
717717 '' ctor/dtor?
718718 if ( (pattrib and (FB_PROCATTRIB_CONSTRUCTOR or _
719- FB_PROCATTRIB_DESTRUCTOR )) <> 0 ) then
719+ FB_PROCATTRIB_DESTRUCTOR1 or FB_PROCATTRIB_DESTRUCTOR0 )) <> 0 ) then
720720
721721 assert( pattrib and FB_PROCATTRIB_METHOD )
722722
@@ -748,7 +748,7 @@ private function hSetupProc _
748748 '' otherwise, try to overload
749749 else
750750 '' dtor?
751- if ( (pattrib and FB_PROCATTRIB_DESTRUCTOR ) <> 0 ) then
751+ if ( (pattrib and (FB_PROCATTRIB_DESTRUCTOR1 or FB_PROCATTRIB_DESTRUCTOR0) ) <> 0 ) then
752752 '' can't overload
753753 return NULL
754754 end if
@@ -920,8 +920,8 @@ add_proc:
920920 overridden = NULL
921921 if ( parent->udt.base ) then
922922 '' Destructor?
923- if ( symbIsDestructor ( proc ) ) then
924- '' There can always only be one, so there is no
923+ if ( symbIsDestructor1 ( proc ) ) then
924+ '' There can always only be one complete dtor , so there is no
925925 '' need to do a lookup and/or overload checks.
926926 overridden = symbGetCompDtor( parent->udt.base->subtype )
927927 elseif ( symbIsOperator( proc ) ) then
@@ -1601,7 +1601,7 @@ function symbFindCtorProc _
16011601 ) as FBSYMBOL ptr
16021602
16031603 '' dtor? can't overload..
1604- if ( symbIsDestructor ( ovl_head_proc ) ) then
1604+ if ( symbIsDestructor1 ( ovl_head_proc ) ) then
16051605 return ovl_head_proc
16061606 else
16071607 return symbFindOverloadProc( ovl_head_proc, proc )
@@ -2845,7 +2845,7 @@ sub symbProcCheckOverridden _
28452845 '' implicit dtors and LET overloads. Since they
28462846 '' are not visible in the original code,
28472847 '' the error message must have more info.
2848- if ( symbIsDestructor ( proc ) ) then
2848+ if ( symbIsDestructor1 ( proc ) ) then
28492849 errmsg = FB_ERRMSG_IMPLICITDTOROVERRIDECALLCONVDIFFERS
28502850 else
28512851 errmsg = FB_ERRMSG_IMPLICITLETOVERRIDECALLCONVDIFFERS
@@ -2916,7 +2916,7 @@ end sub
29162916'' Append calling convention, if it differs from the default
29172917private sub hProcModeToStr( byref s as string , byval proc as FBSYMBOL ptr )
29182918 '' Ctors/Dtors currently always default to CDECL, see cProcHeader()
2919- if ( symbIsConstructor( proc ) or symbIsDestructor ( proc ) ) then
2919+ if ( symbIsConstructor( proc ) or symbIsDestructor1( proc ) or symbIsDestructor0 ( proc ) ) then
29202920 select case ( symbGetProcMode( proc ) )
29212921 case FB_FUNCMODE_STDCALL, FB_FUNCMODE_STDCALL_MS
29222922 s += " stdcall"
@@ -3045,7 +3045,9 @@ function symbGetFullProcName( byval proc as FBSYMBOL ptr ) as zstring ptr
30453045
30463046 if ( symbIsConstructor( proc ) ) then
30473047 res += "constructor"
3048- elseif ( symbIsDestructor( proc ) ) then
3048+ elseif ( symbIsDestructor1( proc ) ) then
3049+ res += "destructor"
3050+ elseif ( symbIsDestructor0( proc ) ) then
30493051 res += "destructor"
30503052 elseif ( symbIsOperator( proc ) ) then
30513053 res += "operator."
0 commit comments