Re: [fpc-pascal] Using constants in constant record definition

2019-06-12 Thread Bart
or you. -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] from fpc 2.6 to 3.x

2019-06-01 Thread Bart
kwards compatibility are documented at http://wiki.freepascal.org/User_Changes_3.0 Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] RPos Causing Access violation

2019-05-21 Thread Bart
s) then exit; {$endif} '.': exit(copy(Result,1, p-1)); end; dec(p); end; end; writeln(ExtractFileNameWithoutExt('c:\foo\bar\foobar.ext')); gives: c:\foo\bar\foobar -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org

Re: [fpc-pascal] CopyFile for FreePascal without Lazarus?

2019-04-18 Thread Bart
eplace TFileStreamUTF8 with TFileStream and you'r probably done. -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] bug in make install ?

2019-03-26 Thread Bart
Process.ShowWindow := swoHIDE help? Makes no difference at all. I totally removed all that code from InitialSetUpDlg and I still see 2 console windows flashing. So something else in the IDE seems to do that. -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.f

Re: [fpc-pascal] bug in make install ?

2019-03-25 Thread Bart
On Sun, Mar 24, 2019 at 11:41 PM Bart wrote: > > Sorry, I just never use that stuff in my programs. In a simple test program I can make this work withou a console wndow popping up: procedure TForm1.Button1Click(Sender: TObject); var S: String; begin Proc.Executable := 'C:\pp\bin\i386

Re: [fpc-pascal] bug in make install ?

2019-03-24 Thread Bart
On Sun, Mar 24, 2019 at 6:36 PM Bart wrote: > Sorry, I just never use that stuff in my programs. It seems that when you try to execute a program that writes to console and you specify [poNoconsole] then the program will exit with: Proc.ExitCode=C005, Proc.ExitStatus=C005 -- B

Re: [fpc-pascal] bug in make install ?

2019-03-24 Thread Bart
s, that should not matter? Sorry, I just never use that stuff in my programs. Bart -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] bug in make install ?

2019-03-24 Thread Bart
On Sun, Mar 24, 2019 at 1:30 AM Bart wrote: > fpcmkcfg.exe does not support -V parameter Never mind that: it helps if you actually rebuild fpc, not just update the sources ;-) fpcmkcfg -h however does not list the "-V" option. Now I get the rather ludicrous error mess

Re: [fpc-pascal] bug in make install ?

2019-03-23 Thread Bart
TOBJECT__FREE, line 336 of C:/devel/fpc/trunk/rtl/inc/objpas.inc Hint: (lazarus) [TMainIDE.Destroy] B -> inherited Destroy... TMainIDE Hint: (lazarus) [TMainIDE.Destroy] END -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org h

Re: [fpc-pascal] bug in make install ?

2019-03-23 Thread Bart
On Sat, Mar 23, 2019 at 7:56 PM Bart wrote: > "Warning: Failed to retrieve the version of the fpcmkcfg configuration > tool. It is probably too old to create the configuration files. Make > sure a recent version is installed and available in the path or > alongside the co

Re: [fpc-pascal] bug in make install ?

2019-03-23 Thread Bart
/b ppc386.exe C:\pp\bin\i386-win32>dir fpc.exe /b fpc.exe And it is the current path: C:\pp\bin\i386-win32>path PATH=C:\pp\bin\i386-win32;C:\Program Files . So, at least this error message is wrong. The "Create new Fppkg configuration" is disabled. How

Re: [fpc-pascal] FPC fixes3.2 gives error on "NWord div 2 * 2"

2019-02-17 Thread Bart
On Sun, Feb 17, 2019 at 10:14 PM AlexeyT wrote: > this is fixed to avoid %subj% compile error. why error? {$mode objfpc} {$h+} var NSec: Word; begin NSec:= NSec div 2 * 2; end. Compiles with trunk (regardles of mode). -- Bart ___ fpc-pas

Re: [fpc-pascal] trying to use C code in .pas on WIN32

2019-01-31 Thread Bart
On Thu, Jan 31, 2019 at 7:35 AM Sven Barth via fpc-pascal wrote: > > This is on an evil windows machine > Windows is one of FPC's main targets, we can do without such "expletives". Maybe he has WinME ??? -- Bart ___ fpc-pasc

