Recent

Author Topic: free pascal  (Read 218 times)

Andrei14

  • Newbie
  • Posts: 1
free pascal
« on: August 26, 2019, 03:55:41 pm »
Hello! Who knows what type of error is this?
Any help will be appreciated! Thanks!

source.pas(12,5) Error: Incompatible types: got "Boolean" expected "Int64"
source.pas(15) Fatal: There were 1 errors compiling module, stopping
Error: /usr/bin/ppcx64 returned an error exitcode

af0815

  • Sr. Member
  • ****
  • Posts: 347
Re: free pascal
« Reply #1 on: August 26, 2019, 03:57:46 pm »
you hava a variable with the type Boolean, but the compiler is wanting a Int64. If you show some code it will be more clear.
regards
Andreas

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 5631
    • wiki
Re: free pascal
« Reply #2 on: August 26, 2019, 04:37:50 pm »
Most likely operator precedence in a bool expression

This code
Code: Pascal  [Select]
  1. if Int1 = int2 and int3 = int4
needs to be
Code: Pascal  [Select]
  1. if (Int1 = int2) and (int3 = int4)
« Last Edit: August 26, 2019, 04:40:12 pm by Martin_fr »