Hi,
I'm almost fourteen years on the forum and a few years less on mailing lists
and I never had a single problem.
I don't attend IRC so I can't say what's wrong there.
OTOH I read Joanna's comments on the forum and they are OK (to the topic; non
conflict).
V.
_
Hi,
you can use PChar, or string+retype to PChar in blockwrite:
BlockWrite(f1, PChar(s)^, length(s));
which gives expected result.
V.
__
Od: "Travis Siegel via fpc-pascal"
Komu: "FPC-Pascal users discussions"
Datum: 05.03.2023
der Sluis via fpc-pascal"
Komu: fpc-pascal@lists.freepascal.org
Datum: 12.01.2023 00:22
Předmět: Re: [fpc-pascal] Dynamic array question
Vojtěch Čihák via fpc-pascal schreef op wo 11-01-2023 om 23:38 [+0100]:
> is there a way how to have dynamic array "inside" another dynamic
Hi,
is there a way how to have dynamic array "inside" another dynamic array?
program project1;
{$mode objfpc}{$H+}
uses
{$IFDEF UNIX}
cthreads,
{$ENDIF}
Classes, SysUtils
{ you can add units after this };
{$R *.res}
type
TDynArray = array of Integer;
PTDynArray = ^TDynArray;
T and generics
Am 31.12.2022 um 14:34 schrieb Vojtěch Čihák via fpc-pascal:
> Is this intended? Or known bug?
It's a bug. Please report with a full example.
Regards,
Sven
___
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
https://
Hi,
I have local type TTempItem, i.e. declared inside method of a generic class.
When I write:
type
TTempItem = record
Item: T;
Empty: Boolean;
end;
I got: Identifier not found "T".
When I write:
type
TTempItem = record
Item: TBaseGList.T; //name of the cla
"FPC-Pascal users discussions"
Datum: 18.11.2022 20:45
Předmět: Re: [fpc-pascal] How to inline CompareFunc to Sort method in generic
abstract class
Em seg., 14 de nov. de 2022 15:26, Vojtěch Čihák via fpc-pascal > escreveu:,What do you mean by "be inlined"? The
Hi,
I wrote a generic abstract class - a list based on dynamic array (i.e. array of
T;) and this class can be specialized elsewhere with any type (records or
classes).
Part of the class is sorting. There are more ways how to deliver *compare
function* to sorting method. I can pass it as a para
Sorry, it was copy-paste from github and it broke formatting
do {
v1 = XXH32_round(v1, XXH_get32bits(input)); input += 4;
v2 = XXH32_round(v2, XXH_get32bits(input)); input += 4;
v3 = XXH32_round(v3, XXH_get32bits(input)); input += 4;
v4 = XXH32_round(v4, XXH_get32bits(inp
Hi,
I noticed this too a few years ago when I translated xxHash from C to FPC.
Pushing the code to less lines improved speed so xxHash32 was as fast as in C.
do { v1 = XXH32_round(v1, XXH_get32bits(input)); input += 4; v2 = XXH32_round(v2,
XXH_get32bits(input)); input += 4; v3 = XXH32_round(v
On 20/10/2022 00:24, Vojtěch Čihák via fpc-pascal wrote:
That's not easy, unfortunately: https://www.youtube.com/watch?v=r-TLSBdHe1A
<https://www.youtube.com/watch?v=r-TLSBdHe1A>
Jonas
___
fpc-pascal maillist - fpc-pa
solve it reversely:
-OaJUMP=1 to -OaJUMP=2.
Of course, I'd like some persistent solution.
V.
__
Od: "Vojtěch Čihák via fpc-pascal"
Komu: "FPC-Pascal users discussions"
Datum: 19.10.2022 17:39
Předmět: Re:
oblem.
__
Od: "Vojtěch Čihák via fpc-pascal"
Komu: "FPC-Pascal users discussions"
Datum: 19.10.2022 15:37
Předmět: [fpc-pascal] Problem with code aligning (probably)
Hi,
...
Thanks for help.
__
Hi,
I wrote a generic class to test sorting algorithms and also benchmarking them.
I have following problem:
When I change even a single line of code anywhere in that unit, even in an
unrelated method, all ~40 algorithms become a little slower or a little faster.
I observed it has two levels
Hi,
my numbers of Lazarus on Linux, Qt (incl. binaries and *.ppu and *.o files)
SVN:
lazarus dir: 2.6 GB (4 files, 1300 dirs)
.svn subdir: 1.6 GB (25000 files, 260 dirs)
GIT:
lazarus dir: 1 GB (15000 files, 950 dirs)
.git subdir: 150 MB (60 files, 40 dirs)
V.
Hi,
Laz2_ are UTF8 versions and they works well.
Create(nil); means that instance has no owner.
(I have Lazarus 2.3.0, it is not on line 165 here).
You can try demo at ../examples/xmlstreaming/.. It works here.
V.
__
Od: "Abuy
Hello and thanks.
I downloaded 3.2.2 (tar), I installed it successfully.
I used it to compile the latest 3.3.1 trunk, again successfully.
And I used this 3.3.1 to build the Lazarus 2.1.0 trunk (65138). Also
successfully.
Everything seems be OK.
Vojtěch a.k.a. Blaazen
Hi,
I tried this (add StrUtils to uses):
procedure TForm1.Button1Click(Sender: TObject);
var i, l: Integer;
aV: Double;
aF: TFormatSettings;
begin
aF.DecimalSeparator:='.';
aF.ThousandSeparator:=' ';
for i:=-2 to 10 do
begin
aV:=pi*power(10, i);
l:=length(intToStr
Hello,
look at this bugreport. I reported it as a Lazarus issue but now it looks like
FPC trunk issue.
https://bugs.freepascal.org/view.php?id=37856
Vojtech aka Blaazen
__
Od: "C Western via fpc-pascal"
Komu: fpc-pascal@lists.fre
I looked to code, it gives error only when map is Sorted=True.
function TFPSMap.Add(AKey: Pointer): Integer;
begin
if Sorted then
begin
if Find(AKey, Result) then
case Duplicates of
dupIgnore: exit;
dupError: Error(SDuplicateItem, 0)
end;
end else
Result
it comfortably
MyList[1].Port:='abc';
V.
______
Od: "Vojtěch Čihák via fpc-pascal"
Komu: ja...@productionautomation.net, "FPC-Pascal users discussions"
Datum: 08.09.2020 16:21
Předmět: Re: [fpc
Hi,
I used TFPObjectList only once, for visual component TECAccordion
(https://wiki.lazarus.freepascal.org/Eye-Candy_Controls#TECAccordion). Each
item of list is derived from TWinControl so it is possible to use it even for
visual components (like TCollection).
However, in your case (record
I suspect Embarcadero that they often intently design Delphi to be not
compatible with FPC.
V.
__
Od: "Sven Barth via fpc-pascal"
Komu: fpc-pascal@lists.freepascal.org
Datum: 09.07.2020 07:30
Předmět: Re: [fpc-pascal] LongInt and LongW
There is TFPGObjectList for objects.
BTW, is FGL a good choice for generics? Some time ago Marco wrote here that FGL
is moreless a technology demonstrator and Generics.Collection or other
libraries should be used instead.
Thanks for reply
V.
__
Hi,
I found this article: https://drewdevault.com/2020/01/04/Slow.html
but FPC is missing, so I wrote simple:
program Project1;
begin
writeln('Hello world!');
end.
$ fpc -O3 -XX Project1.pas
$ strace -C ./Project1
% time seconds usecs/call calls errors syscall
-- -
25 matches
Mail list logo