Re: [fpc-pascal] CLI argument parsers (was: Resource compilation)

2019-01-16 Thread Bart
On Tue, Jan 15, 2019 at 11:02 PM Bart wrote: > I tried the proposed fix (it should go in 5 lines from the bottom i=of > Internal_getopt), and it does not fix the issue. I attached a possible fix to the bugreport. Are there tests for the getopst unit? --

Re: [fpc-pascal] CLI argument parsers (was: Resource compilation)

2019-01-15 Thread Bart
uld go in 5 lines from the bottom i=of Internal_getopt), and it does not fix the issue. -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] CLI argument parsers (was: Resource compilation)

2019-01-14 Thread Bart
implementation particulars. GetOpts gets it wrong sometimes: see https://bugs.freepascal.org/view.php?id=19842 -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Get "disk" ID

2019-01-05 Thread Bart
n time (regardless of a reboot of the system in the mean time). If the disk was formatted before inserting a next time, it will not matter if the "ID" changes. Preferrably the code for linux would also work on MacOSX. -- Bart ___ fpc-pascal maillist

Re: [fpc-pascal] "crtbegin.o" not found

2019-01-03 Thread Bart
On Thu, Jan 3, 2019 at 6:34 PM Florian Klämpfl wrote: > > Maybe there's an appropriate page it can gi into. > > I added it to the explanation of the compiler error. I added it to the FAQ. -- Bart ___ fpc-pascal maillist -

Re: [fpc-pascal] "crtbegin.o" not found

2019-01-03 Thread Bart
I put it on my user page on the wiki: http://wiki.lazarus.freepascal.org/User:Bart#Notes_for_myself Maybe there's an appropriate page it can gi into. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin

Re: [fpc-pascal] "crtbegin.o" not found

2019-01-03 Thread Bart
On Thu, Jan 3, 2019 at 5:34 PM Bart wrote: > There's a commandline argument to gcc that will tell you where it is. bart@simenon ~ $ gcc --print-file-name crtbeginS.o /usr/lib/gcc/x86_64-linux-gnu/5/crtbeginS.o from /etc/fpc.cfg: # path to the gcclib #ifdef cpui386 #-Fl/usr/lib/gcc/x86_64-li

Re: [fpc-pascal] "crtbegin.o" not found

2019-01-03 Thread Bart
t file. There's a commandline argument to gcc that will tell you where it is. Then add that path in the appropriate place in fpc.cfg (At least I did that on Mint 18.2 and Suse Tumbleweed) Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.or

Re: [fpc-pascal] Fixes 3.2: make all fails

2019-01-02 Thread Bart
s. (like e.g. building on a fat partition from linux). > > Solution/workaround: > > touch h2pas.pas Timestamps are all the same. Anyhow, I did a make clean followed by make all and now it finished without errors. So, problem solved, but I have no idea

Re: [fpc-pascal] Fixes 3.2: make all fails

2018-12-31 Thread Bart
Also, rpm -i fpc-3.0.4-1.src.rpm seems to do nothing? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Fixes 3.2: make all fails

2018-12-31 Thread Bart
/fixes_3_2/ Then tried ~/devel/fpc/3.2.0-fixes>make all This fails with: make -C utils all . . ./fpmake compile --localunitdir=.. --globalunitdir=../packages --os=linux --cpu=x86_64 -o -Ur -o -Xs -o -O2 -o -n -o -Cg -o -dx86_64 -o -dRELEASE --compiler=/home/bart/devel/fpc/3.2.0-fixes/compil

Re: [fpc-pascal] Rest in peace Martin Schreiber

2018-12-27 Thread Bart
On Thu, Dec 27, 2018 at 4:48 AM Dennis wrote: > > Rest in peace Martin Schreiber. That's very sad news indeed. -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Generics question

2018-12-02 Thread Bart
for this is not (to me at last). Does anybody know why? Bart -- Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] odd compiling + linking error (with invalid casting of Exp)

2018-10-30 Thread Bart
On Mon, Oct 29, 2018 at 5:49 PM Dmitry Boyarintsev wrote: > It gives the linking error: > sample.pas(17,1) Error: Undefined symbol: > SYSTEM_::=::\_EXP$EXTENDED::=::\EXTENDED > sample.pas(17,1) Fatal: There were 1 errors compiling module, stopping Same with fpc trunk r

