From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,8671579c9eb8548d,start X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!postnews.google.com!z14g2000cwz.googlegroups.com!not-for-mail From: "R" Newsgroups: comp.lang.ada Subject: circular unit dependency Date: 4 Jan 2005 10:31:38 -0800 Organization: http://groups.google.com Message-ID: <1104863498.813484.201360@z14g2000cwz.googlegroups.com> NNTP-Posting-Host: 83.238.46.94 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: posting.google.com 1104863506 9576 127.0.0.1 (4 Jan 2005 18:31:46 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 4 Jan 2005 18:31:46 +0000 (UTC) User-Agent: G2/0.2 Complaints-To: groups-abuse@google.com Injection-Info: z14g2000cwz.googlegroups.com; posting-host=83.238.46.94; posting-account=vW-V7A0AAADVHjc0FRFWzwhUHLUBcq4I Xref: g2news1.google.com comp.lang.ada:7436 Date: 2005-01-04T10:31:38-08:00 List-Id: Hello everybody. I've got a problem with circular unit dependency. In main package I have: with base; with base.derv1; with base.derv2; derv1 has tagged record rec1 and derv2 has its rec2 the derv1 and derv2 packages have overritten operator "+" which spec look like this: in derv1 package spec and body I have: with base.derv2; -- info about rec2 needed in "+" spec ... function "+"(left: rec1; right: base.derv2.rec2) return rec1; and the same thing with the second package spec and body: with base.derv1; -- info about rec1 needed in "+"'s spec ... function "+"(left: rec2; right: base.derv1.rec1) return rec2; when I compile it with gcc i have: main.adb:8:06: circular unit dependency main.adb:8:06: "Main (body)" depends on "base.derv1 (spec)" main.adb:8:06: "base.derv1 (spec)" depends on "base.derv2 (spec)" main.adb:8:06: "base.derv2 (spec)" depends on "base.derv1 (spec)" main.adb:8:06: "base.derv1 (spec)" depends on "base.derv1 (body)" main.adb:8:06: "base.derv1 (body)" depends on "base.derv1 (spec)" main.adb:8:06: "base.derv1 (spec)" depends on "base.derv1 (spec)" well - I need info about other record because it's the parameter of both function"+" any idea? I tried to remove 'with' statement but then I received msgs like: "xxx" not declared in "yyy" thanks in advance best regards R