fpc-pascal · 2018-01
- question about _fpc_local_unwind6
in my rtl for torokernel, I have to implement "_fpc_local_unwind()" however I am not sure about the expected behavior of this function. It appers in the code when I use…
- _Release call location for unused function results8
In the code below Bar creates a reference counted object and returns an interface to it. Foo calls Bar but doesn't assign the result anywhere. In Delphi, this produces…
- Initialize records C style1
I have this code in C, the variable p is a 20 element array. However only the first two items are initialized. Is this possible in pascal as well? TIA, Darius struct…
- Range checks12
The following innocuous looking code generates a range check error: {$R+} function Count: qword; begin Result := 0; end; var i: Integer; begin for i := 0 to Count-1 do…
- Sleep(30) is not reliable?4
In Lazarus component EControl I call Sleep(30) to wait when timer tick work is done. while FBusy do Sleep(30); and app loops forever now in sleep(). procedure…
- RunError(215) occurs only in win 64 bit, not win 32 bit3
When I compiled the following simply programs using Lazarus 1.8 fpc 3.0.4 Win 64, run it, it will throws RunError(215) Arithmetic overflow error. However, if I compile…
- AVG says EXE has a virus | FPC 37459 rev1
I've updated my FPC -> /branches/fixes_3_0 from 37459 rev (2017-10-01) to 38018 rev (2018-01-10). Every time that I'm compiling a project, my AVG antivirus says that…
- Dynamic Packages1
What's the current development status on loading/unloading packages dynamically?
- fcl-web on Microsoft's kernel mode HTTP(S) server0
Hello together! In revision 38013 I extended fcl-web with the support to use it together with Microsoft's kernel mode HTTP(S) server (aka http.sys). What does this mean?…
- directive for -CR1
Is there a compiler directive to enable/disable method call and typecast checks (option -CR). Similar to $R+- for range checks? Mattias
- FPC 3.0.4 on Ubuntu Trusty6
As I don't have Trusty installed I thought I would ask here instead. What is the most convenient way to install FPC 3.0.4 on Ubuntu Trusty? Is it as simple as…
- Html mail displays differently than the body text does...1
I am using Indy 10 (latest trunk version) in Lazarus to create a command line utility to interface with our new Subversion repository server. It sends commit emails to…
- Strange issue with TXMLConfig5
All of a sudden I get a crash in my app trying to read a path from an XML file. The crash comes from the function TDOMNamedNodeMap.Find that crashes on this line: C :=…
- pas2js mailing list6
There is now a public mailing list for pas2js. You can subscribe here: http://lists.freepascal.org/mailman/listinfo/pas2js/ Mattias
- AppImage14
Take a look at https://appimage.org/ Is this possible for Freepascal and Lazarus?
- Poll on website forum0
I posted a poll on the forum site, regarding missing language features in pas2js. http://forum.lazarus.freepascal.org/index.php/topic,39694.0.html Please, let us know…
- Freepascal CLI library5
I'm working on a CLI application that allows the user to do some configuration. During the process the user is presented with different questions that need to be…
- Dot syntax for types?6
I remember I heard about a mode switch that requires "type groups” (what are these called btw?) to use a . and be prefixed. For example: type TGLType = (GL_FLOAT,…
- Change in TStrings.LoadFromFile/LoadFromStream encoding handling0
Just a heads-up. The LoadFromStream and LoadFromFile calls of TStrings have been changed. They now by default take into account encoding. This change was necessary for…
- Compiler hangs while generating debug information1
I encountered an odd problem, however reliably reproducible under both windows 7 and 10, 32bit, with FPC 3.0.2 and 3.0.4. (NOT with Lazarus 1.6.4 which uses FPC 3.0.2…
- issue when enabling -O211
I am getting an exception when I enable the -O2 optimization. More precisaily, the line that stars with write_portd.... is corrupting the data section. This is the…
- can inherited simply replace inherited method(param1, param2, param3)?2
are the 2 below equivalent? procedure Method(param1, param2 : integer); begin inherited; end; procedure Method(param1, param2 : integer); begin inherited Method(param1,…
- PAS2JS: operations with array of record9
Since it's missing the Pas2JS specific forum, I don't know if here is correct place to post things about "Pas2JS". I'm using it a lot and it's very promising. I…
- PAS2JS: JSON suggestion0
IMHO, the TJSJSON external class definition is incorrect. Currently, we have class function, if you want to use the stringify method, use this wierd…
- Generics vs templates18
I was talking with a c++ developer who explained how templates are implemented in c++ and how use some recursive method which causes them to totally murder compile…
- Comp type7
By accident I noticed the comp type for the first time. It's an Int64 but is considered to be a real type. Just out of curiosity, what is the use case of such a type, or…
- Register Allocation on x86_645
is it possible that the register allocation on x86_64 is a bit inefficient? No matter the optimization settings, I can never get FPC to use more than the rax and rdx…
- Problems with writing to console4
I have been mixing "writeln(StdOut" and regular writeln in my application (actually a couple of applications working together) and found that the output on the console…
- re-engineering tool6
Hi! Since I'm confronted with the task of analyzing a pile of object pascal sources I'd like to know: Is there any tool that can help me? Automatically generating a…
- Re: fpc-pascal Digest, Vol 163, Issue 120
Den 2018-01-08 kl. 08:49, skrev Sandro Cumerlato: Great! It works just fine! Very neat and tight fix too! And in time before Christmas is *really* over. At least we have…
- Re: First pas2js public release3
An update on my tests with pas2js: I have overcome most problems now and am quite a bit happier with what I see - and what I did see before was good! Reimar Grabowski…
- Re: fpc-pascal Digest, Vol 163, Issue 111
Thanks! The limitations in the sound playing are straight from JavaScript's Audio API. I think I know how to loop a sound, although the online advice are pretty…
- Error when trying to make tests for target AVR3
I'm trying to run the test suite for AVR by executing the following make statement: make FPC=~/fpc/3.1.1/compiler/ppcx64 TEST_FPC=~/fpc/3.1.1/compiler/ppcrossavr…
- String message methods and the self parameter2
When reading https://www.freepascal.org/docs-html/ref/refsu31.html#x82-1040006.5.7 I stumbled on the following text at the bottom of the page: "In addition to this…
- Final Methods support2
Does FPC have support for final methods? Please see -> http://docwiki.embarcadero.com/RADStudio/Tokyo/en/Methods_(Delphi)#Final_Methods Marcos Douglas
- Translate C code7
Again I would like to ask some support on a piece C code that I need to translate to pascal. The code in question is: #define MEMNEXT(x) ((MyStruct *)(((char *) x) -…
- Modern Compiler Construction using Pascal8
I'd be interested to know if any modern compilers have been written in Pascal (other than the Pascal Compiler). It's unfortunate that that most Pascal books out there…
- CGI/FastCGI and WS request with a max time response4
I have a FastCGI application which needs to receive an user request but, in some cases, the app should consume a WebService(WS) before make the response to the user. The…
- Get user ID for name on Linux10
I would like to get the user ID for a Linux user name. Unfortunately Libc and UnixUtils don't seem to be available in 64-bit, so I can't call the functions getpwnam or…
- any existing units/libraries for sorting?3
I have a list of records (each with a few fields). I want to let users display this list of records in ascending orders of any record field. Is there any existing…
- Possible Memory Leak in TThread.Synchronize3
I have been investigating a possible memory leak in a multi-threading Lazarus program compiled with 3.0.4 where the stack trace with heaptrc shows: Heap dump by heaptrc…
- FPC on zSeries Mainframes1
I remember back in 2012 (I think) there was a large discussion about implementing support for the zSeries IBM mainframes. The wiki had many pages on the topic too.…
- Increasing Image Resolution with Neural Networks0
To whom might be interested, I've just recorded a video showing how to increase image resolution using free pascal: https://www.youtube.com/watch?v=jdFixaZ2P4w I…
