fpc-devel · 2025-11
- generics syntax question1
It is possible in const (anywhere where a const can be given, not just const blocks) to be able to: - access values inside structures - take the address of a field. That…
- Strange error / Why / generic in wrapper class2
The first 2 procedures show that var v2: TWrap1.specialize TTest4<TObject>; is valid. The generic can be specialized directly for the variable. But, if…
- GetDiskFreeSpaceExW implementation4
MS defines GetDiskFreeSpaceExW as follows: (https://learn.microsoft.com/en-us/windows/win32/api/fileapi/nf-fileapi-getdiskfreespaceexw) BOOL GetDiskFreeSpaceExW( [in,…
- Issue with const constraint in Delphi mode specialize (Fun with Delphi mode)0
It appears the below code can distinguish between the 2 TFoo (generic vs constant). But if the constraint to the generic is an "const integer" then how to you specialize…
- Impossible CONST generic constraints in forward declarations...?3
According to https://forum.lazarus.freepascal.org/index.php/topic,52157.msg383991.html#msg383991 1) Contstraint given in the interface declaration MUST be dropped in the…
- generics defy scoping rules -- Intended?8
Normally, if I refer to a type then the first type found by the name will be taken => and if that type is not compatible, then I get an error. => See Example 2 But, if I…
- inconsistent source parsing ? (deprecated)1
In the below code, foo is accepted, and using foo issues the note that it is deprecated. So having a "deprecated" after the "cdecl; " works. But only with "= nil". the…
- TFile.ReadAllBytes broken in 3.2.4RC15
TFile.ReadAllBytes (in System.IOUtils) seems to alwasy return TBytes filled with zero's. It's implemented as (See:…