Re: [fpc-pascal] Docs: portability differences between Borland/FPC

2018-08-18 Thread Bart
On Sat, Aug 18, 2018 at 11:52 PM, Bart wrote: > TurboPascal 6.0 will not do that. It will execute the else statment if Just ignore my above post. Made a typo in the if condition.... Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.

Re: [fpc-pascal] Docs: portability differences between Borland/FPC

2018-08-18 Thread Bart
{$R-}) if I > 99 then Writeln('This is not a Percentage') else writeln('I = ',I); It will print: I = 100 Tested with TP 6.0 on FreeDos 1.2 Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] GetAppConfigDir(False) in a Citrix environment

2018-07-19 Thread Bart
rotocolID of WTS_PROTOCOL_TYPE_CONSOLE: Result := 'WTS_PROTOCOL_TYPE_CONSOLE'; WTS_SESSION_TYPE_ICA: Result := 'WTS_PROTOCOL_TYPE_ICA'; WTS_SESSION_TYPE_RDP: Result := 'WTS_PROTOCOL_TYPE_RDP'; else Result := 'WTS_SESSION_TYPE_UNKNOWN'; end;//case end; Now only the hard part remains

Re: [fpc-pascal] fpdoc error with XML parsing

2018-07-03 Thread Bart
inside comment declaration" and it points at the "m" (from macro). Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] GetAppConfigDir(False) in a Citrix environment

2018-07-02 Thread Bart
slate all that into pascal? If so, do you care to share it? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] GetAppConfigDir(False) in a Citrix environment

2018-06-28 Thread Bart
xist anymore. So this location is pretty useless. Any thoughts on retrieving the sensible place to store configuration files in such an environment, or how to detect I'm in such an environment? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org h

Re: [fpc-pascal] Feature announcement: Dynamic array extensions

2018-05-25 Thread Bart
an Push(arr, value) and it’s not > clear if we can add this ourselves easily without making tons of overloads. Add() would sound more logical to me then. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin

Re: [fpc-pascal] testing if a float has a fractional part

2018-05-15 Thread Bart
On Tue, May 15, 2018 at 7:05 PM, Jonas Maebe <jo...@freepascal.org> wrote: >> If Frac(x) equals zero, will Int(x) cahnge the bitpattern of x then? >> (Or: it cannot be gueranteed that this will not be the case?) > > > That canno

Re: [fpc-pascal] testing if a float has a fractional part

2018-05-15 Thread Bart
kup) uses 47 function SameValue(aGot, aExpected: Double): Boolean; 48 begin 49 if IsNan(aExpected) then 50 Result := IsNan(aGot) 51 else 52 Result := aGot = aExpected; 53 end; Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal

Re: [fpc-pascal] testing if a float has a fractional part

2018-05-15 Thread Bart
t the value can always be > represented exactly a sum of power-of-two's). Just curious. If Frac(x) equals zero, will Int(x) cahnge the bitpattern of x then? (Or: it cannot be gueranteed that this will not be the case?) Bart ___ fpc-pascal maill

Re: [fpc-pascal] Copy dynamic array

2018-05-15 Thread Bart
of TSomeType; SetLength(a, 5, 5); a[0,0] := VarOfTSomeType; b := copy(a); a[0,0] := SecondVarOfTSomeType; writeln(b[0,0]); //prints SecondVarOfTSomeType. You would need to do b[i] := copy(a[i]) in a loop to copy the data. Bart ___ fpc-pasca

Re: [fpc-pascal] Proposal for new Free Pascal logo

2018-04-02 Thread Bart
On Mon, Apr 2, 2018 at 3:34 AM, Mr Bee via fpc-pascal <fpc-pascal@lists.freepascal.org> wrote: > The proposed logo is updated. I think it's a nice logo. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepasca

Re: [fpc-pascal] GetLocaleInfo returns ZZZ

2018-02-28 Thread Bart
SISO639LANGNAME -> nl LOCALE_SISO3166CTRYNAME -> NL LOCALE_SISO639LANGNAME2 -> nld LOCALE_SISO3166CTRYNAME2 -> NLD Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] GetLocaleInfo returns ZZZ

