Re: [fpc-pascal] using exceptions

2012-01-03 Thread Lars
Marcos Douglas wrote: On Thu, Dec 22, 2011 at 4:17 PM, Anton Shepelev anton@gmail.com wrote: Marcos Douglas: It's  not  difficult,  but is boring have always a parameter or function return to return  an  error, and  have  to  verify  if error then... if not er- ror...  if

Re: [fpc-pascal] Advanced Records - Why not available by default?

2012-01-14 Thread Lars
Daniel Gaspary wrote: Any special reason to Advanced Records be available only in Delphi Mode ? Personally, I'm getting sick of all the new features added to delphi that don't add anything meaningful, and just add complexity to the compiler. why didn't borland just make people use old borland

Re: [fpc-pascal] libQT4Pas - Why it is needed?

2012-01-29 Thread Lars
Do other languages like python use the plain c interface, or C++? how about something like ruby, lua, objective C, php .. Krzysztof wrote: Just as I thought - it is object class thing. So if FPC does not (fully) support directly calling external C++ libraries there are plans to support it?

Re: [fpc-pascal] I found FPC v0.2 source code :-)

2012-01-29 Thread Lars
Anything that has Capacitors in it which use wet electrolytic, can dry out with age. Old stereos that crackle when you turn up the volume are an example. In motherboards though it seems it's more a problem that capacitors blow up and bulge out which is probably from usage rather than idle age.

Re: [fpc-pascal] I found FPC v0.2 source code :-)

2012-01-30 Thread Lars
waldo kitty wrote: On 1/29/2012 17:41, Lars wrote: Anything that has Capacitors in it which use wet electrolytic, can dry out with age. Old stereos that crackle when you turn up the volume are an example. In motherboards though it seems it's more a problem that capacitors blow up and bulge

Re: [fpc-pascal] libQT4Pas - Why it is needed?

2012-01-30 Thread Lars
waldo kitty wrote: On 1/29/2012 17:38, Lars wrote: Do other languages like python use the plain c interface, or C++? how about something like ruby, lua, objective C, php .. :( i don't nderstand why one would want to apply interpreted script languages, al la BASIC, to today's tasks... sure

Re: [fpc-pascal] libQT4Pas - Why it is needed?

2012-01-30 Thread Lars
Felipe Monteiro de Carvalho wrote: On Sun, Jan 29, 2012 at 11:38 PM, Lars nore...@z505.com wrote: Do other languages like python use the plain c interface, or C++? how about something like ruby, lua, objective C, php .. No idea, but Python, ruby, lua and php do not generate real programs

Re: [fpc-pascal] I found FPC v0.2 source code :-)

2012-01-30 Thread Lars
Graeme Geldenhuys wrote: On 30 January 2012 10:54, Mark Morgan Lloyd wrote: People who repair things are a dying breed. I fully agree. Totally off-topic, but anybody here know of a course or books one could buy on basic electronic repairs. Thinking in lines of PSU etc to start with. I've

Re: [fpc-pascal] TStringStream.DataString returns garbage?

2012-02-01 Thread Lars
Graeme Geldenhuys wrote: On 2 February 2012 00:14, Michael Van Canneyt wrote: Ehm.. this should be S[1], now you're writing the pointer. Thank you. That's what happens if you have too many very late nights programming - sleep deprivation catches up and one overlooks the simple mistakes.

Re: [fpc-pascal] TStringStream.DataString returns garbage?

2012-02-02 Thread Lars
Jorge Aldo G. de F. Junior wrote: I would vote for a new function on all stream types to allow writing strings in the expected way. Everybody hits that problem once. I think there is a class.WriteString function instead of class.Write() Similar to a DEPRECATED; directive, there could be an

Re: [fpc-pascal] TStringStream.DataString returns garbage?

2012-02-04 Thread Lars
it seems http://docwiki.embarcadero.com/VCL/XE2/en/Classes.TStringStream.WriteString in delphi the WriteString() function accepts a strongly typed string. This might be a compatibility problem in delphi mode since in fpc, writestring accepts a untyped pointer if i am not mistaken. Different

Re: [fpc-pascal] TStringStream.DataString returns garbage?

2012-02-04 Thread Lars
Lars wrote: it seems http://docwiki.embarcadero.com/VCL/XE2/en/Classes.TStringStream.WriteString in delphi the WriteString() function accepts a strongly typed string. This might be a compatibility problem in delphi mode since in fpc, writestring accepts a untyped pointer if i am

Re: [fpc-pascal] Re: What is the most widely used Pascal on Linux and other Unix variants?

2012-02-27 Thread Lars
Frank Church wrote: 5. This requires an increase in the uptake of Pascal. I mean if a language like D can get so much attention and have libraries being created for it why can't Pascal which has been longer established. Another language to check out is TutorialD by Date and Darwen, a pascal

