[7696] in Athena Bugs

home help back first fref pref prev next nref lref last post

bug in cfront 2.0 wrt constructors and structure passing

daemon@ATHENA.MIT.EDU (Ken Raeburn)
Wed Jun 26 22:59:25 1991

Date: Wed, 26 Jun 91 22:59:19 -0400
From: Ken Raeburn <Raeburn@MIT.EDU>
To: bugs@ATHENA.MIT.EDU
Cc: eichin@ATHENA.MIT.EDU

When cfront runs over ~raeburn/compiler-bugs/cfront/align.c, the code
it generates is incorrect.  In the routine
   AlignCmd::GetReference(GraphicComp*)
or
   GetReference__8AlignCmdFP11GraphicComp
the call to the Iterator constructor returns a pointer to an Iterator,
which is then passed to Clipboard::GetComp.  However, that routine
wants an Iterator as an argument, not an Iterator*.  The C++ code is
correct in that respect; the code generated by cfront is not.

This happens with both the vax and RT versions.  Because I set the
default for cfront on the RT to ANSI mode, this gets caught by hc; the
non-ANSI code on the vax will not cause a compiler warning, but it
will not function properly.

I've compressed the files in that directory to save a little space.
Please let me know when they can be deleted.

Ken

P.S.  Ezra -- when you file a report with AT&T, be sure to ask for a
patch for cfront 2.0.  Their fixing it in future versions won't help
us until we get a new license.

home help back first fref pref prev next nref lref last post