Jump to content

David Heffernan

Members
  • Content Count

    1154
  • Joined

  • Last visited

  • Days Won

    74

David Heffernan last won the day on August 29

David Heffernan had the most liked content!

Community Reputation

911 Excellent

4 Followers

Technical Information

  • Delphi-Version
    Delphi XE7

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. That trade off depends on the size of the record. For small records then performance is better if the items are stored directly in a contiguous array.
  2. OK, this is making more sense to me, and I can better appreciate the inconvenience.
  3. Maybe. I guess I might not be encountering the problem regularly. You must be facing it very regularly I guess. Isn't that a different issue?
  4. You are massively overstating this. Finding a file from disk is not difficult. Yes it takes a few seconds, but then it's not like this issue happens regularly. Every feature takes resources to implement. Given the immense problems that the entire Delphi product has, I for one would be disappointed if Emba spent resources on features like this that bring so little benefit.
  5. Doesn't seem to me like this is a very significant problem given that you can just open the file in a text editor yourself.
  6. Not sure the IDE should do that. There are tools to convert. If you want to convert, then use those tools. If the IDE did this automatically then that would be painful for people who wanted to use binary.
  7. If it is in binary form then presumably there would be no need because there would be no problem in it
  8. Well, you avoid some of the issues, but not all. For instance you don't avoid the issue where an item is deleted, but a stale pointer is retained. Additionally you end up with a large number of heap allocations, and memory that can be scattered which can impact performance.
  9. Granted the indirection that is offered by a reference type does make some of the issues hard to trip over, but they still exist.
  10. In a collection which owns its members then removing an item leads to a stale reference in either scenario (classes vs records).
  11. Your third sentence directly contradicts the first sentence.
  12. Yes, this should be a read only property. In an ideal world we'd have proper language support for references, as I think is especially we done in D foreach (ref elem; arr) { elem = 0; }
  13. TList<T> FWIW my codebase doesn't use the RTL generic collections. It uses a collections library that I wrote, that amongst other things has collection classes that allow access to items via references to the underlying records for exactly this situation. I think that you are making valid points, but you aren't pinning the blame in quite the right place. I don't think the issue is with value types per se. To my mind the issues are more about limitations of the standard RTL collection classes.
  14. Not if you use a collection that provides you access to items via references to the underlying records
  15. That is correct. But that's not the point you made.
×