2018-02-21 Thread Bart
Maybe the same as: http://www.hu.freepascal.org/lists/fpc-devel/2011-January/023648.html Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] RunError(215) occurs only in win 64 bit, not win 32 bit

2018-01-24 Thread Bart
On Wed, Jan 24, 2018 at 12:59 PM, Marco van de Voort <mar...@stack.nl> wrote: > Which seems correct. The expression to compare with is entirely longword and > it gets negative (5+5) - (10+10). But shouldn't it then also give the same error if compiled for 3

Re: [fpc-pascal] Freepascal CLI library

2018-01-14 Thread Bart
efault: Char; CaseSensitive: Boolean): Char; function for that in the TP era. (It used crt unit though. And TCharSet = set of Char) Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Crash in Math.SameValue()

2017-12-22 Thread Bart
Delphi do the same (I cannot test myself)? B.t.w.: writeln(E2); // gives 'NaN'; writeln(IsNas(E2)); //gives FALSE Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] TFloatHelper.BuildUp() question

2017-12-15 Thread Bart
On Fri, Dec 15, 2017 at 1:36 PM, Bart <bartjun...@gmail.com> wrote: > Procedure BuildUp(const ASignFlag: Boolean; const AMantissa: QWord; > const AExponent: Integer); Basically the current implementation does this: Self := 0.0; TExtended80Rec(Self)._Exp:=(TExtended80Re

Re: [fpc-pascal] TFloatHelper.BuildUp() question

2017-12-15 Thread Bart
TFLOATHELPER.BuildUp() implementation in > syshelpf.inc. > > And when I hit Alt+Up, it takes me back to declaration in syshelph.inc, but > to TSingleHelper! Yep, it does not like the clever implementation (defining types and then using the same code by including the same i

[fpc-pascal] TFloatHelper.BuildUp() question

2017-12-15 Thread Bart
Frac: 0800 S = 5.0E-01 Sign: + Mantissa: Exp: 007E Frac: 0800 What am I doing wrong here? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin

Re: [fpc-pascal] Math.MinExtended value

2017-12-15 Thread Bart
: Extended = 3.64519953188247460253e-4951; This would be the equivalent of Math.MinExtended I guess. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Math.MinExtended value

2017-12-14 Thread Bart
3.64519953188247460253E-4951 seems to be the lowest value I can get while testing (Win 32 bit). What's up with that? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] linker failed with fpc rpm on CentOS 7

2017-12-13 Thread Bart
hen these files are somewhere on your system (I forgot how to ask gcc to tell you), then you can adjust the library path in fpc,cfg accordingly. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailm

Re: [fpc-pascal] FPC install on windows with limited rights

2017-11-02 Thread Bart
rivileges for that). Otherwise just copying the entire fpc folder (and adjusting fpc.cfg) should be enough for running and building from Lazarus. (Did that on Win98, because the fpc installer needs XP or higher) Bart ___ fpc-pascal maillist - f

Re: [fpc-pascal] FPC vs. Lazarus regarding some units...

2017-10-29 Thread Bart
> > MMSystem is not delivered with Lazarus. I don't know what you are writing > about. MMSystem is delivered with fpc (at least with my current version: 3.0.4rc1). Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.

Re: [fpc-pascal] StringOfChar for Unicode/Widestring

2017-08-23 Thread Bart
On 8/21/17, Bart <bartjun...@gmail.com> wrote: > (which may tell you more about me that fpc). OK, that makes no sense... I meant to say: (which may say more about me,than it may say about fpc) Bart ___ fpc-pascal maillist - f

[fpc-pascal] StringOfChar for Unicode/Widestring

2017-08-21 Thread Bart
Hi, Do we have a StringOfChar function for UnicodeString/WideString in FreePascal? I could not find it in 3.0.4RC1 (which may tell you more about me that fpc). Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http

Re: [fpc-pascal] Super Large Integer Math Calculations

2017-07-07 Thread Bart
It's not lightning fast, but there is room for optimization I guess. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Ignoring function results

2017-05-20 Thread Bart
llows you to drop the result of a function. This means that you can use a function call as if it were a procedure. By default this feature is on. You can switch it off using the {$X-} or {$EXTENDEDSYNTAX OFF}directive." Bart ___ fpc-pascal m

Re: [fpc-pascal] FPC Graphics options?

2017-05-11 Thread Bart
to Lazarus (GUI) is not an option? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Cross compile linux->solaris?

2017-04-28 Thread Bart
-> solaris? The error messages upon "compiling" a perl script are a PITA compared to the messages from the fpc compiler. PERL: Syntax error line 3 near print (line 3 being the last and empty line of the file) Freepascal: Fatal: Syntax error, ";" expected but "ide

Re: [fpc-pascal] Bug in documentation for Random?

2017-04-05 Thread Bart
http://docwiki.embarcadero.com/RADStudio/Tokyo/en/Random "random returns a random number between 0 and abs(num-1)" IIUC, then Random() shoud always return a positive number. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepasca

Re: [fpc-pascal] Bug in documentation for Random?

2017-04-05 Thread Bart
Fun fact: TP's random used an unsigned parameter (word), so no ambiguity there. Random (function) -- Returns a random number. Declaration: function Random [ ( Range: Word) ]: < Same type as parameter >; Bart ___ fpc-pascal ma

Re: [fpc-pascal] Bug in documentation for Random?

2017-04-05 Thread Bart
26112 Random(-10) = -1774796928 Random(-10) = 1443026331 Random(-10) = -919853036 Random(-10) = -747947900 Random(-10) = -1767321924 Random(-10) = -2114448955 Random(-10) = 1499268340 Random(-10) = -1658783534 (which makes no sense at all to me...) Bart __

[fpc-pascal] Bug in documentation for Random?

2017-04-05 Thread Bart
m(-10)); end. C:\Users\Bart\LazarusProjecten>test random(-10) = -1 C:\Users\Bart\LazarusProjecten>test random(-10) = -4 Maybe my understanding of English ("strictly less than") is not correct, so I ask here before posting as a bugreport. Bart ___

