Compiler trap in Real64 op ADR(x)

Re: Compiler trap in Real64 op ADR(x)

Postby Robert » Wed Jul 29, 2020 8:39 am

adimetrius wrote:P.S. It seems I can't post at the other discussion page

No!

The policy is described here: https://wiki.blackboxframework.org/inde ... tin_Boards .
User avatar
Robert
 
Posts: 159
Joined: Sat Sep 28, 2013 11:04 am
Location: Edinburgh, Scotland

Re: Compiler trap in Real64 op ADR(x)

Postby Josef Templ » Mon Aug 03, 2020 7:46 am

a bug fix as proposed by adimetrius has been prepared for the center version.

Thanks for the careful analysis and bug fix proposal.

- Josef
Josef Templ
 
Posts: 255
Joined: Tue Sep 17, 2013 6:50 am

Re: Compiler trap in Real64 op ADR(x)

Postby Josef Templ » Wed Oct 14, 2020 9:29 am

adimetrius wrote:For a permanent correction, why not amend CheckForm?

It would be the most 'straight' logic: CheckForm checks that the format of data is correct. It is correct to convert a Pointer to a Real64, and that't what CheckForm should return. Amending other procedures looks as a workaround to me.
Code: Select all
   PROCEDURE CheckForm (form: BYTE; VAR mf: INTEGER);
   BEGIN
      IF form = Real32 THEN mf := 0
      ELSIF form = Real64 THEN mf := 4
      ELSIF form = Int32 THEN mf := 2
      ELSIF form = Pointer THEN mf := 2       (* this is the addition *)
      ELSE ASSERT(form = Int16); mf := 6
      END
   END CheckForm;


P.S. It seems I can't post at the other discussion page


@adimetrius
Are you still convinced that CheckForm is the best place for the fix?
I am asking because we had some discussion in the center about the best place for the fix.
To me it looks very plausible but I want to make sure that the original author of the proposal still supports it.

- Josef
Josef Templ
 
Posts: 255
Joined: Tue Sep 17, 2013 6:50 am

Re: Compiler trap in Real64 op ADR(x)

Postby adimetrius » Thu Oct 15, 2020 8:37 am

Yes, I still believe CheckForm would be the most natural place for the fix.
User avatar
adimetrius
 
Posts: 34
Joined: Sun Aug 04, 2019 1:02 pm

Previous

Return to Bug

Who is online

Users browsing this forum: No registered users and 1 guest

cron