Re: [fpc-pascal] fpweb and security

2012-02-27 Thread Lars
michael.vancann...@wisa.be wrote: On Mon, 27 Feb 2012, ik wrote: Hello, I'm thinking now to use fpweb for a web application I need to build, but the application is going to be over the internet, and I'm interesting in knowing about few security issues that are supported or not. Does it

Re: [fpc-pascal] for loop vs while loop

2017-02-02 Thread Lars
On Wed, February 1, 2017 4:49 am, Graeme Geldenhuys wrote: > Hi, > > > Just curious (been in a discussion with somebody else). Is there a > performance difference between a FOR loop and a WHILE loop? > > Not sure if it will make a difference, but the usage is with three > nested loops, iterating

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-30 Thread Lars
On Mon, January 30, 2017 1:06 am, Marco van de Voort wrote: >> Reason I want to avoid TProcess is simply because cgi programs being >> around 30-100K are easier to upload for people with limited internet >> connection speeds. As soon as I pull in large units that involve lots >> of classes the cgi

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-30 Thread Lars
On Mon, January 30, 2017 12:57 am, Marco van de Voort wrote: > >> Or, get assignstream working on windows and not just unix, but that >> will be a bit of a big undertaking, and again may not be possible. > > Again, duplicating TProcess. > Except assignstream doesn't require TProcess.Create and

Re: [fpc-pascal] Pipe vs Memory buffer.

2017-01-29 Thread Lars
On Sun, January 29, 2017 4:45 am, fredvs wrote: > Hello Lars. > > > Thanks for your brilliant light. > > >> (and can you look into the actual source code of opus or is this closed >> source?) > > ==> https://github.com/xiph/opus > Well the function yo

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-29 Thread Lars
On Sun, January 29, 2017 2:41 pm, Marco van de Voort wrote: > Some likely scenarios (e.g. run and capture stdout) have been prepared in > RunCommand, also in unit Process. > > > The main motivation for adding these is that 90+% of the TProcess and > CreateProcess usage in the forums was faulty

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-29 Thread Lars
On Sun, January 29, 2017 3:18 am, Marco van de Voort wrote: > In our previous episode, Lars said: > >> Assign(StdErr, 'somefile.txt') >> Rewrite(StdErr) >> >> >> And didn't seem to work >> >> >> So if you run a process and nothing prints to s

Re: [fpc-pascal] Pipe vs Memory buffer.

2017-01-29 Thread Lars
On Sun, January 29, 2017 6:04 am, José Mejuto wrote: > El 28/01/2017 a las 13:32, fredvs escribió: > > >> TOpusFileCallbacks = record >> read: op_read_func; >> seek: op_seek_func; >> tell: op_tell_func; >> close: op_close_func; >> end; >> >> This does not work: >> >> >> HandleOP :=

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-29 Thread Lars
On Sun, January 29, 2017 1:36 pm, Santi wrote: > Maybe ExecuteProcess is calling some kind of shell, > Freepascal developers will tell. > To call the shell you send in cmd /C FpSystem does this, but it's on unix Calling the shell is useful for not requiring absolute paths to commands...

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-29 Thread Lars
On Sun, January 29, 2017 10:46 am, Graeme Geldenhuys wrote: > On 2017-01-29 07:59, Lars wrote: > >> So if you run a process and nothing prints to stdout, and there is some >> data printed to stderr, I do not know how to capture it. Which makes >> me want to try TProc

Re: [fpc-pascal] Pointer hashing

2017-01-29 Thread Lars
On Sun, January 29, 2017 7:37 pm, Ryan Joseph wrote: > I'm trying to hash a pointer value and found some example of hash > function but not sure about translations and the process in general. ... > x := (Power((x shr 16), x)) * $45d9f3b; x := Power((x shr 16), x); result := The math unit, is

[fpc-pascal] Operator overloading with Text labels or words

2017-01-29 Thread Lars
It's not possible to define an operator like: Operator AbcXyz(r : real; z1 : complex) z : complex; begin end; Is it? Has to be a symbol? If one could use words or text as operators this might be very interesting, although, probably a double edged sword like Lisp where you could embed

Re: [fpc-pascal] Language constructs and types that dependent upon system unit

2017-01-21 Thread Lars
Forgot to mention, you can also write your own system unit and swap it in place (in delphi and fpc). You can modify existing system unit or even rewrite your own system unit from scratch.. KOL/mck project does this sort of thing to decrease executable size to a miniature size. Embedded

Re: [fpc-pascal] FPC run (run program after compile)