Re: [fpc-pascal] TThread.OnTerminate ?

2017-03-19 Thread Bart
On 3/19/17, fredvs <fi...@hotmail.com> wrote: > I am loosed. lost is probably the word you're looking for ;-) > procedure OnTerminate(sender: Tobject); override; > ... try procedure DoTerminate; override; Bart ___ fpc-pascal maillist

Re: [fpc-pascal] Forward Generic Type Declaration Bug

2017-03-19 Thread Bart
On 3/19/17, Bart <bartjun...@gmail.com> wrote: > r35221 (a bit old maybe) gives an IE. Still present in r35625 (today). Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Forward Generic Type Declaration Bug

2017-03-19 Thread Bart
rch in the bugtracker for this IE showed: http://bugs.freepascal.org/view.php?id=26452 (Internal error 2012101001 with forward template declaration). It's the same issue I guess? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.f

Re: [fpc-pascal] Forward Generic Type Declaration Bug

2017-03-19 Thread Bart
On 3/19/17, Sven Barth via fpc-pascal <fpc-pascal@lists.freepascal.org> wrote: > With that I agree. Would you please check with 3.1.1 and if it's still the > case there report a bug so that this isn't forgotten? r35221 (a bit old maybe) gives

Re: [fpc-pascal] Forward Generic Type Declaration Bug

2017-03-18 Thread Bart
On 3/18/17, Sven Barth via fpc-pascal <fpc-pascal@lists.freepascal.org> wrote: > Forward declarations for generic types are not supported. But it should not give an internal error. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal

Re: [fpc-pascal] KeyDown routine and Ctrl+Q

2017-02-08 Thread Bart
On 2/8/17, Jürgen Hestermann <juergen.hesterm...@gmx.de> wrote: > > But when I type "Ctrl+Q" then "Key" is 17 instead of VK_Q (81). I get $51 for the key when I press Ctrl+Q (Win32). Bart ___ fpc-pascal maillist -

Re: [fpc-pascal] Deleting 'Nonexistent' files under windows

2017-01-24 Thread Bart
it and would not let me remove the file and folder. I rewote my test program to remove them, but still Windows refused. (The folder name ended in a space, you could not even browse to the folder in Windows Explorer) I then booted a live Linux distribution and removed it from there. No problem whats

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

