Sign in Join

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

Mailing lists / fpc-pascal

fpc-pascal · 2011-10

  1. Delphi's anonymous functions in Free Pascal

    Does Free Pascal have anonymous functions that you can pass around, e.g. to a sort(compare : function, arr : array) function? If not, does anyone know any hacks to…

    Andrew Pennebaker, Alberto Narduzzi, Alexander Shishkin
    124
  2. 3-tier database applications with FPC

    Just over 3 years ago I asked about FPC support for creating 3-tier database applications. The answer was basically: it's not possible (unless you roll your own Midas /…

    Graeme Geldenhuys, ABorka, Carlo Kok
    14
  3. Premature end of headers using fcl-web and POST

    So I advanced my CGI using HTTP GET so far, but I'd like to migrate to HTTP POST. But I always get this error message in the apache logs: Premature end of script…

    Felipe Monteiro de Carvalho, ABorka, Ludo Brands
    19
  4. How can I implement "thrice" in Free Pascal?

    Haskell lets you define functions like thrice, which accepts an element of type a and returns a list of the element repeated three times, for any data type a. thrice ::…

    Andrew Pennebaker, Florian Klämpfl, Graeme Geldenhuys
    37
  5. A linking error when compiling with FPC 2.4.4

    I have installed FPC 2.4.4 using the following package: http://mirrors.iwi.me/lazarus/snapshots/fpc-2.4.4-1.i386.deb.tar Having unpacked it in a folder, I did: sudo dpkg…

    Luciano de Souza, Felipe Monteiro de Carvalho, Graeme Geldenhuys
    13
  6. Re: using a unit from an old version of fpc

    Directly including it in the uses clause is not possible. Linking it might be possible with certain limitations, but it is fairly difficult and implies some amount of…

    Tomas Hajny, John Lee
    1
  7. XML - How to set and use a Namespace Prefix?

    I'm trying to create an XML Document with multiple Namespaces. With the code below[1] a get as result the following XML: <svg xmlns="http://www.w3.org/2000/svg" /> How…

    Daniel Gaspary
    0
  8. Debugging cgi applications

    Atached is a small unit that makes debugging cgi applications easier. When used in a program it will as part of the initialization launch a new process which opens a…

    Ludo Brands
    0
  9. FPC MemoryDataset

    Hi! Sometime ago I submitted a patch that makes the FPC Memory DataSet compatible with Delphi to make it usable on both IDE's by project PascalSCADA. The class TDataset…

    Fabio Luis Girardi, Michael Van Canneyt
    1
  10. text.inc(1955, 20) Error: identifier idents no member "CodePage"

    I got this error when I tried to compile FPC 2.7.1 rev 19546. ------------------------------------------------------------------------------------------------- make[7]:…

    Marcos Douglas, Graeme Geldenhuys, Henry Vermaak
    16
  11. How to insert a record and get the primary key with sqldb?

    Yet another chapter of my database problems =) Ok, now I want to insert a record in my table and I would like to obtain the auto-generated PrimaryKey I tryed a number of…

    Felipe Monteiro de Carvalho, Graeme Geldenhuys, Henry Vermaak
    60
  12. Indy 10 HTTP Server component with FPC

    Is anybody here using the Indy 10 components with FPC? More specifically, the HTTP Server component. My project compiles fine, but when I activate the HTTP Server I get…

    Graeme Geldenhuys, Burkhard Carstens, Marco van de Voort
    5
  13. How are Assigned, Free, Nil and Destroy related?

    This is one question I have wanted to ask for a long time. How are Assigned, Free, Nil and Destroy related, and when is one or another appropriate? What other procedure…

    Frank Church, Alexander Shishkin, Felipe Monteiro de Carvalho
    17
  14. FPC has multiple HTTP server components

    I was looking through the FCL code and noticed that there seems to be more than one HTTP server component. What is the difference between them, and which one would be…

    Graeme Geldenhuys, Marco van de Voort, Michael Van Canneyt
    2
  15. sqldb how to find a record fast with primary key

    I am using sqldb to connect to a postgres database. Using wiki instructions, my final object is a TSQLQuery for each table. So, this basically is a TDataset and to read…

    Felipe Monteiro de Carvalho, Ludo Brands, Martin Schreiber
    12
  16. Why do string indices start at 1, but array indices start at 0?

    It's inconsistent and ripe for bugs. Andrew Pennebaker www.yellosoft.us

    Andrew Pennebaker, Andrew Haines, Jonas Maebe
    6
  17. Format() directives

    In the future, could Format respect the difference between '%x' and '%X'? It's useful to use the former for lowercase hexadecimal. Andrew Pennebaker www.yellosoft.us

    Andrew Pennebaker, waldo kitty
    2
  18. Unicode function names

    Out of curiosity, I've just tried creating a function named ⍳ (Unicode character 2373, i.e. the APL iota function). FPC trunk complains Fatal: illegal character…

    Mark Morgan Lloyd, Sven Barth, Unknown author
    3
  19. Reopen issue 20500: TSQLParser cant Parse Statements containing "as"

    The issue reporter gave this example: select ORDERNO as OrderNo from ORDERS as Orders; It does parse AS, but only for a field. Michael Van Canneyt replied: TSQLParser…

    Reinier Olislagers, Michael Van Canneyt
    3
  20. Compiling sources obtained via SVN

    I assume there's an expectation that the sources downloaded from trunk should compile on all platforms? I've just updated to 19505, and attempting to build on Linux Mint…

    brian, Mark Morgan Lloyd, Pierre Free Pascal
    4
  21. Stack corruption setting UnicodeString Char

    Usually when we work with PChars we do things like this to set the final terminator: var ansistr: ansistring; begin // Copy the originating string taking into account…

    Felipe Monteiro de Carvalho, Mattias Gaertner, Sven Barth
    5
  22. Getting Hardware information in Linux

    I'm trying to figure out how to get hardware information about the machine i'm running at in Linux OS. For example: hard-drive size, manufacture etc... BIOS information,…

    ik, Den Jean, Graeme Geldenhuys
    8
  23. CGI under Freepascal

    I am trying to use CGI with Pascal. I don't have background in web development, but principles of CGI seems to be simple. The first way could be FPWeb. However, I prefer…

    Luciano de Souza, Felipe Monteiro de Carvalho, Graeme Geldenhuys
    3
  24. fpc has trouble with array types

    But, but, the docs imply that this is the syntax for a function that returns an array of bytes. fpc ios7crypt.pas ios7crypt.pas(3,25) Error: Type identifier expected…

    Andrew Pennebaker, Felipe Monteiro de Carvalho, Sven Barth
    8
  25. fpweb and reading the contents of a request

    I am trying to send data from javascript and read data back from my cgi module with this: SendSyncRequest = function(RequestURL, RequestContent) { var request = new…

    Felipe Monteiro de Carvalho, herux, Michael Van Canneyt
    12
  26. fpweb and custom debug log

    I see that when my CGI raises an exception we get a nice error message with a stack trace as a response. Is it possible to put some logging messages into this error…

    Felipe Monteiro de Carvalho, Michael Van Canneyt
    1
  27. Any command line interpreters for Free Pascal?

    E.g., if fpi existed, I would add a shebang like this to my code: #!/usr/bin/env fpi Andrew Pennebaker www.yellosoft.us

    Andrew Pennebaker, Alex Shishkin, Florian Klämpfl
    36
  28. More Filter Madness

    Mine is more of a *programming *problem, rather than one native to Pascal, but here goes: I have a text file with many Double values. Looking more or less like below,…

    Ko Hashiguchi, Alberto Narduzzi, Graeme Geldenhuys
    13
  29. RE : Problem passing pointers to "hidden" procedure

    On Sat, 15 Oct 2011 09:24:36 +0200 "Ludo Brands" wrote Oops! Silly me. But some kind of complaint from the compiler would have been helpful! Andrew Bennett

    Unknown author
    0
  30. Problem passing pointers to "hidden" procedure

    As part of an attempt at multi-threading, I have had to move many things that used to be global into the Implementation parts of units in order to enforce privacy. When…

    Unknown author, Ludo Brands, Sven Barth
    2
  31. How do I load external Pascal code?

    If I were using C, I would type: #include "code.h" If I were using Python, I would type: import code What's the command to load code in Pascal? And where do the load…

    Andrew Pennebaker, Jonas Maebe, Jürgen Hestermann
    15
  32. Stunnel replaced by FPC?

    For my remote assistance screen sharing project https://bitbucket.org/reiniero/checkride/ I'm currently using stunnel on Windows to tunnel VNC traffic over an SSL/TLS…

    Reinier Olislagers, Wimpie Nortje
    2
  33. FPC 2.4.4 - Error: Illegal type conversion: "Set of TMySet" to "Byte" ... and vice versa

    I am trying to compile my code which is compatible with Delphi and FPC 2.5.1+, but when I try to compile on Mac OS X with 2.4.4 I have error message: Error: Illegal type…

    fred f, Jonas Maebe
    1
  34. List of Integer/Double etc

    Hi, I'm wondering if the rtl or a standard package includes classes for handling lists of Integer, Double, and other types. Similar to TStringList, but for numerical…

    Leonardo M. Ramé, Sven Barth
    3
  35. Making a cross-compiler for STM32

    I'm trying to make a crosscompliler for STM32 (arm-embedded) on my linux-machine. I just downloaded a daily development snapshot and compiled it with : make clean…

    Koenraad Lelong, Jeppe Græsdal Johansen
    8
  36. OT A bit, will you vote for this feature request for FB ?

    I have created a feature request for Firebird SQL, to add support for multibyte characters when dealing with the string functions in FB.…

    ik
    0
  37. Reusing a TProcess object (issue 19997)

    Is it allowed to execute a TProcess object more than once? And if yes, different command lines be used? The reason I ask is issue 19997, each invocation of the compiler…

    Vincent Snijders, Sven Barth
    1
  38. Writing generic enumerator

    Is it possible to write one? Due to the nature of enumerator, the iterator and iterated class usually form mutual dependency. With normal classes, this is no problem as…

    leledumbo, Sven Barth
    1
  39. Linking to C++ DLL compiled with MSVC

    I've been trying to link to an external DLL which is unfortunately compiled using MSVC in C++ mode. The functions itself do not use any C++ features, they are just not…

    Michael Lutz, Sven Barth
    5
  40. Windows API translation - or better way to update system tray?

    (See http://lazarus.freepascal.org/index.php/topic,14847.msg79038.html#msg79038 for initial question) My program starts and stops external programs that have icons. It…

    Reinier Olislagers, Sven Barth
    2
  41. [Semi-OT] Git format patches don't seem to work

    Having some trouble creating patches that actually work. (On Windows) I've been using git to get FPC trunk and git diff --no-prefix > %temp%\mypatch.diff rem --no-prefix…

    Reinier Olislagers, Alex Shishkin, cobines
    29
  42. What about complex numbers?

    Hello Is complex number arithmetic possible in FPC? Another post recommends use unit so named ucomplex, but i can't find any detailed information of this in the…

    Carlos Avila, David Emerson, Jeppe Græsdal Johansen
    8
  43. freetype unit + unicode

    I am using the freetype unit (with linux) and would like to display some interesting unicode characters. However when I pass a string containing say U+2265 to…

    David Emerson, Graeme Geldenhuys, Unknown author
    8
  44. Error when translating a C header

    I tried to translate a C header with: h2pas -e -d -p iupkey.h I got the following error: at line 21 error : syntax error at line 41 error : syntax error Illegal…

    Luciano de Souza, Ludo Brands
    3
  45. 2
  46. Does FPC support fields which are only accessible from the object itself, eg. some kind of super private fields

    Private allows access to procedures which the unit, even if they belong to a separate object. Does FPC support fields which are only accessible from the object itself,…

    Frank Church, Paul Ishenin
    1
  47. fcl-extra ServiceManager doesn't seem to working with unelevated Windows account?

    First wanted to check with you if I'm doing something wrong. Using the ServiceManager unit (Windows only), I'm trying to find out if a service is running (Vista x64). I…

    Reinier Olislagers, Sven Barth
    2
  48. Cannot build RTL for native NT

    These were the steps I did (based on http://wiki.freepascal.org/Target_NativeNT) 1. Check out svn.freepascal.org/svn/fpc/trunk (revision 19048), put it into…

    Andre Tampubolon, anta40, Sven Barth
    4
  49. FPC 2.5.1 (trunk rev 18036): Can't find unit fastcgi used by custfcgi

    I got an error trying to compile FPC 2.5.1 (trunk at revision: 18036) on WinXP-SP3. Before update, I ran 'make distclean'. Console output: [snip] Start building package…

    Marcos Douglas, Florian Klämpfl, Marco van de Voort
    13
  50. Error crosscompile on WinXP: FPC /branches/fixes_2_6 rev 19336

    On WinXP I can compile FPC /branches/fixes_2_6 rev 19336 to i386 but not to x86_64 I think the argument "-dGDB_V606" should be changed... but is this a new option or a…

    Marcos Douglas
    0