2017-01-21 Thread Lars
On Mon, January 16, 2017 1:21 pm, Lars wrote: .. > On Mon, January 16, 2017 3:59 am, Sven Barth wrote: >> No, FPC is a compiler, not a "runner" or debugger. That would even be >> one of the few points where patches would *not* be welcome. >> > > fpc

Re: [fpc-pascal] FPC run (run program after compile)

2017-01-22 Thread Lars
On Sat, January 21, 2017 11:54 pm, I previously wrote: > https://github.com/z505/fpcRun > > > Project started on github. Tested to work on Windows. > > > Now I just have to try Unix, as, executeprocess works slightly different > on that system and some absolute path configuration to fpc might be

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-28 Thread Lars
On Thu, January 26, 2017 7:28 am, Michael Van Canneyt wrote: > > > On Thu, 26 Jan 2017, Graeme Geldenhuys wrote: > > >> Hi, >> >> >> Whats the differences or pros and cons between using TProcess vs >> RunProcess(). >> > > TProcess gives you full access to the process. You can kill it, > pause it,

Re: [fpc-pascal] TProcess vs RunProcess()

2017-01-29 Thread Lars
On Fri, January 27, 2017 10:24 am, Graeme Geldenhuys wrote: > On 2017-01-26 14:28, Michael Van Canneyt wrote: > >> TProcess gives you full access to the process. You can kill it, >> pause it, write to stdin, read from stdout. >> >> These things cannot be done with RunProcess. >> That's one-shot

Re: [fpc-pascal] ppcjvm issues

2017-01-29 Thread Lars
On Fri, January 27, 2017 11:37 am, Dmitry Boyarintsev wrote: > On Fri, Jan 27, 2017 at 12:52 PM, Jon Foster > > wrote: > > >> Correct me if I'm wrong: It would seem like that your free >> implementation >>> doesn't actually do anything, other than fulfilling the

Re: [fpc-pascal] Pipe vs Memory buffer.

2017-01-29 Thread Lars
On Fri, January 27, 2017 7:54 am, fredvs wrote: > > I am not sure that a array of byte is what op_test_memory want. > It is not a pipe (like lot of other audio lib use), if it is not a array > of byte, what does he want...? > C doesn't even really have arrays since it is so low level (well this

Re: [fpc-pascal] ppcjvm issues

2017-01-29 Thread Lars
On Fri, January 27, 2017 10:52 am, Jon Foster wrote: > > On 01/27/2017 06:36 AM, Dmitry Boyarintsev wrote: > >> On Tue, Jan 10, 2017 at 6:14 AM, Michael Schnell > > wrote: >> >> >> >> If destroying an object is not necessary, the class should

Re: [fpc-pascal] uses myunit in '../src/myunit.pas' ?

2017-02-11 Thread Lars
On Sat, February 11, 2017 5:56 am, Fred van Stappen wrote: > > Unit names are considered to be unique, so strictly, for the compiler > there is no need to specify the path explicitly in code when the unit path > is given to the compiler when calling it from the command line. > > To do this, use

Re: [fpc-pascal] ppcjvm issues

2017-01-17 Thread Lars
On Mon, January 16, 2017 2:40 am, Michael Schnell wrote: > On 14.01.2017 20:36, Lars wrote: > >> What if you are porting code to a non jvm... if you copy and paste >> something and it has no free, you're screwed. > Sorry. I don't understand. AFAIK, in a non jvm project, free()

Re: [fpc-pascal] PascalScript broken by FPC 3.0 ?

2017-01-15 Thread Lars
On Sun, January 15, 2017 7:04 am, Bart wrote: > On 1/15/17, Mattias Gaertner wrote: > > >> Note: >> You can use the Lazarus IDE macro $(FPCVer) in the "FPC source >> directory". Then you only need to switch the compiler path. > > This requires the same directory layout

Re: [fpc-pascal] FPC run (run program after compile)

2017-01-16 Thread Lars
On Mon, January 16, 2017 2:55 am, Graeme Geldenhuys wrote: > On 2017-01-16 07:06, Lars wrote: > >> The only thing I could find was InstantFpc, which may serve similar >> purpose but not really the same as what I was thinking... > > If InstantFPC doesn't work for you,

[fpc-pascal] FPC run (run program after compile)

