Re: [fpc-devel] FPC 3.0.2 release target

2016-05-30 Thread tha...@thaddy.com
New feature. Belongs in 3.1.1. On 30-May-16 12:38 PM, Alfred wrote: I would like to support the inclusion of interface RTTI. Included a patch for this ! Thanks. ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/cgi

Re: [fpc-devel] FPC 3.0.2 release target

2016-05-30 Thread tha...@thaddy.com
It says fixed in 3.1.1. It doesn't say it would be back-ported, but indeed you can request it. And indeed in this case I support your request. (Since it was an oversight in the first place?) I have no clue if this is easy to do, but I think it is warranted. Regards, Thaddy On 30-May-16 12:42

Re: [fpc-devel] C flags, enums, sets, and the "Pascal way"

2016-04-02 Thread tha...@thaddy.com
Well, h2pas gives you: {$packrecords c} type VkFlags = uint32_t; VkSparseImageFormatFlagBits = (VK_SPARSE_IMAGE_FORMAT_SINGLE_MIPTAIL_BIT := $0001, VK_SPARSE_IMAGE_FORMAT_ALIGNED_MIP_SIZE_BIT := $0002, VK_SPARSE_IMAGE_FORMAT_NONSTANDARD_BLOCK_SIZE_BIT := $000

Re: [fpc-devel] Feature announcement: Record management operators

2016-03-07 Thread tha...@thaddy.com
You mean really,really,smart pointers and the introduction of the comma into the language? On 07-Mar-16 3:37 PM, Maciej Izak wrote: 2016-03-07 15:34 GMT+01:00 Kazantsev Alexey >: It's cool! What about Copy or CopyRecord? Work in progress. Will be probabl

Re: [fpc-devel] Ability to handle instance pointers as ordinal type.

2016-02-21 Thread tha...@thaddy.com
I knew that... It is a suggestion to extend the syntax. Sven explained how it could work. On 21-Feb-16 12:16 PM, Ewald wrote: The first case will compile, the second will not, failing with a "Constant Expression expected". So, if you would somehow know the instance pointers at compile time,

Re: [fpc-devel] Ability to handle instance pointers as ordinal type.

2016-02-21 Thread tha...@thaddy.com
It is also about notational convenience. In that sense it belongs to the language level and not in the library domain. And it is somewhat obvious to have. (I know I am not the only one who at some point in time was surprised you couldn't easily use instance pointers as ordinals) On 21-Feb-16

Re: [fpc-devel] Ability to handle instance pointers as ordinal type.

2016-02-21 Thread tha...@thaddy.com
That's exactly what I use (a dictionary) to circumvent this language limitation and use a case expressively. I feel though, it is a limitation that could be solved. On 21-Feb-16 11:58 AM, Maciej Izak wrote: No much sense for me. Just use dictionary, for example TDictionary from Generics.Coll

Re: [fpc-devel] Ability to handle instance pointers as ordinal type.

2016-02-21 Thread tha...@thaddy.com
13:37, tha...@thaddy.com: ___ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

[fpc-devel] Ability to handle instance pointers as ordinal type.

2016-02-21 Thread tha...@thaddy.com
I have been pondering with that idea ever since the implementation of strings for case. This morning I remembered again why it may be useful. Consider this code vs the alternative I suggest. Plz. do not value the code, it is just copied from the forum and frankly not the point but an illustra

Re: [fpc-devel] Supported start compiler for trunk

2016-02-02 Thread tha...@thaddy.com
Point duly taken. (But I knew) On 02-Feb-16 5:53 PM, Sven Barth wrote: Am 02.02.2016 14:51 schrieb "tha...@thaddy.com <mailto:tha...@thaddy.com>" <mailto:tha...@thaddy.com>>: > > Yes. It is in the wiki. (Sigh) > But there is an argument to be made to al

Re: [fpc-devel] Supported start compiler for trunk

2016-02-02 Thread tha...@thaddy.com
Yes. It is in the wiki. (Sigh) But there is an argument to be made to allow fixes branch. On 02-Feb-16 11:54 AM, Alfred wrote: While trying to build trunk, I encountered the following peculiarity. Building trunk with 3.0.0 : ok. Building trunk with 3.0.1 (fixes ios) : not allowed due to wrong v

Re: [fpc-devel] Random thread-safe

2016-01-28 Thread tha...@thaddy.com
The point is partially more or less at the end of the link I included. The reference to the Rdrand Which means software should take advantage of hardware when possible. But it is about more than that. An

Re: [fpc-devel] Random thread-safe

2016-01-28 Thread tha...@thaddy.com
Then wouldn't it be possible to make PRNG's plugable. The Mersenne twister is still good as it is but definitely not suitable for every and any case. Marsialigla's might be a better choice nowadays. And the seeding can nowadays often been done from reading hardware random, like on the Raspberry

Re: [fpc-devel] Array of char

2015-02-25 Thread tha...@thaddy.com
No, it's about the K&R compatibility. That's all, nothing more, nothing less. It has always been there for an array of char (old c style, now ansichar) ) in Delphi. On 25-Feb-15 6:08 PM, Jonas Maebe wrote: On 25/02/15 17:02, tha...@thaddy.com wrote: @ Florian. You closed the

Re: [fpc-devel] Array of char

2015-02-25 Thread tha...@thaddy.com
My bad, hidden post #0 On 25-Feb-15 5:02 PM, tha...@thaddy.com wrote: @ Florian. You closed the typecast from array of char to string issue. Maybe you are right, I just can prove that every d2-xe7 adds a #0, so a cast (partially, agreed) works in delphi and not in fpc. I suggest you

[fpc-devel] Array of char

2015-02-25 Thread tha...@thaddy.com
@ Florian. You closed the typecast from array of char to string issue. Maybe you are right, I just can prove that every d2-xe7 adds a #0, so a cast (partially, agreed) works in delphi and not in fpc. I suggest you reconsider this. The raw pointer cast should work, which means an array of char s

[fpc-devel] 64 bit ASM stack fixup code

2014-08-31 Thread tha...@thaddy.com
Hi, I am trying to do some maintenance on the X86 intel assembler writer. At the moment I am stuck on the .params macro that delphi supports. Is there an easy way to fix up 64 bit code without having to write code that supports that macro? Regards, Thaddy smime.p7s Description: S/MIME

Re: [fpc-devel] For Stocki. Regarding interfaces.

2014-08-27 Thread tha...@thaddy.com
Mm, Marco, since you were the first one to put me right (and I was referring to block rsolution, which was false) I do not think - in the light of Danny's writings - that a {$modeswitch delphibugs} is appropriate. ;) Anyway, I hope that this reconciles Stocki's thinking about the subject. De

Re: [fpc-devel] For Stocki. Regarding interfaces.

2014-08-26 Thread tha...@thaddy.com
Oh, I see. Oeps. On 26-8-2014 22:04, Sven Barth wrote: Then why haven't you make up for it and put up the link? ;) For the record, we are talking about this issue: http://bugs.freepascal.org/view.php?id=26602 Regards, Sven smime.p7s Description: S/MIME Cryptographic Signature __

Re: [fpc-devel] For Stocki. Regarding interfaces.

2014-08-26 Thread tha...@thaddy.com
Sven, I made some mistakes here as well. About 20 years ago I knew what was going on. I am sorry I didn't put the mail in the proper context. Regards, Thaddy On 26-8-2014 21:55, Sven Barth wrote: On 26.08.2014 17:27, tha...@thaddy.com wrote: Stocki, Since your report was closed

[fpc-devel] For Stocki. Regarding interfaces.

2014-08-26 Thread tha...@thaddy.com
Stocki, Since your report was closed and I didn't fully (the closing) agree with that without research, here's a part of my research: I found this reply by Danny Thorpe on stackoverflow: http://stackoverflow.com/questions/7759081/is-the-compiler-treatment-of-implicit-interface-variables-docume

[fpc-devel] New KOL 32/64 bit version 3.22 beta

2014-08-26 Thread tha...@thaddy.com
For those interested in smaller executables that perform the same as codebloated ":-X " there is a new and up to date beta Key Objects Library available. Follow this link: http://kolmck.net/kol322-x64-unofficial.7z It has been thoroughly tested during the summer and has become much more stabl

Re: [fpc-devel] Method for write string into TStreamt

2014-07-22 Thread tha...@thaddy.com
like storing the length and storing a string marker and/or use RTTI for strings, to be consistent. In practice, I use json for that kind of streaming. And that is already in place. On 22-7-2014 14:37, Dmitry Boyarintsev wrote: On Tue, Jul 22, 2014 at 6:46 AM, tha...@thaddy.com <ma

Re: [fpc-devel] How to convert set to integer and vice versay

2014-07-22 Thread tha...@thaddy.com
Yes, Marco, as you previously suspected, It does. I saw you gave already a similar answer to mine. The pointer casts are definitely not necessary, Gennady. Can you show a little example WHERE it doesn't work? In plain fpc, not lazarus code? On 22-7-2014 18:13, Marco van de Voort wrote: In o

Re: [fpc-devel] Method for write string into TStream

2014-07-22 Thread tha...@thaddy.com
You can always use KOL for that ;) But anyway: we implemented that at the cost of read-back speed and looking for zero termination, which is flawed anyway for object pascal strings, since it can contain zero's. It can be done through RTTI with my usual complaints about that sort of shit. A (a

Re: [fpc-devel] Method for write string into TStreamt

2014-07-22 Thread tha...@thaddy.com
A case for ternary computing is not really a bad idea ;) On 21-7-2014 21:42, Hans-Peter Diettrich wrote: Dmitry Boyarintsev schrieb: How about introducing a default parameter? The parameter keeps the method backward compatible, allowing write a string without the prefix. public procedure TSt

Re: [fpc-devel] How to convert set to integer and vice versa

2014-07-22 Thread tha...@thaddy.com
You will find that if you are converting from a Delphi version equal to or before Delhi 2009, the {$Mode Delphi} or -Mdelphi directive does exactly what you want. On 22-7-2014 3:37, Gennady Agranov wrote: Hi, I am new to FPC, but I do like it - thanks! We are trying to switch from Delphi to

Re: [fpc-devel] Thank You Sven Barth

2014-06-10 Thread tha...@thaddy.com
Tnx Sven. I mean it, you know that. On 10-6-2014 6:36, Sven Barth wrote: Am 09.06.2014 20:07 schrieb "Anthony Walter" >: > > Sven, > > I noticed you recently fixed many compiler issues which were in the bug tracker. I wanted give you a hearty 'Thank You' and let you k