Live data from Hacker News

Why I use Object Pascal

dubst3pp4.github.io

221–230 of 235 posts

Re: Why I use Object Pascal

#221
post #147
post #146

Earlier quoted context omitted.

I don't think anyone really disagrees with you -- most people have problems with the syntax of Perl, C, and C++. Sure, they can get used to it, particularly with C because it's small, but the syntax isn't why they use the language. Somewhat surprisingly, I think Perl's syntax is one of the reasons that Python became popular. Perl can do pretty much everything Python can, and it came significantly earlier. Yet people…

> Perl can do pretty much everything Python can, and it came significantly earlier. Yet people gravitated toward Python. I don't think syntax is the main culprit here, and Perl is only four years older than Python. For about 15 years Python tried, unsuccessfully, to compete with Perl as the premier language for shell scripting and sysadmin tasks. It wasn't until around 2005 that Python finally caught on, its rise coi…

I think the main culprit was Perl's mess of an OO system. While technically it was the same at its core as the Python one, the almost complete lack of syntax to support OO and lack of standards (especially in those earlier days) for objects to interoperate made it needlessly complicated for most people and people moved to languages where they could just write "class Foo".

Re: Why I use Object Pascal

#222
post #21

"You can also define your own types" , "classes can also inherit other classes" , "Pascal is modular" ... Not to say these are not valid reasons, or expectations one may have from a language, but - what exactly is Pascal being compared to? I mean, it's 2017.

C has no classes, and everything's in one global namespace. Scheme & LISP have no built-in classes, and one can argue that CLOS isn't what we normally describe as OOP. Both normally have a global namespace. Inheritance in JavaScript is possible but very hard to implement correctly before ES6. Node has namespaces (sort of) but client-side JavaScript generally doesn't. PHP in theory has namespaces, but the standard lib…

> what we normally describe as OOP

OOP just means "functions are associated with data in a syntaxic construct of the language". Namespaces are irrelevant.

Re: Why I use Object Pascal

#223
post #147
post #146

Earlier quoted context omitted.

I don't think anyone really disagrees with you -- most people have problems with the syntax of Perl, C, and C++. Sure, they can get used to it, particularly with C because it's small, but the syntax isn't why they use the language. Somewhat surprisingly, I think Perl's syntax is one of the reasons that Python became popular. Perl can do pretty much everything Python can, and it came significantly earlier. Yet people…

> Perl can do pretty much everything Python can, and it came significantly earlier. Yet people gravitated toward Python. I don't think syntax is the main culprit here, and Perl is only four years older than Python. For about 15 years Python tried, unsuccessfully, to compete with Perl as the premier language for shell scripting and sysadmin tasks. It wasn't until around 2005 that Python finally caught on, its rise coi…

The "killer app" for Python was NumPy. Ruby and Perl have nothing even close.

Re: Why I use Object Pascal

#224
post #44

Earlier quoted context omitted.

There certainly were/are differences across platforms in C (hence config scripts), but for the most part those aren't issues with the language itself but with the supplied libraries.

Oh the joys of writing portable code across Aix, HP-UX, Solaris using their own compilers, using a mix of K&R and ANSI C. Many computers just had something like Small-C available.

Even using GCC it could be a problem. Aix would want a different type for this function call, Solaris for that function call, Linux for this other function call. We had #ifdefs around a lot of variable declarations.

Fortunately, we were at least all ANSI.

Re: Why I use Object Pascal

#225

Earlier quoted context omitted.

You must be 50... and you're still on HN! Are you still an engineer? If so, what stack are you using now?

Checking in as another 50 year old, still on HN, still an "engineer", experienced enough to use tools, not "stack"s. Admittedly I didn't start with Pascal, but rather with BASIC and several assembly languages (1802, Z80, & 6809 were among the first I used). I learned Pascal after C, actually. I like things about both, but often wish that Wirthian languages would have won out. FWIW, these days I primarily use Java, C,…

well I'm 27 and started with turbo pascal/delphi and I didn't hated it. I still have the programming book, but never looked at it again in the last 10 years.

Re: Why I use Object Pascal

#226
I just what to thank the author of the article. I am from the camp of those who had this misunderstanding of thinking that Pascal is only a "toy language" to be studied at school or university and the articles gave clear proofs it's not. I'm not going to switch to Pascal now or explore the question more deeply; it was just an important thing for me to learn.

Re: Why I use Object Pascal

#227

As I get older, I'm strongly swinging into the camp that thinks languages should have strongly restrictive syntax. Object pascal is one of those languages which is both low level enough to cleanly map to efficient code, as well as high level enough not to feel really restrictive. Its a language that is completely misunderstood because far to many people read a couple critical essays, and believed everything they read…

> even though the strongest argument frequently was that its harder to type "begin/end" than "{/}". Which is a pretty lame thing and it's not too different from Ruby, to boot.

Ruby supports braces, they just aren't used as often.

I prefer begin/end so this is a feature to me.

Re: Why I use Object Pascal

#228
post #9

Turbo Pascal and Forth were my first languages past Assembly on C64. They were so much better then Basic and Assembly for a young teenagers. Delphi is now $1,200 to $4,400 a user!!! WOW more then the $75 in 1983 https://www.embarcadero.com/app-development-tools-store/delp...

Currently I'm learning Forth and I really like that language! It's a brain twist and that's reason enough to have a look at :-)

Forth is one of the first things I install on a new machine, I love tinkering with it and it seems to me to be the "right" way to do computing... but I have yet to write a useful program in it...

Re: Why I use Object Pascal

#229
post #80

I've lately been trying out FreePascal for building my indie games (which have in the past been in C, Python, Java, Objective-C, and finally JavaScript), and it's going well enough. There's certainly room for improvement, and the Lazarus IDE is not at all to my taste, but it's likely to be my next-ten-years language. https://mdhughes.tech/2017/09/02/pascal/ and a couple of followup posts https://mdhughes.tech/categor…

Any early feedback on mobile?

Lazarus and/or Free Pascal? Android is looking good, though maybe not really a pleasing experience for those with less experience. It even has multiple approaches. iOS is still dark, no one seems interested in making it work, even Arduino gets its place before iOS.

Delphi? Some big mobile apps are written in it already. WPS Office for Android and/iOS, if you ever heard, was written in Delphi. At least the last time I decompile their APK it confirms a Delphi runtime existence. Disadvantage would be the framework that's not native, thus you may end up in jumbo size APK even for a form + label containing hello world.

Re: Why I use Object Pascal

#230
post #22

Ultibo - the barebone unikernel OS for Raspberry Pi - is written completelly in Object Pascal... it's source code is >>much https://ultibo.org ).

This is strange and wonderful. Thanks for sharing. Somehow I wasn't aware of this, and I follow Raspberry Pi stuff.

Too wonderful. I was shocked when I see common filesystem drivers (including NTFS!), completely written in Pascal. The author must be a programming God.
Post reply on HN