2017-01-15 Thread Bart
es. Typically the bindled compiler that comes with Lazarus is in $(Lazarus)/fpc/$(FPCVer)/ and a stand alone installation of fpc will default to c:\pp (on Windows). I install fpc seperately and have all my fpc compilers and their sources in c:\devel\fpc\$(FPCVer), which makes it easier in

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

2017-01-15 Thread Bart
piler. Just install fpc 2.6.4 and 2.6.4 sources. In Lazarus options set the correct path to the compiler and compiler sources. Then rebuild Lazarus clean. For projects you need the 3.0 compiler, just switch back the paths, do a clean rebuild and you're

Re: [fpc-pascal] FPC 3.0.0 seed compiler for Rasperry Pi ARM?

2017-01-09 Thread Bart
On 1/9/17, Bo Berglund <bo.bergl...@gmail.com> wrote: > Or could I skip the sourceinstall part and just point lazarus to the > downloaded sources from SVN from which fpc was built? Generally speaking, for Lazarus that is enough. Sources are needed for CodeTools, not for compiling/bui

Re: [fpc-pascal] Untyped var params

2017-01-07 Thread Bart
T_SINGLE: PSingle(@Y)^:=3; > T_DOUBLE: PDouble(@Y)^:=3; > end; > end; OK, I can imagine more complex examples where this may come in handy. And thanks for the rest of the explanation. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepas

Re: [fpc-pascal] Untyped var params

2017-01-07 Thread Bart
he type of Y, so why not write then procedure X(var Y: Integer); begin Y := 3; end; FillChar OTOH _is_ a good example of why you would use an untype var parameter. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Untyped var params

2017-01-07 Thread Bart
On 1/7/17, Andrew Hall <andrew.h...@shaw.ca> 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 then use an untyped var paramete

Re: [fpc-pascal] ppcjvm issues

2017-01-07 Thread Bart
On 1/7/17, Tomas Hajny <xhaj...@hajny.biz> wrote: > I can't comment the first part, but where exactly is a type named "float" > defined in FPC (which unit)? Float is defined in math unit. It is an alias to float128, if that type exists, else extende, or else to double, or

Re: [fpc-pascal] Readln a password

2017-01-03 Thread Bart
I wrote > 2 years ago. You could have backspace and escape in your password ;-) I later implemented an inputfield (using crt unit and reading key-input using BIOS routines) that behaved just like an edit control, so it would correctly handle left, right, delete, backspace etc. Ahh, the good old

Re: [fpc-pascal] Question on type helpers

2017-01-02 Thread Bart
file? > > I think we have a generator for it in utils or so. I've never used it > however... I just copied the 3.0 config and did a search and replace on the paths. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepasca

Re: [fpc-pascal] Question on type helpers

2017-01-02 Thread Bart
On 1/1/17, Bart <bartjun...@gmail.com> wrote: > Now I need to check wether the 3.0.2 RC1 does too. > If it is inddeed r33214 that fixed it, I think it is in 3.0 fixes. > We'll see (but not today). Compiles OK with 3.0.2RC1. Bart ___

Re: [fpc-pascal] Question on type helpers

2017-01-01 Thread Bart
blesome code just fine. Now I need to check wether the 3.0.2 RC1 does too. If it is inddeed r33214 that fixed it, I think it is in 3.0 fixes. We'll see (but not today). PS How can I get the "make install" to generate a fpc.cfg file? Bart _

Re: [fpc-pascal] Question on type helpers

2017-01-01 Thread Bart
On 1/1/17, Sven Barth <pascaldra...@googlemail.com> wrote: > Could indeed be the case due to codepaged strings being different types. > I think there already is a bug report along those lines... You mean http://bugs.freepascal.org/view.php?id=2

Re: [fpc-pascal] Question on type helpers

2016-12-31 Thread Bart
On 12/31/16, Bart <bartjun...@gmail.com> wrote: > NB. These are my compiler options: > -MObjFPC -Scghi -Cirot -g -gl -gh -l -vewnhibq -Filib\i386-win32 -Fu. > -FUlib\i386-win32 -FcUTF8 When I remove the -FcUTF8, compilation succeeds. This sounds like a bug to me. B.t.w. I canno

Re: [fpc-pascal] Question on type helpers

