Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal

fpc-pascal · 2016-03

  1. Implicit Operator Overloading

    Fpc: 3.0 Should the compiler to allow the definition of two operator overloading with the same parameters and diferent result types? e.g: ==== code ==== TMyRecord<T>…

    Mazola Winstrol, Sven Barth
    3
  2. FPC 3.0.0 and constref default param

    This code worked fine on FPC 2.6.4: procedure Test(constref AParam: String = 'def_param'); begin writeln(AParam); end; But on FPC 3.0.0 I get error: unit1.pas(30,42)…

    Krzysztof, Maciej Izak
    3
  3. Postgresql interface bronken for Raspberry pi model 1b

    Hi! I'm using a pi as a monitor for some process, so I'm trying to get SDL2 and a working postgres interface on it. However I'm running into trouble on timestamps fields…

    Björn Lundin, Bo Berglund, Marco van de Voort
    9
  4. Class constructor called unconditionally

    First, take a look at this small project: === code === program Project1; {$IFDEF FPC} {$MODE DELPHI} {$ENDIF} {$IFDEF MSWINDOWS} {$APPTYPE CONSOLE} {$ENDIF} type TFoo =…

    silvioprog, Dmitry Boyarintsev, Graeme Geldenhuys
    15
  5. PDF generator, try 2

    Hello In revision 33401 of FPC subversion, a lot of fixes have been committed for Font handling in the PDF generator: e.g. Unicode fonts should now render correctly. The…

    Michael Van Canneyt, Ralf Quint
    1
  6. Default source encoding

    According to http://wiki.freepascal.org/index.php?title=FPC_Unicode_support#String_constants "the constant strings are assumed to have code page 28591 (ISO 8859-1 Latin…

    Mattias Gaertner, Jonas Maebe, Michael Van Canneyt
    7
  7. History of the Cardinal data type?

    Just curious. What is the history behind the Cardinal data type. As per the FPC documentation, it is always mapped to the LongWord type. I presume it is the same in…

    Graeme Geldenhuys, Dmitry Boyarintsev, Florian Klaempfl
    25
  8. How to crosscompile i386-linux from X86_64-win64

    what parameter(s) need to cross-compiling i386-Linux from X86_64-win64 ? When I am trying to compile from "win32" with win32 compiler:…

    ulrich, Jonas Maebe, Sven Barth
    4
  9. heaptrc and high RAM usage

    I have an app that is using too much RAM and I am trying to figure out which structures are using how much RAM. Note that this is not a leak, everything is freed nicely…

    Felipe Monteiro de Carvalho, Andreas Schneider
    1
  10. IFDEF usage in x86_64's SwapEndian() implementation

    Here is the x86_64's SwapEndian() function implementation. =============[ src/rtl/x86_64/x86_64.inc ]==================== function SwapEndian(const AValue: DWord):…

    Graeme Geldenhuys, Bart, Michael Van Canneyt
    5
  11. Migrating from FPC 2.6.4 to 3.0.0 . What should I be aware?

    I'm planning constantly moving my apps to FPC 3.0.0. Compiled the smallest app and everything seems to working fine. In official recent changes list I read that main…

    Krzysztof, Jonas Maebe
    1
  12. TPersistent overhead

    What are all the performance costs associated with subclassing TPersistent for RTTI information? I want to use this in some classes but unfortunately the way my code is…

    Ryan Joseph, Graeme Geldenhuys, Michael Van Canneyt
    5
  13. [heaptrc] no output for weblaz projects.

    I use heaptrc unit without any problem, using Lazarus project options. Now I try fcl-web applications (curently fphttpapp) and... heaptrc does not work. I see the…

    Thierry B., Graeme Geldenhuys, leledumbo
    3
  14. UnicodeString and Length() function

    I never really used the UnicodeString (or WideString for that matter) - I've always used AnsiString with UTF-8 content. I also have my own UTF8 functions Copy(),…

    Graeme Geldenhuys, Jonas Maebe
    2
  15. cwstrings unit and UTF8Decode()

    I'm using FPC 2.6.4 primarily. Am I correct in that UTF8Decode and most (if not all) UTF8-to-UTF16 conversions don't function correctly (or not at all) if you don't…

    Graeme Geldenhuys, Bart, Felipe Monteiro de Carvalho
    18
  16. IsValidIdent() with dots

    Hi Is there a function like IsValidIdent but accepting also dots (.), as in name "TForm1.Action1Execute"? While fixing a bug: http://bugs.freepascal.org/view.php?id=25954

    Juha Manninen, Mattias Gaertner, Michael Van Canneyt
    3
  17. Smartphone apps in FPC

       I was on this list years ago, and then fell off at some point for some reason, but back again now. :-)    Having written for DOS all those years ago, I am now…

    Unknown author, Felipe Monteiro de Carvalho, Ingemar Ragnemalm
    16
  18. Mangle name in fpc-FreeBSD ?

    Hello. I have problem to access methods from a C library. For FreeBSD, the methods cannot be accessed (but ok for Linux and Windows). In FreeBSD, LoadLibrary(aac.so) is…

    fredvs, Ewald, Marc Santhoff
    37
  19. crosscompiling problem (.a file)

    I have installed Lazarus 1.6 (64-bit version) in the windows directory c:\lazarus16. I downloaded the source compiler in c:\lazarus16\FPC - missing subdirectories. In…

    ulrich, Jonas Maebe
    5
  20. Fpc 3.0 Bug: type specialization and operator overload

    Fpc version: 3.0 (the one provided by Lazarus). Please confirm if this is a bug regarding operator overloading and type specialization. It is a quite difficult to…

    Mazola Winstrol, Sven Barth
    2
  21. Primitive Record Wrappers

    In some situations, would be very interesting to determine whether the value of a primitive variable is initialized or not. For example, fields in database records can…

    Mazola Winstrol, Constantine Yannakopoulos, Dmitry Boyarintsev
    38
  22. PDF generator

    I have committed a PDF generator to FPC Subversion: fcl-pdf. Why a new pascal PDF generator ? Mainly because the existing ones written in Object Pascal suffer from…

    Michael Van Canneyt, che fou, Graeme Geldenhuys
    7
  23. How do I test the testfppdf on Windows?

    I just created the folder "fonts" and copied the "C:\Windows\Fonts\arial.ttf" into that, so I changed the line "D.AddFont('FreeSans.ttf', 'FreeSans-12' to…

    silvioprog, Graeme Geldenhuys, Jesus Reyes A.
    35
  24. Codepage + class helper raises "Error identifier idents no member ..."

    Consider the following code: === code === program project1; {$mode objfpc}{$H+} *//{$codepage utf8}* uses Classes; type TFoo = class helper for TStream public procedure…

    silvioprog, Bart, Sven Barth
    11
  25. FillChar/FillByte and Finalize()

    Should I (and in which case) call Finalize() when using FillChar/FillByte? Heaptrc unit is not detecting any memory leak. For example: type PMyRec = ^TMyRec; TMyRec =…

    Krzysztof, Olivier Sannier
    2
  26. CMS in Pascal ?

    I'm looking for a minimalist flat-file CMS. There are many floating around, I found a list on e.g. http://www.hongkiat.com/blog/flat-cms/ Is there one written in Object…

    Michael Van Canneyt, Christian-W. Budde, leledumbo
    4
  27. CMem issue?

    I got an AV in the CMem unit. To reproduce the problem just compile and run this code below: === code === program project1; {$mode delphi} uses Classes, SysUtils, cmem;…

    silvioprog, Bart, dinmil
    20
  28. TFPTimer wtih timer_create

    Hi all! I'm searching a way to implement a TFPTimer that don't uses threads. On Linux and FreeBSD I found the timer_create and family functions. My question is: What…

    Fabio Luis Girardi, Michael Van Canneyt
    5
  29. TStringHelper.Split() issue?

    Just test this code below: === code === program Project1; {$mode delphi} uses SysUtils; var content: string = 'x:y'; splited: TArray<string>; begin splited :=…

    silvioprog, Michael Van Canneyt, Rik van Kekem
    6
  30. AnsiCompareStr question (again...)

    in an application, I use a TStringList.Sort to sort a list of these two words "(C-C)" and "(C=C)". When I use the same unit in another project, the Sort function sort…

    Marcou Gilles, Bart, Jonas Maebe
    8
  31. fcl-xml HTML parser

    today I did a little modification to a tool I wrote some time ago. To my surprise even the unmodified code produced totally wrong result while the old binary did work as…

    Unknown author
    0
  32. Annual Inform

    Annual inform: I am programming LibreN3D for 3D animations, and some other projects in FreeDOS and other systems, but these two past years they really were standing by.…

    Rafael Angel Campos Vargas
    0
  33. Fpc Bug 3.0: Generics and Operator Overloading

    Fpc version: 3.0 (the one included with Lazarus 1.6). Please confirm if it is a bug: it seems the compiler doesn't handle operator overloading properly when using…

    Mazola Winstrol, Sven Barth
    3
  34. Fpc Bug: Type specialization with Generics and Operator Overloading in Diferent Units

    Fpc version: 3.0 (the same included with lazarus 1.6). Please confirm if it is a bug: If i declare a generic record with overloaded add operation, i need to specialize…

    Mazola Winstrol, Sven Barth
    1
  35. Bug in FPC 3.0.0 (was: Bug in FPC 3.0.0?)

    Sorry, my previous example was not complete. Here is a problem detected when compiling UniDAC 6.2.8. Taken from real code in VirtualTable.pas program Project1; {$MODE…

    Serguei TARASSOV, Bo Berglund, Flávio Etrusco
    39
  36. Bitcounting

    Does FreePascal have a routine for counting bits? So that e.g. BitCount(%1001100100001) gives 5 (number of bits that are 1)? I came up with (extracted from IntToBin()):…

    Bart, David W Noon, Jeppe Johansen
    11
  37. Trapping distant exceptions

    I'm sure I should know this, and think it's an FAQ, and I'm pretty sure somebody (Graeme?) was discussing it recently. Assuming that an exception handler at the end of a…

    Mark Morgan Lloyd
    0
  38. fpc 3.0 ansistring codepage behavior

    I am debugging an issue (x86_64 Linux platform) which I have in FPC 3.0 which I didn't have in 2.6.4. It is a complex project with a lot of threading, custom memory…

    Seth Grover, Jonas Maebe
    2
  39. Access violation in an empty project declaring heaptrc

    Just create a project like this: program project1; {$mode objfpc}{$H+} uses heaptrc; begin end. Now, compile and try to run that, you will get this error: Heap dump by…

    silvioprog, Sven Barth
    2
  40. Happy tickets benchmark

    Here is my little brute-force test for FPC, C and C# compilers. http://arbinada.com/main/en/node/1532 The results are not so good with FPC but I cannot use Delphi to…

    Serguei TARASSOV, Adrian Veith, Dmitry Boyarintsev
    58
  41. compile Link Smart option, is it -XX or -CX?

    According to http://www.freepascal.org/docs-html/prog/progse30.html the smartlink option on the command line is -CX Compilation and Linking Linking Link Smart is -XX…

    Dennis, Dennis Poon, Sven Barth
    3
  42. Wiki (image) uploading temporarily disabled

    The tech support scammers discovered that mediawiki's antispam regex doesn't get applied to image descriptions, so they're now attacking us that way. I hope to find a…

    Jonas Maebe
    1