2017-01-15 Thread Lars
Is there a way to compile a program with fpc at the command line and run it right after? Something like fpc run project1.pas -Fu../ The only thing I could find was InstantFpc, which may serve similar purpose but not really the same as what I was thinking... For some reason (I may remember

Re: [fpc-pascal] FPC run (run program after compile)

2017-01-16 Thread Lars
On Mon, January 16, 2017 3:08 am, Mattias Gaertner wrote: > On Mon, 16 Jan 2017 00:06:59 -0700 > "Lars" <nore...@z505.com> wrote: > > >> Is there a way to compile a program with fpc at the command line and >> run it right after? >> >> Somethin

Re: [fpc-pascal] FPC run (run program after compile)

2017-01-16 Thread Lars
On Mon, January 16, 2017 6:59 am, Mark Morgan Lloyd wrote: > On 16/01/17 13:30, Mattias Gaertner wrote: > >> On Mon, 16 Jan 2017 05:22:14 -0700 >> "Lars" <nore...@z505.com> wrote: >> >> >>> [...] >>> That instantfpc has catch22 lik

Re: [fpc-pascal] FPC run (run program after compile)

2017-01-16 Thread Lars
On Mon, January 16, 2017 3:59 am, Sven Barth wrote: > Am 16.01.2017 08:07 schrieb "Lars" <nore...@z505.com>: > >> >> Is there a way to compile a program with fpc at the command line and >> run it right after? >> >> Something like >

Re: [fpc-pascal] Does the system unit allow file locking/sharing?

2017-01-16 Thread Lars
On Mon, January 16, 2017 2:34 pm, I previously wrote: > The oldschool way of opening files using the system unit (no sysutils) > has the filemode variable.. > > system.FileMode := fmOpenRead; ... > Assign(... > Rewrite(... > > > > Can this be used with file locking/sharing OR-ed options like: >

[fpc-pascal] Does the system unit allow file locking/sharing?

2017-01-16 Thread Lars
The oldschool way of opening files using the system unit (no sysutils) has the filemode variable.. system.FileMode := fmOpenRead; ... Assign(... Rewrite(... Can this be used with file locking/sharing OR-ed options like: fmShareCompat fmShareDenyNone fmShareDenyRead fmShareDenyWrite

Re: [fpc-pascal] Language constructs and types that dependent upon system unit

2017-01-19 Thread Lars
On Thu, January 19, 2017 1:28 pm, gabor wrote: > I was hoping that maybe there is an easy answer. But I understand. > Thanks. > The easy answer is just to use the system unit and have no fear... The main issue with using fpc with C is when you try to use classes or try to use C++ classes As

Re: [fpc-pascal] with no if assigned() there are bugs

2016-09-21 Thread Lars
On Wed, September 21, 2016 6:27 am, Pierre Free Pascal wrote: > There is also the -gc option: > -gcGenerate checks for pointers > > > This is another debugging option, that is not used very often, I could not find this option in the Lazarus options under debugging or any other tab...

Re: [fpc-pascal] with no if assigned() there are bugs

2016-09-21 Thread Lars
> On 2016-09-21 13:27, Pierre Free Pascal wrote: > > There is also the -gc option: > -gcGenerate checks for pointers > I was going to add to my original post "sorry if this feature already exists, or something similar". Now I have to see what Delphi offers, as I use fpc and delphi and

[fpc-pascal] with no if assigned() there are bugs

2016-09-20 Thread Lars
Hi all, I am wondering what your thoughts are on this idea: add the ability to do if assigned() on all objects to prevent bugs, maybe as a compiler feature. Before you write me off as just another person requesting yet another silly feature (it may in fact be that), here is the problem: A lot of

Re: [fpc-pascal] corba interfaces - is/as not working properly

2016-09-28 Thread Lars
On Wed, September 28, 2016 2:24 am, Graeme Geldenhuys wrote: > On 2016-09-28 08:38, David Emerson wrote: > >> I'm testing out CORBA interfaces before changing all my code to use >> them (I would prefer not to have managed types for interfaces). >> > > I've been using CORBA style interfaces for

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2016-11-08 Thread Lars
On Tue, November 8, 2016 2:56 am, Graeme Geldenhuys wrote: > Yes, that changed about 9 years ago. :) And no, fpGUI is *not* a non > visual development environment. fpGUI comes with its own Visual Forms > Designer, Help Viewer, demo IDE and many more. Thanks for clarifying. I have always wanted

Re: [fpc-pascal] New Feature: 'Management Operators'

2016-11-08 Thread Lars
On Tue, November 8, 2016 1:47 am, Maciej Izak wrote: > 2016-11-07 22:24 GMT+01:00 African Wild Dog : > > >> >> I saw on the bug tracker a patch submission by Maciej Izak about the >> feature "Management Operators". >> >> This feature is related to Automatic Reference

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2016-11-08 Thread Lars
On Tue, November 8, 2016 2:45 am, Graeme Geldenhuys wrote: > What Fred did with polYDev is create a minimal (read very small) fully > functional FreeBSD install, that supports desktop development using FPC, > includes a IDE (ideU a fork of MSEide with tons of custom modifications) Does ideU

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2016-11-08 Thread Lars
On Tue, November 8, 2016 3:24 am, Michael Schnell wrote: > On 08.11.2016 03:12, Lars wrote: > "FpGUI" used to be an option (one of a selection of Widget Types, > together with e.g. "GTK2", "CustomDraw", ...). At some point in time the > "WidgetType

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2016-11-08 Thread Lars
On Tue, November 8, 2016 4:04 am, Michael Schnell wrote: > On 08.11.2016 03:12, Lars wrote: > >> >> Does lazarus even know about fpGUI >> > Version 1.6 on Windows: even in the GUI: > Project -> Project Options -> Additions and Overrides -> Set > "LCL

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2016-11-07 Thread Lars
On Mon, November 7, 2016 2:48 am, Michael Schnell wrote: > I understand that you suggest you can't build the Lazarus IDE with > defining fpGUI or CustomDrwan instead of Qt or Gnome (or Windows or > Cocos). > > Does lazarus even know about fpGUI I thought fpgui was never a part of lazarus..

Re: [fpc-pascal] A serious Memleak using delegates/implements (was: Delegate Interface class does not seem to be referenced counted)

2016-11-10 Thread Lars
On Wed, October 5, 2016 9:54 pm, Martin Schreiber wrote: > On Thursday 06 October 2016 00:16:22 Tony Whyman wrote: > >> On 05/10/16 23:03, Graeme Geldenhuys wrote: >> >>> Martin Schreiber recently mentioned in another Interface discussion >>> that there is a very good reason he doesn’t use COM

Re: [fpc-pascal] A serious Memleak using delegates/implements (was: Delegate Interface class does not seem to be referenced counted)

2016-11-10 Thread Lars
On Thu, November 10, 2016 11:04 pm, Martin Schreiber wrote: > On Friday 11 November 2016 04:21:31 Lars wrote: > >> >> Replying to an old thread in my inbox. Apologies if it's obsolete as it >> is a month old. >> > I don't think such themes are allowed in fpc-p

Re: [fpc-pascal] New Feature: 'Management Operators'

2016-11-10 Thread Lars
On Wed, November 9, 2016 7:11 am, leledumbo wrote: >> anyway probably I have no motivation anymore to continuing my work. > > Too bad, if only at least the patch for this feature is integrated, I can > start arguing to my employer again that Pascal has simple, user > selectable garbage collection

Re: [fpc-pascal] New Feature: 'Management Operators'

2016-11-10 Thread Lars
On Wed, November 9, 2016 2:40 am, denisgolovan wrote: > Yes. Mostly. > > > More general advantage is that this feature might finally bring > FreePascal back into league of languages having nice support for value > types (as opposed to OOP atrocities). To put it in other words, functional > style

Re: [fpc-pascal] FreeBSD distro with fpc as star.

2016-11-05 Thread Lars
On Thu, November 3, 2016 4:33 pm, Graeme Geldenhuys wrote: > On 2016-11-03 20:57, Paul Breneman wrote: > >> The short/small video showing the same program being compiled and run >> for 5 systems (FreeBSD 64/32, Linux 64/32 and Windows 32 bit) is *very* >> nice! > > Yes, its even simpler to do

Re: [fpc-pascal] C translation question

2016-10-23 Thread Lars
On Sun, October 23, 2016 2:31 pm, Bernd Oppolzer wrote > But if you translate the C for loop to a while loop first, Agree! For loops, are not nearly as flexible and powerful as while loops. For loops can get you stuck in a certain mode of thinking and you try to develop hacks to manipulate the

Re: [fpc-pascal] C translation question

2016-10-23 Thread Lars
On Sat, October 22, 2016 4:44 am, José Mejuto wrote: > Hello, > > > It is at the end of the loop for sure, it points to the "previous" point > in the polygon and in the case of the first testing point the "previous" > one is the last one. > > So the correct code is: > > > j := i; > > This is my

[fpc-pascal] Piping: high level tool? Strong types sent via pipe

2016-10-17 Thread Lars
I was thinking: pipes are useful to communicate between processes. How about a high level communication system instead of just sending low level strings over the pipe? For example strong typing. If you want to send an integer over a pipe, you generally have to parse the string and ensure it is a

Re: [fpc-pascal] C translation question

2016-10-24 Thread Lars
On Mon, October 24, 2016 5:20 am, José Mejuto wrote: > El 24/10/2016 a las 1:40, Lars escribió: > > >> Hi, what is the status of automated conversion tools? Last I remember >> reading about them was when I read a delphi page on how to convert >> header files. Are you sa

Re: [fpc-pascal] C translation question

2016-10-24 Thread Lars
On Mon, October 24, 2016 8:00 pm, Lars wrote: > I previously wrote: > >> >>> Are you saying that nowadways you can actually convert >>> plain C code to fpc, > > Found this too: > > > http://c2pas.sourceforge.net/ > And there is also this interes

Re: [fpc-pascal] C translation question

2016-10-24 Thread Lars
I previously wrote: > >> Are you saying that nowadways you can actually convert >> plain C code to fpc, Found this too: http://c2pas.sourceforge.net/ It says it can convert a large portion, but not all, obviously ___ fpc-pascal maillist -

Re: [fpc-pascal] Underscores in numerical literals - grouping

2016-11-22 Thread Lars
On Tue, November 22, 2016 6:12 am, Martin Schreiber wrote: > On 11/21/2016 03:46 PM, Graeme Geldenhuys wrote: > >> The age old rule >> of programmer source code always being in a mono-spaced font is >> ridiculous for this day and age. >> ... > A programmer scans code most the time vertically > or

Re: [fpc-pascal] C translation question

2016-11-15 Thread Lars
On Sun, November 13, 2016 2:50 am, Bo Berglund wrote: > On Sun, 30 Oct 2016 21:15:03 -0600, "Lars" > <nore...@z505.com> wrote: > > >> The issue with github is that it encourages a lot of forking rather >> than working together as CVS did. > > We stil

Re: [fpc-pascal] MySQL 5.7 and FreePascal

2016-11-19 Thread Lars
On Sat, November 19, 2016 12:05 pm, Terry A. Haimann wrote: > Is it possible to connect to MySQL 5.7 using TSQLConnection or will I > have to downgrade my MySQL Version? I have FreePascal 3.0.0 which appears > to be the most current version. I have it on a Ubuntu Linux 16.10 X86-64 > system.

Re: [fpc-pascal] Generic way to pre-maturely exit TCustomApplication without memory leaks

2016-10-21 Thread Lars
On Mon, October 17, 2016 12:18 am, grouchysmurf wrote: > Hi. > > >>> I ended up doing exactly that though it feels like an ugly thoug[h] >>> incomplete hack. Thanks for the tip. > >> Why a hack? >> System.ExitCode is meant for returning exitcodes. >> > > Being forced to forfeit one or two layers

Re: [fpc-pascal] C translation question

2016-10-30 Thread Lars
On Tue, October 25, 2016 3:31 pm, José Mejuto wrote: > El 25/10/2016 a las 3:56, Lars escribió: > > >>> If you want to test it I can provide .exe or source code, but do not >>> expect it to translate anything far than some trivial functions. >> Do you have gi

Re: [fpc-pascal] C translation question

2016-10-30 Thread Lars
On Sun, October 30, 2016 4:40 pm, Graeme Geldenhuys wrote: > On 2016-10-30 21:12, Lars wrote: > >> as github is hot with the new kids on the block these days. > > Yes, for good reason! Though I would correct your statement as "Git is > hot...". You don't have to use

Re: [fpc-pascal] List of integers? Any class available in RTL or FCL to help?

2016-12-13 Thread Lars
On Mon, December 5, 2016 6:37 am, Sven Barth wrote: > > Again: I don't see why anyone thinks of generics as complex. Your mail > did not answer that in any way. > Well for one, at least in Delphi, it forces you to throw stuff into a class that have no need. Like a simple array... This:

Re: [fpc-pascal] List of integers? Any class available in RTL or FCL to help?

2016-12-13 Thread Lars
On Mon, December 5, 2016 7:05 am, denisgolovan wrote: > > And generics are complex because they lead to more accidental complexity > for reasons given earlier. > > The Golang approach is to use interfaces, similar to freepascal's VARARGS but a bit different.. and more powerful. Interfaces, an

Re: [fpc-pascal] List of integers? Any class available in RTL or FCL to help?

2016-12-14 Thread Lars
On Wed, December 14, 2016 12:09 am, I previously wrote: > similar to freepascal's VARARGS > Correction: I really meant ARRAY of CONST, but varargs is kind of related. i.e.: http://www.freepascal.org/docs-html/3.0.0/ref/refsu70.html#x181-20300014.4.6 is a simple way of generically programming,

Re: [fpc-pascal] List of integers? Any class available in RTL or FCL to help?

2016-12-14 Thread Lars
On Wed, December 14, 2016 12:35 am, I previously wrote: > But I don't know enough about fps generics to know if stuff needs to be > forced into a class, as I have to start using generics and testing it out > to really know. Sorry, FPS --> FPC. My MacOs laptop that I'm on, testing it out, keeps

Re: [fpc-pascal] meta data of files

2016-12-14 Thread Lars
On Wed, December 14, 2016 11:57 am, Marc Santhoff wrote: > Hi, > > > I'd like to read out meta data from files. is there any pascal code > supporting this task? > > This is about reading the comment of zip files, the author and > description of word processor files (open document format) and so

Re: [fpc-pascal] Size of program vs library ?

2017-01-14 Thread Lars
>>> Sorry to insist on that, but the size of fp library is very too big >>> vs > other libraries (C for example). Except in the case of KOL applications where many of my KOL Dll's/Exe's were smaller than any C/C++ tool could ever create... But KOL is window's specific mostly. Someone ported it,

Re: [fpc-pascal] Free Vision etc. form editor

2017-01-14 Thread Lars
On Fri, January 13, 2017 5:35 am, Mark Morgan Lloyd wrote: > I've just come across > http://forum.lazarus.freepascal.org/index.php?topic=18998.0 which was > asking about a dialog(ue) editor for Turbo/Free Vision. The links it cites > are dead, but the author's page is still available at >

Re: [fpc-pascal] ppcjvm issues

2017-01-14 Thread Lars
On Thu, January 12, 2017 2:08 am, Michael Schnell wrote: > On 11.01.2017 11:25, Sven Barth wrote: > >> >> We're talking about JVM here where garbage collections *must* be used. >> So FPC does as well for that target. >> >> > This of course is true. But if the class code is in fpc, fpc paradigms >

Re: [fpc-pascal] List of integers? Any class available in RTL or FCL to help?

2016-12-05 Thread Lars
This topic title brings back nostalgia as I needed an integer list before, and found some, either in the contributed units section of fpc, or in some old turbopascal units by a company.. TurboPower with Julian Bucknall, or something similar. As I looked through the code, I wondered if fpc and

Re: [fpc-pascal] how to use Default to replace this ' FillChar(aRecord, sizeof(aRecord), 0);

2016-12-05 Thread Lars
Do you know about this feature: var SomeRec: TSomeRecord = (); This initializes the record without needing fillchar. I assume your "Default()" call initializes the record initially. You can eliminate the default() call by initializing the record as part of your declaration. Some criticize

Re: [fpc-pascal] Untyped var params

2017-01-07 Thread Lars
On Sat, January 7, 2017 2:52 pm, Bart wrote: > On 1/7/17, Andrew Hall wrote: > > >> If you cast your “something” to a typed pointer, the compiler will >> do the work for you in the usual way: >> > > But if you know that at forehand (and you know, since you cast it), > why

Re: [fpc-pascal] ppcjvm issues

2017-01-07 Thread Lars
On Sat, January 7, 2017 10:09 am, Jon Foster wrote: > On 01/07/2017 03:06 AM, Tomas Hajny wrote: > >> On Sat, January 7, 2017 03:12, Jon Foster wrote: >> >> >> >> Hello, >> >> >> You didn't mention that you weren't subscribed to the list, but since >> this seemed to be the case, I included your

Re: [fpc-pascal] Untyped var params

2017-01-07 Thread Lars
On Sat, January 7, 2017 4:29 am, Ryan Joseph wrote: > >> On Jan 4, 2017, at 11:07 PM, Dmitry Boyarintsev >> wrote: >> >> >> Treat is as a pointer (it's an implicit pointer anyway) >> >> > > So I need to need to use Move to write memory directly to “var >

Re: [fpc-pascal] FPC clean room project

2017-01-07 Thread Lars
On Fri, January 6, 2017 12:51 pm, Sven Barth wrote: > Ehm... Delphi's compiler is written in C++, not Delphi as far as we > know. Also their NEXTGEN compiler is utilizing LLVM, something we won't > purely do. Yes the exe signature was c/c++ That does not forgive copyright just because

Re: [fpc-pascal] FPC hardware accelerated GUI apps. Why?

2017-01-07 Thread Lars
On Fri, January 6, 2017 10:06 am, Tomas Hajny wrote: > Hello, > > > Could be potential further discussion about FireMonkey moved to > fpc-other, please? I don't think that it's still related to FPC... > > Thank you > > > Tomas > (one of FPC mailing list moderators) > Fine, let me put it this way

Re: [fpc-pascal] FastHtmlParser does not fire OnFoundText on e.g. empty table cell

2016-12-31 Thread Lars
On Fri, December 30, 2016 1:22 pm, Graeme Geldenhuys wrote: > On 2016-12-29 18:43, Bart wrote: > >> Is this intended behaviour? >> > > I'm not sure. I used FastHTMLParser 2+ months ago and discovered a > couple of bugs in it, and similar behaviour to what you mentioned. I wrote > some unit tests

Re: [fpc-pascal] FastHtmlParser does not fire OnFoundText on e.g. empty table cell

2016-12-31 Thread Lars
On Thu, December 29, 2016 12:09 pm, Bart wrote: > On 12/29/16, Bart wrote: > > >> Is this intended behaviour? >> If so, could it be made configurable to do fire the OnFoundText event >> in such cases? > > Never mind, I did not think this through. > I solved my problem in a

Re: [fpc-pascal] FPC clean room project

2017-01-06 Thread Lars
On Tue, January 3, 2017 5:47 am, Dmitriy Pomerantsev wrote: > Doesn't matter since FPC license allowing that. > > > Dmitriy Pomerantsev. Well, Kylix, AFAIR was actually released under GPL at one time too, so in a way delphi already allowed it too (although, more a LGPL would have really

Re: [fpc-pascal] FPC clean room project

2017-01-06 Thread Lars
On Sun, January 1, 2017 10:23 pm, Mr Bee wrote: > Hi all, > There's someone accusing that Free Pascal (and some parts of Lazarus) is > just a reverse engineering of Delphi. Even he said some codes of FPC/Laz > are taken from Delphi (and Kylix). This is a serious allegation. I know > that isn't

Re: [fpc-pascal] FPC clean room project

2017-01-06 Thread Lars
On Thu, January 5, 2017 2:46 am, Graeme Geldenhuys wrote: > I also know from first hand experience that Embarcadero has been made > aware of CodeTyphon's copying and distribution of FireMonkey (called Orca > or something in CodeTyphon). What does this product allow? Compilation of firemonkey

Re: [fpc-pascal] FPC clean room project

2017-01-06 Thread Lars
On Fri, January 6, 2017 8:59 am, Graeme Geldenhuys wrote: > On 2017-01-06 15:49, Lars wrote: > >> What does this product allow? >> > > CodeTyphon distributes the source code of Embarcadero's FireMonkey > predecessor (previously known as VG-Scene or something), but reb

Re: [fpc-pascal] FPC clean room project

2017-01-06 Thread Lars
On Tue, January 3, 2017 6:10 pm, Snorkl e wrote: > They might with a change of ownership, who knows these days, but the > fact they did use it in the past would not look good for any litigation > from some bottom feeder. The fact that they use FPC, means they likely reverse engineer FPC and

Re: [fpc-pascal] FPC clean room project

2017-01-06 Thread Lars
On Fri, January 6, 2017 9:21 am, Graeme Geldenhuys wrote: > On 2017-01-06 16:14, Lars wrote: > >> Okay but what's the point of it? to be able to compile firemonkey like >> applications without buying delphi? > > Yes, you can build hardware accelerated GUI applications using

Re: [fpc-pascal] How to split file of whitespace separated numbers?

2016-12-24 Thread Lars
On Fri, December 23, 2016 4:49 am, Howard Page-Clark wrote: > On 23/12/16 08:14, Bo Berglund wrote: > >> Is there a quick way to split a string of whitespace separated values >> into the separate members? > It is possible that a custom string parser (something along these lines) > might improve

Re: [fpc-pascal] how to use Default to replace this ' FillChar(aRecord, sizeof(aRecord), 0);

2016-12-07 Thread Lars
On Mon, December 5, 2016 4:46 am, Dennis Poon wrote: > > > Lars wrote: > >> Do you know about this feature: >> >> >> var SomeRec: TSomeRecord = (); >> > This is good for global variable. > But I wonder whether it has effect in procedure's local va

[fpc-pascal] How to tell if file is locked, i.e. FileOpen in sysutils

2017-01-15 Thread Lars
The fileopen function returns -1 on error, but there is no way to tell if the error is because of a lock, or another issue opening the file? I'm interested in finding out specifically if a file is locked, as it would be useful for example in a wiki to say to the user "File is locked by another

[fpc-pascal] sqldb create/free lifetime of object

2017-04-12 Thread Lars
The sql query object and transaction object are created but not freed: http://www.freepascal.org/docs-html/fcl/sqldb/usingsqldb.html I think the docs should mention that the objects need not to be freed, as this violates normal programming practice of freeing all objects you create. P.s. how is

Re: [fpc-pascal] SpVoice.GetVoices returned exception class EOleSysError

2017-04-12 Thread Lars
Do you know about fpu issue, described on wiki? http://wiki.freepascal.org/SAPI Is it an fpu exception or something else? And stackoverflow http://stackoverflow.com/questions/3032739/delphi-sapi-text-to-speech Regards Toppost On Mon, April 10, 2017 12:58 am, misabov wrote: > The project has

Re: [fpc-pascal] Threading vs Parallelism ?

2017-04-12 Thread Lars
On Wed, March 29, 2017 4:26 pm, fredvs wrote: > @Karoly Balogh (Charlie/SGR) > > > Perfect, I have now all the arguments to defend the "Dinosaur Threading" > choice. > > Thanks. > > > Fre;D > Methinks that programs should be designed or programmed in such an abstract way that you do not care or

  1   2   >