Recent

Author Topic: Windows API definitions/prototypes  (Read 5217 times)

ASerge

  • Hero Member
  • *****
  • Posts: 2240
Re: Windows API definitions/prototypes
« Reply #15 on: February 05, 2019, 01:05:08 pm »
For external APIs that don't use managed types (e.g. those Windows APIs that do not use interfaces) there shouldn't be a difference.
That is, it turns out that the conversion in the Windows API "var" to "out" constraints only a large amount of work, and there are no other reasons.

BeniBela

  • Hero Member
  • *****
  • Posts: 906
    • homepage
Re: Windows API definitions/prototypes
« Reply #16 on: February 05, 2019, 01:38:52 pm »
Here is a related question,  if I were to change the definitions of those APIs I use in my programs (IOW, the changes would be manual and individually tested to be correct), would there be any interested in including the "cleaned up" definitions of those APIs ?  (this question is _mostly_ to determine if any effort on my part in that regard could benefit other people, if it wouldn't then, I would most likely not do it.)

Obviously, the number of APIs I would update would also be very limited compared to the number of APIs available.  I doubt it would exceed a few hundreds at most.

That would be really helpful

I had already opened a bug report for this

440bx

  • Hero Member
  • *****
  • Posts: 4014
Re: Windows API definitions/prototypes
« Reply #17 on: February 05, 2019, 02:17:35 pm »
That would be really helpful
I certainly understand the developers reluctance of doing it as a "project" assigned to one individual.  In the case of FPC, it seems to me that the FPC/Lazarus user community could "pitch in" cleaned up definitions and little by little end up with definitions that are as clean as they can be,

It would be rather nice too if the contributor included some simple program (in many cases a short console program) that would exercise the definition(s) being contributed to demonstrate the new definition(s) is/are correct.    Maybe establishing some rules of how such specific contributions must be made would help.  After all, it is a fact that there has to be - should be - one individual to verify and accept the contribution and, it's important to make that individual's job as simple and straightforward as possible.

The beauty of open source is that everyone can contribute and the aggregate of many small contributions often lead to a better result than one individual could ever achieve.  I believe we should take advantage of that and create "structures" to submit and validate specific changes - such as API declarations.

Just thinking out loud...




(FPC v3.0.4 and Lazarus 1.8.2) or (FPC v3.2.2 and Lazarus v3.2) on Windows 7 SP1 64bit.

 

TinyPortal © 2005-2018