-
Content Count
3586 -
Joined
-
Last visited
-
Days Won
176
Everything posted by David Heffernan
-
Getting PID of winword.exe based on filename
David Heffernan replied to misc_bb's topic in Windows API
Does Word use a separate process for each open document? -
Getting PID of winword.exe based on filename
David Heffernan replied to misc_bb's topic in Windows API
Does Word use a separate process for each open document? -
Did you submit a QP report yet?
-
system.zlib.pas(2958): E2065 Unsatisfied forward or external declaration: '@zcalloc'
David Heffernan replied to alogrep's topic in VCL
You could make a minimal example. The issue is surely with your program. -
system.zlib.pas(2958): E2065 Unsatisfied forward or external declaration: '@zcalloc'
David Heffernan replied to alogrep's topic in VCL
Make that minimal reproduction already -
system.zlib.pas(2958): E2065 Unsatisfied forward or external declaration: '@zcalloc'
David Heffernan replied to alogrep's topic in VCL
A minimal reproduction. The act of making one will likely show you what you did wrong. -
system.zlib.pas(2958): E2065 Unsatisfied forward or external declaration: '@zcalloc'
David Heffernan replied to alogrep's topic in VCL
Show us a minimal reproduction of the issue. Then we can talk. -
Reorganize a class / Set Of ..
David Heffernan replied to PatV's topic in Algorithms, Data Structures and Class Design
This is known to be unreliable -
Reorganize a class / Set Of ..
David Heffernan replied to PatV's topic in Algorithms, Data Structures and Class Design
type TFoo<T> = class type TSetOfT = set of T; end; The compiler reports this error for me: [dcc32 Error] E2001 Ordinal type required -
https://stackoverflow.com/questions/9360280/how-to-make-a-lib-file-when-have-a-dll-file-and-a-header-file
- 2 replies
-
- dll
- import library
-
(and 1 more)
Tagged with:
-
Reorganize a class / Set Of ..
David Heffernan replied to PatV's topic in Algorithms, Data Structures and Class Design
Of course it makes sense. Try declaring set of TObject and see how that works out. You'd need to constrain to an ordinal type with 256 or fewer elements and you can't do that with constraints. Too bad we can't have templates. -
Reorganize a class / Set Of ..
David Heffernan replied to PatV's topic in Algorithms, Data Structures and Class Design
Whilst you can't use constraints, you can use generics and RTTI to get some effective code reuse when working with enums and sets. Ideally this could be done truly generically but such is life with Delphi. -
Reorganize a class / Set Of ..
David Heffernan replied to PatV's topic in Algorithms, Data Structures and Class Design
We can't see what the class does. You've just shown the interface. -
is FMX supported RTL (Right to Left) languages?
David Heffernan replied to Y. Ghasemi's topic in FMX
I think the answer is still no. -
I cannot understand what you mean by event in component or instance. In fact I can't make any sense out of this.
-
I can't understand the question at all
-
Legacy (bad) code issues on Delphi 11.1 on 64bit VCL apps related to new ASLR linker flags
David Heffernan replied to Davide Angeli's topic in Delphi IDE and APIs
If you want to fully test your own app this is the way to go, so that you get top down allocation for all the addresses in your program. You won't necessarily find all the issues if you only do the fastmm local allocator. Using OS top down has always worked well for me. -
Legacy (bad) code issues on Delphi 11.1 on 64bit VCL apps related to new ASLR linker flags
David Heffernan replied to Davide Angeli's topic in Delphi IDE and APIs
Better is to use OS level top down allocation. -
Can undefined function result point to valid/used data in memory?
David Heffernan replied to Mike Torrettinni's topic in RTL and Delphi Object Pascal
Nothing here is "as expected". This is all undefined behaviour that is subject to change in future compiler releases. It's a mistake to read the return value before assigning to it. -
Can undefined function result point to valid/used data in memory?
David Heffernan replied to Mike Torrettinni's topic in RTL and Delphi Object Pascal
Delphi strings are managed types so they are never ill-defined in the way that unmanaged types can be before first assignment. Note that this assumes correct practise. So if you use GetMem rather than New to allocate memory for a managed type then the above statement is not correct, but then doing that would be incorrect practise. -
Range check error with TSysLogServer
David Heffernan replied to djhfwk's topic in ICS - Internet Component Suite
Maybe so. But my point about how to deal with getting a pointer from a string that may be zero length stands. So long as the use of the pointer respects the zero length and doesn't try to de-reference it. -
Range check error with TSysLogServer
David Heffernan replied to djhfwk's topic in ICS - Internet Component Suite
The correct solution, in my view, is to pass Pointer(RawMessage) rather than @RawMessage [1] -
This can easily happen. It's really common. Programming mistake in the app manifests as an exception raised in vcl code. Nothing interesting to see here.
-
Converting code source in R to Delphi
David Heffernan replied to de la Mancha's topic in Algorithms, Data Structures and Class Design
Here's what to do. First of all you need to understand the R code. You need to know what it's purpose is, and how it achieves it. You will need a clear understanding of what data types are expected to be passed to, and returned from the function. You may need to talk to the author of the code, or learn enough R to work it out yourself. Once you have a clear understanding then you will be in a good place to write an equivalent function in Delphi. Good luck. -
MIGRATING PHOTOBOOK TO DELPHI ALEXANDRIA FROM 2014
David Heffernan replied to Blavatsky's topic in Databases
If you comment out all of the code then the library will compile. And we all know that once a piece of code compiles, the job of the programmer is done.