Recent

Author Topic: Memory Safety and Object Pascal. Very good article  (Read 1258 times)

BlueIcaro

  • Hero Member
  • *****
  • Posts: 832
    • Blog personal
Memory Safety and Object Pascal. Very good article
« on: January 20, 2025, 04:07:49 pm »
Hello I found this article which talks about the security of pascal, and other issues

https://chapmanworld.com/memory-safety-and-object-pascal/

/BlueIcaro

Thaddy

  • Hero Member
  • *****
  • Posts: 18728
  • To Europe: simply sell USA bonds: dollar collapses
Re: Memory Safety and Object Pascal. Very good article
« Reply #1 on: January 20, 2025, 04:19:13 pm »
That article was referenced before, I think. At least its subject.
Craig is an old hand, but his worries about fpc/lazarus are unfounded.
If Europe sells their USA bonds the USD will collapse. Europe can affort that given average state debts. The USA can't affort that. Just an advice...

Joanna

  • Hero Member
  • *****
  • Posts: 1415
Re: Memory Safety and Object Pascal. Very good article
« Reply #2 on: January 22, 2025, 01:17:32 am »
Has anyone ever met him or seen his pascal projects?

Handoko

  • Hero Member
  • *****
  • Posts: 5515
  • My goal: build my own game engine using Lazarus
Re: Memory Safety and Object Pascal. Very good article
« Reply #3 on: January 22, 2025, 02:16:28 am »
I do not know him personally. But a quick search on the web showed he was active on Delphi/Embarcadero communities. And these are some of his codes:
https://github.com/Embarcadero/Blogs/tree/master/Craig%20Chapman/RADServerSample/src/delphi

440bx

  • Hero Member
  • *****
  • Posts: 6063
Re: Memory Safety and Object Pascal. Very good article
« Reply #4 on: January 22, 2025, 03:06:08 am »
I don't see how FPC and/or Delphi are any safer than C and C++.

All four of those languages allow unchecked pointer arithmetic, that's as unsafe as unsafe gets.

I think the article is rather biased towards Pascal and negatively biased towards C/C++.

That said, FPC and Delphi do offer some facilities that, in some cases, mitigate the need to use pointers but, whenever performance is needed, pointer arithmetic delivers it (along with some risks ;) )

Even COBOL85 which didn't support pointers isn't completely memory safe, yet in spite of that, it was/is still possible to inadvertently overwrite memory blocks. 
FPC v3.2.2 and Lazarus v4.0rc3 on Windows 7 SP1 64bit.

 

TinyPortal © 2005-2018