fpc-pascal · 2014-01
- Generic String Functions29
What is the relation between Generic Functions and (static) DXE String encoding schemes ? Can you (e.g.) do a (silly) Generic Function that takes two strings of any (but…
- fp universal library ?35
Hello everybody ;-) I have developed a fp-wrapper, uos, who links to the best audio open-source libraries: This main fp-wrapper uses other fp-wrappers who link to those…
- overload question (variant vs enum subrange)1
TFoo1 is a sub range of FFoo And it seems to match both TFoo and variant. No other type seems to be bothered by variant. Also variant is the only type, that I found…
- TThread.Suspend7
First question: is Start an accurate replacement for Resume, or can it only be used to start a thread created in the suspended state? Second question: now that Suspend…
- 4
- c structs and pascal interfaces2
I want to use c "interfaces" exposed as structs in fpc as interfaces. In particular I'm converting the OpenSLES header file to fpc. Here's an example of an exported…
- FPCUnit and threads1
FPCUnit has support for threads test? If yes, do you have an example? Marcos Douglas
- ExtractStrings skips empty string parts?7
Conforms issue #16043: "ExtractStrings in the Classes unit skips over empty text. For example: "AAA,BBB,,CCC" is converted to: "AAA" "BBB" "CCC" I was expecting: "AAA"…
- Does TBufDataSet support Blob or memo field?6
I created a TMemoField in TBufDataSet but no matter I do: 1) Field.asString := 'some value' or 2) Field.LoadFromStream(someStream). Afterwards, this F.AsString always…
- Formating JSON outputs2
JSON is a very easy format to handle with Freepascal. However, the output is not so readable when the number of registers increase. An example of it is: program test;…
- best method: multiple three state options in a decision tree13
what is the best method of coding a decision tree with options that have three states and all options are additive? clarification: i have a situation with 5 (at this…
- Memory leak on TFPGInterfacedObjectList2
Hello list. Whenever I add interfaced objects to a TFPGInterfacedObjectList, those objects apparently add two references, while release only one when the list is cleaned…
- Pure FPC ?15
Hello. Does it exist a option to compile fpc without Delphi compatibility ? If no, what do you think about that ? I know, it will be lot of work (like create a…
- [ARM-Android] Safe values for -Cp and -Cf0
In case I would like to have at least 2011 devices as minimum targets, what are the safe values for them? Are -CpARMv6 -CfSOFT enough? Or either could be made better?…
- 0
- how to pass a procedure address and execute it?11
i'm trying to use one routine (centralControl) to process data from two different routines (inputThis and outputThat)... the one routine (centralControl) needs to call…
- FPC trunk missing include file due to recent httpd24 change?1
Got this compiling trunk in fpcup: [1] Perhaps a forgotten file in commit r26573 michael * Patch from Dennis (Bug ID 25534) to add some APR functions to the interface…
- [PATCH] TUploadedFile: some improvements0
Please see in: http://bugs.freepascal.org/view.php?id=25583 Thank you! Silvio Clécio My public projects - github.com/silvioprog
- Strange message about mixed signed expression10
I always wondered why I get a compiler message for the following code snipped: ---------------------------------------------------------------------------- function…
- Include trunk fpcres location in fpc.cfg paths?2
I'm trying to get fpcup to natively compile FPC trunk+Lazarus on ARMHF and finally getting somewhere.... In the Lazarus part however I get lazbuild.lpr(1689) Error:…
- Winsock problems on trunk: rtl-extra?2
FPC trunk x86, windows. Warning: fiddling newb alert. I have a unit httpclient that apparently uses winsock2: 3rdparty\httpclient.pas(0,0) Fatal: Can not find unit…
- Adding files to a tar file3
This code should add all the files of a directory in a tar file. program e01; {$mode objfpc}{$H+} uses libtar, sysutils; var archive: TTarWriter; search: TSearchRec;…
- Can Delphi load a small function of a shared lib written in Free Pascal 2.6.2?6
On Windows, I'm trying to serialize an object to JSON in Delphi 7, using FPC functions linked in a shared lib. I'm sendind a small demo in attached. To test it is very…
- Optimisation : X+X or 2*X or X*2 ?8
The multiplication in floating arthmetic units is usualy know as being slower than the addition. So, have I interest to code X+X, 2*X or X*2 when using reals (mainly…
- [fcl-web] [fphttpserver] what should pathinfo contain?0
I recently has a problem with Brook where every request except default fails and when I debug, I see that pathinfo always has the same content as host. Is this correct?…
- CPPClass Documentation?4
This morning, I saw on fpc-devel a message titled `CPPClass`, which made me wonder if this keyword means what its name implies. Sadly though, there is not much…
- windows.GetProcAddress() vs DynLibs.GetProcAddress()59
Hello. I have a external dll. In Windows i can access perfectly the procedures with GetProcAddress() if i use Windows unit. If i use DynLibs unit, prog crash when i try…
- DecimalSeparator automatic change ?2
I have strange problem, I have application on Windows 2012 Server, where is set locale to Slovak (DecimalSeparator is comma) In my application in DataModuleCreate I…
- minor glitch in phrasing of rarely seen compiler warning0
I recently wrote code that produced this Warning ... Warning: compiler switches aren't supported in \ styled comments Should this not read as follows? Warning: compiler…
- Re: ARM Linux crosscompiler: compiles but... executable gives segmentation fault10
I guess not, when I remember correctly this has already been repaired for armv6m. The problem for me is that .Lj9 is defined as a negative number. As a consequence r13…
- Linking C library1
I'm trying to link a C library to my pascal app. From the messages I understand that I forgot to link in some additional library. However I cannot find which one that…
- respawn a daemon in Linux18
Hi Linux Experts. Since years I am running an fpc program as a kind of daemon on a PC Linux server. I simply defined a "respawn" line in /etc/inittab and with any start…
- ARM Linux crosscompiler: compiles but... executable gives segmentation fault14
For the Dutch among us: de dag die je wist dat zou komen... Thanks to earlier help I got to build an ARM Linux cross compiler module in fpcup which even compiles fpcup…
- Profiling ARM targets2
What is the recommended way to profile FPC applications run on ARM targets in light of the error message: Fatal: Option "-pg" is not, or not yet, supported on the…
- Re: ARM Linux crosscompiler: compiles but... executable gives segmentation fault0
Might be related to the mla/mls optimization which somehow has been enabled even though it's still broken ----- Reply message ----- Fra: "Reinier Olislagers" Dato: man.,…
- invalid floating point0
Running win32 fpc 2.7.1 10/01/2014 Compiling with no -v options.I get An unhandled exception occurred at $0043C670:37 EInvalidOp: Invalid floating point operation…
- fpc build breaks since 263984
Hi Looks like since 26398 rev. fpc cannot be built. It fails with following when running "make all". classes.pp(56) Warning: Implicit uses of Variants unit Fatal: Can't…
- Documentation, syntax diagrams29
Today I found this type definition in some FreePascal sources: TypeReal =type Double; I wondered what the second “type” keyword means here (I have never seen this…
- Efficient millisecond timestamp11
What's the most efficient and portable way of getting a millisecond timestamp, relative to any ancient epoch? I find TimeStampToMSecs(DateTimeToTimeStamp(Now)) hard to…
- Compiled resource file search path5
Hi Could anybody give a hint on which fpc option to use to force compiler search .res files in some directory? I've added -vt switch and it shows that the only file name…
- Load .NET dll (or bootstrap CLR to be precise) from FPC9
I'm writing a web app hosting several tasks in FPC, however one of the task is calling a function residing in a .NET dll. I've made a flat C interface for the dll (so…
- UTF8 codepage for file in trunk: codepage constant names?9
First, thanks to all involved in documenting the existing FPC trunk Unicode situation on the wiki. Exactly the kind of docs I was looking for! I'm trying to avoid…
- Ansi version of string functions1
I would like to know what is the difference between AnsiStrscan and strscan, or, generically, the Ansi* functions versus non-ansi versions? Thanks a lot. Xiangrong
- Is it just me or... trunk cross compile failure on arm-linux8
Working on my arm-linux cross compiler (which used to at least build a compiler etc), I currently hit this with fpc trunk:…
- gtree - Freeing a nil Root without error5
gtree.TTree type has the following code: constructor TTree.Create; begin FRoot := nil; end; destructor TTree.Destroy; begin FRoot.Free; end; How is possible then that…
- Trunk Win64 compilation problems: objects.ppu - commit 26398?2
Hitting compilation problems on trunk with fpcup. cp.exe: C:/development/fpctrunk/rtl/units/x86_64-win64/objects.ppu: No such file or directory make.exe[4]: ***…
- Checking assignment compatibility6
Simulating a C-style conditional, I can do this function tf(const q: qword; const qt, qf: TObject): TObject; inline; begin Assert(TypeOf(qt) = TypeOf(result)); which- as…
- how to initialize a SearchRec var?22
understanding that SearchRec has different formats for different OS targets, we've tried to use fillchar to initialize it to an empty record... unfortunately that does…
- Free Pascal 2.6.4-rc1 released!30
Hello We have placed the first release candidate of the Free Pascal Compiler version 2.6.4 on our ftp servers. You can help improve the upcoming 2.6.4 release by…
- Boolean types6
What is assignment-compatible with a bytebool etc.? My reading of the manual suggested that it should be possible to assign numeric zero or non-zero, but fPB1L: bytebool;
