Can anyone reproduce this ISSUE?
Using version 24.3.1 (or earlier version).
APPEARS TO BE A BUG WITH TYPE objects having both SPEC and BODY.
Consistently reproducible following these steps.
Compile both TYPE Spec, and TYPE BODY using the script at bottom..
Refresh the TYPES node in object tree to see the new type UTBUG.
Open type UTBUG Spec in worksheet, review the code, then CLOSE worksheet.
Open type UTBUG Body in worksheet and RECOMPILE the BODY.
REVIEW the SCRIPT OUTPUT tab showing BODY compiled successfully, followed by ERROR(s) PLS-00201, PLS-00304.
***RECOMPILE SCRIPT OUTPUT ***
Type Body BUGTYPE compiled
***IMMEDIATELY FOLLOWED BY***
LINE/COL ERROR
--------- -------------------------------------------------------------
0/0 PL/SQL: Compilation unit analysis terminated
1/11 PLS-00201: identifier 'BUGTYPE' must be declared
1/11 PLS-00304: cannot compile body of 'BUGTYPE' without its specification
Errors: check compiler log
*** SCRIPT ***
CREATE OR REPLACE EDITIONABLE TYPE BUGTYPE
authid current_user
as object
(
label varchar2(4000 char)
, constructor function bugtype(self in out nocopy bugtype
, v\_label\_in in varchar2) return self as result
)
/
CREATE OR REPLACE EDITIONABLE TYPE BODY BUGTYPE
AS
constructor function bugtype(self in out nocopy bugtype
, v\_label\_in in varchar2) return self as result
is
begin
label := v\_label\_in;
return;
end;
end;
/
*** Initial compilation for both Spec and Body are successful. ***
Type BUGTYPE compiled
Type Body BUGTYPE compiled