2016-12-31 Thread Bart
ted but "INSERT" found But why does it not fail then at the uncommented line that also calls the Insert method? NB. These are my compiler options: -MObjFPC -Scghi -Cirot -g -gl -gh -l -vewnhibq -Filib\i386-win32 -Fu. -FUlib\i386-win32 -FcUTF8 Bart _

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

2016-12-31 Thread Bart
?view=markup) and bugs can be reported in fpc bugtracker? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

[fpc-pascal] Question on type helpers

2016-12-31 Thread Bart
; end. This compiles fine. But when you move the declaration of TAHelper to the implementation section, then you get a compiler error: thtest.pp(21,5) Fatal: Syntax error, "CREATE" expected but "DOIT" found Line 21 is A.DoIt; I'm using fpc 3.0.0 (32-bi

Re: [fpc-pascal] Linux installation, where to put fpc?

2016-12-31 Thread Bart
ot;fpc" will open the last installed version. Note: I never build fpc or change it's source files, so I'm with them being in a location that I have no write access to. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists

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

2016-12-29 Thread Bart
On 12/29/16, Bart <bartjun...@gmail.com> 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 better way (it should never have depended on

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

2016-12-29 Thread Bart
to populate a 2-dimesional table-like structure, and this fails due to this behaviour of FastHtmlParser. Is this intended behaviour? If so, could it be made configurable to do fire the OnFoundText event in such cases? Bart ___ fpc-pascal maillist - fpc

Re: [fpc-pascal] Test file mode question

2016-10-25 Thread Bart
On 10/25/16, Rolf Grunsky <rgrun...@sympatico.ca> wrote: > If (SFile.Mode = fmClosed) Then Rewrite(SFile); Maybe cast SFile to TextRec(SFile)? Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bi

Re: [fpc-pascal] How to know the encoding of a string?

2016-10-17 Thread Bart
way. Lazarus comes with lconvencoding unit which has a guessencoding function. Maybe this can be of some help to you? (Ruling out a string is UTF8 (compatible) can be done 100%) Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.

Re: [fpc-pascal] server down?

2016-10-17 Thread Bart
pascal.org/view.php?id=29452 Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

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

2016-10-17 Thread Bart
hack to me. A direct access to > system variables is inelegant to my unexperienced eye but YMMV. I can see your reasoning. Again: file a feature request (with the above argumentation) in the bugtracker. Attach a patch, this will increase the likelyhood it'll be looked in

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

2016-10-16 Thread Bart
tem.ExitCode is meant for returning exitcodes. an overloaded TCustomApplication.Terminate(AExitCode: Integer) might be nice to have though. You could file it as a feature request in the bigtracker. Bart ___ fpc-pascal maillist - fpc-pascal@list

Re: [fpc-pascal] Error: Identifier not found "Heap Error"

2016-10-16 Thread Bart
On 10/16/16, Mark Morgan Lloyd <markmll.fpc-pas...@telemetry.co.uk> wrote: > I've got a 5.0 manual to hand [blows dust off, coughs]. See: http://putka.upm.si/langref/turboPascal/0683.html Bart ___ fpc-pascal maillist - f

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

2016-10-13 Thread Bart
ode; end; air2.lpr(54,35) Error: identifier idents no member "ExitCode" Probably you can set system.ExitCode before calling Terminate. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] The Next Release

2016-10-13 Thread Bart
e of cardiac arrest in the process. Bart ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] Issue 24504

2016-10-12 Thread Bart
eless: any code that relied on the wrong behaviour would NOT have worked cross-platform (at least the unix implementation behaves as documentation says with regard to this issue). [/nitpickig mode] Bart ___ fpc-pascal maillist - fpc-pascal@lists.free

[fpc-pascal] Issue 24504

2016-10-12 Thread Bart
Hi, I attached a trivial patch for issue #24504: Dos.FSearch wrong result using joker-signs (http://bugs.freepascal.org/view.php?id=24504) in the bugtracker. Can some devel review? If accepted it would be nice to include in 3.0.2 release. Bart

Re: [fpc-pascal] Are the TEncoding singletons thread-safe?

2016-08-11 Thread Bart
4657705/3268398> using the XE's > AtomicCmpExchange() function before return any TEncoding global instance. .. > I could send a patch to solve it, I hope you did not look at the Delphi sourcecode to see how it was implemented, because that would now make a "clean room" i

<    1   2   3   4   5   >