Questions tagged [freepascal]

Free Pascal is a multi-dialect, multi-platform Object Pascal compiler. Originally started to replace the retired Turbo Pascal compiler, it now attempts to follow the Delphi dialect still being developed by Embarcadero Technologies. It has compiler modes for Delphi, Turbo Pascal and Mac Pascal. It also has two modes for its own superset dialect: One mode with exceptions, classes and interfaces, and mode one without.

Free Pascal is a multi-dialect, multi-platform Object Pascal compiler. Its main focus are the Delphi and Turbo Pascal dialect, but a substantial Mac Pascal subset and a minor ISO Pascal mode exist as well.

Free Pascal is available for most common architectures and operating systems.

http://www.freepascal.org

1338 questions
-3
votes
1 answer

How to add ASCI Char in TStringGrid Cells

I'm not expert in Delphi and I'm trying to add "Extended ASCII String" broken into individual character and then add into the TSgringGrid.Cells[x,y]. Some of the characters are getting displayed but rest of the characters are not shown in these…
-3
votes
2 answers

"Data element too large" error when compiling+assembling with fpc (on OSX)

How can I troubleshoot and fix a fatal Data element too large error when compiling and assembling with fpc (Free Pascal compiler) in a 64-bit Mac/OSX environment? It seems that the cause of the error is probably an array[0..MaxInt] call (see below…
sideshowbarker
  • 81,827
  • 26
  • 193
  • 197
-3
votes
1 answer

Rabin Karp Algorithm in pascal

Can someone give me a source code for a function - Rabin Karp algorithm - in pascal (free pascal version)?
-3
votes
1 answer

Boolean operators precedence in Pascal

I have some problems understanding some Pascal boolean expressions, and don't understand how chained or / and work. Why does False or True and True = True? Why does False or True and True or False = True? As I can see it evaluates them from the…
Matei
  • 1,783
  • 1
  • 14
  • 17
-4
votes
1 answer

Why my pascal program exited with Error 207

I'm trying to make a program to find the determinant of a matrix like this : program determinan; uses crt; type arr=array of array of real; var mat:arr; uk:byte; procedure ukuran(var x:arr;var n:byte); begin …
syh
  • 7
  • 1
-4
votes
1 answer

Can't use break statement. Illegal expression error

In my for loop I used break statement to break loop after some match. But when I compile my code I got error for break: Error: Illegal expression Could you help me? I should add some unit? for i:=0 to length(carsList)-1 do begin …
Mlody87
  • 425
  • 1
  • 7
  • 19
-4
votes
3 answers

Pascal else if statment

below is my code and error message I had been thinking of how to correct it but still couldn't, can anyone pls help me, thx I was trying to make a programme that can make a square with numbers out side like this input:3 output: 1 2 3 8 4 …
Casper Wong
  • 11
  • 1
  • 4
-4
votes
1 answer

How can i fix my this syntax error?

I want to test my pascal code but I can't figure out why it's getting this error: Fatal: Syntax error, ; expected but ELSE found Program Lesson2_Program1; Var name, surname, community, inputAnswer : String; GrossSalary, expenses, NetIncome:…
OOFERS
  • 1
  • 2
-4
votes
1 answer

Set of bytes, what are the values of a and b

program Project1; var a,b:set of byte; c:set of byte; i:integer; begin a:=[3]; b:=[2]; c:=(a+b)*(a-b); FOR i:= 0 TO 5 DO IF i IN c THEN write(i:2); readln; end. Can someone please explain to me what is going on in this code.…
-4
votes
2 answers

How to detect installed Free Pascal on Windows computer?

I want to detect installed Free Pascal (about version, install directory...) on my windows computer. Using c#, how to find FPC information on windows registry?
Sent Fake
  • 45
  • 4
-4
votes
1 answer

How to make my FreePascal app exit with a specific code if a certain exception is thrown?

My program has an ESyntaxError class that I use like this: raise ESyntaxError.Create(Message) And I have that ESyntaxError class just defined like this: ESyntaxError = class(Exception) I observe that if that ESyntaxError.Create(Message) code has…
sideshowbarker
  • 81,827
  • 26
  • 193
  • 197
-5
votes
1 answer

Does FreePascal support Macbook Pro m2?

I use Macbook Pro on m2. I want to download FreePascal's ide. But I didn't found on the website. Can you guys help me? I'm expecting link description for FreePascal. Thanks.
-5
votes
1 answer

How to remove spaces from string with while do operator? Pascal

I have text and I need to remove spaces from beginning of text and from end of text. And I can do it only with while do operator. How can I do that? Here's program code program RandomTeksts; uses crt; var t:String; l, x,…
Huskys
  • 1
  • 1
-5
votes
2 answers

How Do I Call a Thread.Execute in GUI Thread?

There is a TThread descendant class with its own Execute method doing some math. It works fine but I am looking for the optimization of the following kind. The GUI thread and context of the program determine the count of necessary instances of these…
asd-tm
  • 3,381
  • 2
  • 24
  • 41
-5
votes
1 answer

Free pascal exit code 201

my code I'm trying to make a program to generate amicable numbers under 10000, but after i pressed ctrl+f9, it exited with exit code 201. How do i fix that?
gachaSalt
  • 11
  • 3
1 2 3
89
90