[HN Gopher] 50 Years of Pascal and Delphi Is in Power
___________________________________________________________________
50 Years of Pascal and Delphi Is in Power
Author : pjmlp
Score : 114 points
Date : 2021-04-03 13:13 UTC (9 hours ago)
(HTM) web link (blog.marcocantu.com)
(TXT) w3m dump (blog.marcocantu.com)
| facorreia wrote:
| I owe a lot to the folks involved with Turbo Pascal for CP/M. I
| worked for years with Turbo Pascal, Borland Pascal and Delphi.
| useerup wrote:
| The forerunner for Delphi was Turbo Pascal. Before it became
| Turbo Pascal it was called Compass Pascal and then Poly Pascal
| (it was sold by a danish shop/company called Poly Data).
|
| Anders Hejlsberg wrote the first Compass Pascal compiler when he
| was 16. And it still lives on in Delphi so many years later.
| Anders is now driving TypeScript development at Microsoft.
| [deleted]
| davidhbolton wrote:
| Turbo Pascal, Borland Pascal and Delphi all suffered from the
| curse of units. Units were great, way superior to C/C++
| compilation allowing fast compiles and efficient stripping of
| unused code. But they were version incompatible. If you lacked
| the source code for a compiled unit, you could never move to a
| later version with it.
|
| But give it its due, the stuff you could do with Delphi for
| example COM made it probably the only Win 32 compatible language
| to compete with C++. It was the Betamax to the VHS of VB...
| robocat wrote:
| Units between versions were mostly not a problem due to the
| culture.
|
| Virtually all third party commercial libraries had source
| available, which had a raft of benefits (even if you often
| needed to pay more for the library to get the source.)
|
| Meanwhile for other languages, libraries were often sold
| without any source, and you were royally screwed if you had a
| problem later.
| pjmlp wrote:
| What curse? There is no language with versioning integrated
| into the module system.
|
| In all modern languages that is a build system responsibility.
| protomyth wrote:
| What is the current descendant of Pascal? Is it a child of Oberon
| or some Modula development.
| txdv wrote:
| If you are looking for a free alternative - Free Pascal, for a
| commercial - RemObjects Hydra.
| magicalhippo wrote:
| Hydra is their C#/Java/Delphi interop solution. Their Pascal
| language is Oxygene[1], part of their cross-language Elements
| solution[2].
|
| [1]: https://www.elementscompiler.com/elements/oxygene/
|
| [2]: https://www.elementscompiler.com/elements/default.aspx
| mhd wrote:
| Historically speaking Go would qualify as being descended from
| Oberon, philosophically none of the current crop of languages
| would qualify, most of them being too complex and brining in
| elements Wirth wasn't too fond of (like most of FP).
| mseepgood wrote:
| If you go by its creator it's Oberon-07 ("Revised Oberon").
| T-A wrote:
| https://spf13.com/presentation/on-the-shoulders-of-giants/
| protomyth wrote:
| I doubt Go qualifies as a descendant of Pascal particularly
| with some of the things said about Pascal by the C / Go
| creators.
| mseepgood wrote:
| The famous "Why Pascal is Not My Favorite Programming
| Language" article was written by Brian Kernighan, not by
| Ken Thompson (who created Go). Kernighan wrote the books
| about C and Go.
| atombender wrote:
| Go is influenced by several languages, and Modula and
| Oberon are at the top of that list. Robert Griesemer, one
| of the designers of Go, worked on Oberon at ETH Zurich.
| oblio wrote:
| I imagine Go is super disappointing for Wirth, it couldn't
| ever be called a successor to Pascal. To C, in some regards,
| maybe. To Pascal? Surely not.
| themodelplumber wrote:
| Don't miss Nim.
|
| https://nim-lang.org/
| oaiey wrote:
| Considering the Heijlsberg line of work ... It is first C# and
| then TypeScript :)
| elros wrote:
| As someone who went from Delphi to C# to TypeScript that's
| also how I see things
| vanderZwan wrote:
| I think that very much depends on your definition of
| "descendant", given how many language designers mention how
| much they were inspired by Oberon, Modula, or even just Wirth's
| writings in general. This is both on a technical level and on a
| language design level.
| yawaramin wrote:
| I seriously view OCaml as a descendant of Pascal. If you look
| at some of its imperative syntax (for loops, while loops,
| mutable assignment), comments (* ... *), modular programming
| style (distinguishing interfaces and implementations), and fast
| compilation speed, it's clear that the OCaml engineers took a
| lot of Pascal's (and its descendant Modula-2) lessons to heart.
|
| At the same time, OCaml's ML heritage greatly simplifies the
| majority of the syntax (getting rid of semicolons, making
| identifiers case-sensitive), and bringing the expressive power
| of functional programming.
|
| It fuses together the best of both worlds. It's why I often say
| that OCaml is like a midpoint between Haskell and Go. The 'Go
| parts' are from their common ancestor, Pascal.
| Schectmar246 wrote:
| Sometimes I wonder if the failure of languages like these - along
| with Ada is purely aesthetic one.
|
| Who knows, maybe Rust and something like Ada++
| http://www.adapplang.com/ will be able to dethrone C++, or Java
| some day.
| Galanwe wrote:
| > Sometimes I wonder if the failure of languages like these -
| along with Ada is purely aesthetic one.
|
| Delphi was not a failure by _any_ stretch of imagination. In
| terms of RAD, it was only second to VB.
|
| Also keep in mind that a lot of people at the time knew Pascal,
| in that regard Delphi was completely esthetically pleasant.
| hsitz wrote:
| Yes. And that "only second to VB" must be in reference to
| sales. Delphi was way more advanced and usable than VB, from
| a technical point of view.
| vintagedave wrote:
| These days the best comparison would be Python, perhaps. Not
| in terms of things like indentation, but conceptually: that
| is, elegant non-C-style.
| pjmlp wrote:
| They need to provide tooling at the same level, otherwise they
| will only succeed in niche areas where security is the top
| level concern, and good enough static analysers aren't
| acceptable.
|
| Think of Qt, WinUI, CUDA, Unreal, Visual Studio debugger, C++
| Builder kind of tooling.
| Schectmar246 wrote:
| Hmm, but aren't these languages easily compatible with C and
| C++. I know in Ada++ you just have to link the library at
| build time and generate a pkg based on a header file.
|
| func Foo (X : C.int) return C.bool with Import, External_Name
| => "Foo";
|
| I suppose though that you are right. A majority of modern
| programmers probably view sophisticated tools and pre-built
| packages (a la NPM) as necessities and hardly care about
| performance or code quality.
| Jtsummers wrote:
| It's now 3 April, Ada++ was announced on 1 April. If you're
| the author, congrats on the commitment, but it literally
| just changes _begin_ and _end_ to _{_ and _}_ , _is_ to _:_
| , and a few keywords, like _procedure_ to _proc_. I mean,
| it 's more obvious when you look at the _case_ example:
| case Variable: when 0 => Put_Line ("Zero");
| when 1 .. 9 => Put_Line ("Positive Digit"); when 10
| | 12 | 14 | 16 | 18 => Put_Line ("Even Number
| between 10 and 18"); when others => Put_Line
| ("Something else"); }
|
| Where's the _{_ to go with that _}_? Oh, that 's right, the
| _:_ is replacing _is_ : case Variable is --
| was : above .. end case; -- replaced by }
| above
|
| and there is no _{_. It may have made more sense to go
| Python-style and use significant whitespace.
|
| And regarding package management, Alire does exist and is
| starting to become interesting for Ada users. The list of
| crates is still small, but it's functional and (somewhat)
| easier than managing it manually.
|
| https://alire.ada.dev/
|
| EDIT: Fixed some things like "it's" to "its" and "process"
| to "procedure". It's Saturday morning and my coffee was
| still brewing.
| open-source-ux wrote:
| " _Sometimes I wonder if the failure of languages like these -
| along with Ada is purely aesthetic one._ "
|
| Possibly part of the reason. Pascal has a very readable syntax,
| but for some (most?) programmers it is too "verbose" and that
| is enough for them to never consider it. This is probably true
| of any language labelled "verbose".
|
| Python and Ruby advocates probably feel these languages have
| found the right level of conciseness and readability. But
| everyone has a different opinion. Of new languages, Nim and
| Julia seem aiming for the same balance: not too terse, but
| still easy to read. Have they succeeded?
|
| I find it fascinating that C's influence on language syntax
| continues today with new languages (e.g. Rust, Zig) in a way
| that Pascal does not.
| lordgroff wrote:
| Pascal to this day remains one of the most readable languages
| around. It's not fancy, it's verbose, and very clear. I think
| the only reason it fell from grace is the simple fact that it
| came from an era when best implementations of it were
| commercial, and that's not something that is acceptable in this
| day and age.
| lelanthran wrote:
| > I think the only reason it fell from grace is the simple
| fact that it came from an era when best implementations of it
| were commercial, and that's not something that is acceptable
| in this day and age.
|
| I love Lazarus, and Delphi before it, and Pascal before that
| ... but I gotta say, the language, readable though it is, is
| a pain in the rear to write.
|
| An instance of a class is not the same thing as an object.
|
| By default, the file open/read/write/close routines don't
| return error values so the caller has to do extra work to
| check statuses after each use of these functions (IIRC, those
| error codes from Assign(), Reset(), etc weren't thread-safe
| either!)
|
| Some conditional expressions _cannot have_ parenthesis
| (compilation error) while other conditional expressions _must
| have_ parenthesis (also a compilation error).
|
| Some builtin functions can't be easily 'wrapped' because
| while the function may take variadic arguments, the language
| doesn't allow the programmer to _write_ variadic argument
| functions.
|
| It's death by a thousand cuts; each little problem,
| surmountable on its own, adds to the overall friction when
| developing.
|
| What I really like in Pascal:
|
| 1. Programmer-defined range types: enums are not a
| replacement for those. 2. Bounds checking on arrays; I'd
| rather crash with an exception than silently overrun the
| array. 3. Nested functions (although, now with almost all
| languages supporting anonymous functions nested functions
| probably aren't really needed).
| vintagedave wrote:
| > An instance of a class is not the same thing as an
| object.
|
| I have no idea what you mean here, sorry.
|
| > By default, the file open/read/write/close routines don't
| return error values
|
| Those file IO methods are for backwards compatibility with
| Turbo Pascal. They haven't changed semantics since DOS.
| They don't support Unicode. They are heavily deprecated.
| Today, try using TFileStream.
|
| > while the function may take variadic arguments, the
| language doesn't allow the programmer to write variadic
| argument functions
|
| Pascal isn't C. You can consume variadic methods written in
| a C library, but the Delphi way to write the same thing is
| an 'array of const'. Here's the Format method, for example:
| http://docwiki.embarcadero.com/Libraries/Sydney/en/System.S
| y...
|
| > each little problem, surmountable on its own, adds to the
| overall friction when developing.
|
| You may have better luck not thinking of it from a C
| background but as similar to, say, Python: some things are
| different.
| lelanthran wrote:
| Now, granted, my knowledge on Pascal, Delphi and Lazarus
| is qite old and I've not used any of them for a long
| time, so if I'm making errors in anything I say below,
| then please accept my apologies in advance :-)
|
| >> An instance of a class is not the same thing as an
| object.
|
| > I have no idea what you mean here, sorry.
|
| This explains the issue quite well: https://forum.lazarus
| .freepascal.org/index.php/topic,43622.m...
|
| > Today, try using TFileStream.
|
| I have used it and was not as unhappy with it as I was
| with the Standard Pascal file IO functions. I was never
| able to figure out from the exception why a TFileStream
| method failed. The most you could infer was that an error
| occurred, but not _what_ error.
|
| This makes for a very poor interface to the user in the
| resulting application, as they have no idea what to do to
| fix the error before retrying. In most other languages
| (that Delphi and Lazarus compete with) you can let the
| user know what they should do to fix the error before
| retrying.
|
| > You can consume variadic methods written in a C
| library,
|
| That doesn't apply to what I was saying. I meant that a
| programmer could not write a Pascal procedure that
| wrapped a variadic-args _Pascal_ procedure. C has nothing
| to do with this.
|
| This is occasionally useful (say, for logging), and its
| ommission is one of those tiny things that add friction.
|
| With all that being said, I _still_ prefer doing native
| GUI apps in Lazarus to almost everything else out there.
| It 's insanely readable even after a prolonged period.
| unnouinceput wrote:
| Quote: ">> An instance of a class is not the same thing
| as an object.
|
| > I have no idea what you mean here, sorry.
|
| This explains the issue quite well: https://forum.lazarus
| .freepascal.org/index.php/topic,43622.m..."
|
| I am not sure how Lazarus implements stuff behind the
| scene but I can tell you 100% for sure that in Delphi
| every declared class has TObject as ancestor class, so
| when you instantiate a class in Delphi, you are creating
| an object.
| beagle3 wrote:
| Do note Python recently gained a C like assignment
| operator, the "walrus" operator.
| mycall wrote:
| Java simply stole the show. It had GC, namespaces, huge
| ecosystem and free.
| unnouinceput wrote:
| When I first tried Java, 25 years ago, after learning
| Pascal/C/C++ at Uni first, my first pet-peeve with it was
| the fact that I could not declare global variables. Coming
| from Pascal and C/C++ that was a bummer. I had to declare a
| class then inside that class go declare my global
| variables. Imagine my frustration that instead of just
| typing "globalHandle = 25" I had to write instead
| "mumuClass.globalHandle = 25". Real productivity bump right
| there!
| mikewarot wrote:
| Lazarus doesn't have GC, but strings are handled by
| automatic reference counts, and everything complex is an
| object with create/delete, so manual memory management
| isn't really a chore.
|
| There is a hierarchical namespace based on units, and also
| there is lexical scope.
| marcodiego wrote:
| What killed delphi were its proprietary closed roots. With a
| single vendor with erratic market history behind it, it was
| risky to use it for anything that was needed to be updated
| frequently and last long.
| brokenkebab wrote:
| Partly. But let's not forget Microsoft actively kicked
| Borland in the guts by withholding API information, and
| hiring away Borland's key figures. Everybody saw it and
| accounting for Msft weight (especially at that time) it was
| safer to bet on Borland's demise. I think it played bigger
| role then any erratic behavior.
| mdip wrote:
| I have written at length, in past Pascal posts, about my affinity
| for the language in my early days... specifically Borland Turbo
| (later Borland) Pascal[0].
|
| I ended up hacking on some leaked Telegard source code, decided
| to scrap it after discovering something I thought was suspicious
| and realizing I couldn't expect to understand every detail of
| these thousands of lines of code that I shouldn't have had in the
| first place. I ended up completely rewriting it in time to run it
| on my own, and a few friends' BBSes for about two years until we
| all found romance, the internet or both.
|
| Just thinking about one of the reasons _why_ I did the rewrite
| reminds me of how incredible that language /ecosystem was--given
| the early-90s when I used it. The "final nail in the coffin" for
| me was the code that authenticated a user. Bear in mind, this is
| the early 90s. You had a "handle" and a number, which a 16-bit
| unsigned integer (0-65535), assigned sequentially with the admin
| always being "0", and you could login with the number. Passwords
| were not only stored in plain-text in a relatively readable
| format in a file on the drive, but the Admin panel helpfully
| displayed the user's password every time a 'sysop' viewed a
| user's account. The background is provided to make clear: this
| was not a complicated login routine designed to avoid side-
| channel attacks, perform string comparisons in deterministic
| times, etc -- if they were, it'd be an amazing waste of time
| given the total disregard for security throughout the code (and
| most projects of this era)... and if it were, I wouldn't have
| been a good enough developer to even identify it.
|
| However, this code had a few `goto` statements, and some inline
| assembly. The three places that had inline assembly in this code
| were the ANSI implementation, that I wrote, the 16550 UART
| driver, that I wrote and this login routine that I did not write
| and as far as I could tell had absolutely no good reason to be
| there. After hours of refactoring, I broke the code out into
| "code that logs a user in" and "code that makes something"; That
| "something", IIRC, was a round-about way to generate a "master
| password" that could be used to login with any account (and `0`
| was `root`). During testing, I discovered that my "skipping the
| code that makes something" part resulted in an empty string value
| which meant I could login with no password to any account. I
| rewrote the whole login routine, and then the whole thing.
|
| Would kind of love to look into that, now, since I'd actually be
| able to understand what is going on, now (maybe!).
|
| [0] IIRC, the IDE fit on a 5.25" floppy, and Version 5.0 had a
| whole bunch of new, elaborate, syntax highlighting. It was
| _amazing_.
| skeletal88 wrote:
| One language feature from Delphi (or Pascal?) that I wish modern
| languages had is class properties
|
| No getter/setter bs. When creating a class you declared a field a
| property, it looked like this type private
| FBar: Integer; procedure SetBar(Value: Integer);
| published property Bar read FBar write SetBar
|
| so you specified what method was to be called when assigning to
| the propery and when reading from it. You could start with both
| read and write accessing the field directly and then later make
| them use getters-setters while keeping the class interface the
| same. Somehow this knowledge got lost by designers of modern
| languages unfortunately :(
| m_mueller wrote:
| In python nowadays you use data classes for that. Essentially
| nice with the frozen attribute. Before that there were named
| tuples - still useful to subclass instead of frozen data
| classes, as long as you don't need inheritence or any of the
| advanced data class field attributes.
| pdonis wrote:
| Python has had the property decorator since early in version 2.
| beagle3 wrote:
| Nim has everything you need to do that.
| yawaramin wrote:
| Surprisingly (or maybe not), JavaScript has getters and
| setters: https://developer.mozilla.org/en-
| US/docs/Web/JavaScript/Refe...
| facorreia wrote:
| C# has that:
|
| https://docs.microsoft.com/en-us/dotnet/csharp/programming-g...
| brokenkebab wrote:
| Yes, but Object Pascal's syntax is way cleaner.
| wtetzner wrote:
| Doesn't C# have properties?
| sglienke wrote:
| Most modern languages have that while at the same time removing
| a lot of the unnecessary ceremony and adding features such as
| init only setters in C#.
| pjmlp wrote:
| Besides the sibling answers, properties were originally taken
| from Eiffel/Sather into Object Pascal.
| musesum wrote:
| I wrote a hypertext system in Turbo Pascal - this was before NCSA
| Mosaic. What sold me was that it was one of the first IDEs. A
| friend mentioned that, when the compiler found an error, it would
| bring up the editor and position you at the error. This was huge!
| Plus, it selling for maybe 1/10th the price of other compilers.
| fit2rule wrote:
| I also wrote a hypertext-like front-end with Turbo Pascal, pre-
| Internet, back in the day .. there was a 3rd-party UI framework
| that made it so reasonable to mix graphics and GUI elements in
| MSDOS, so .. we made a bunch of internal company apps that
| rendered the data off the network, allowed the execs to point
| and click things, change graphs, etc.
|
| I remember seeing a plethora of amazing GUI plugins for Delphi
| too ..
| mlinksva wrote:
| Wirth's article also "ignores" Ada. But that's fine, the article
| is a personal account, not a survey of all Pascal family
| languages. The penultimate sentence:
|
| "The sequence Pascal--Modula--Oberon is witness to my attempts to
| achieve [perfection]."
| analognoise wrote:
| Please, give Lazarus a shot.
|
| One codebase, compile everywhere. Small executables, compiled
| rapidly. Cross platform. LGPL. Super friendly community with a
| LOT of awesome talent.
|
| It's really great!
| tomjen3 wrote:
| That sounds great, any pointers to get started writting more
| complex apps? In particular I can't seem to find a proper
| description of the memory system (when do I need to manage
| memory myself) and strings (it looks like those are managed
| automatically, but not? And there are like 4 types of them?
| Which would I need for UTF8?)
| guilhas wrote:
| Very interesting project to have a look is CudaText an open
| source Sublime alternative made with Lazarus/Freepascal
|
| http://uvviewsoft.com/cudatext
| olah_1 wrote:
| I couldn't figure out how to do API calls, get tokens, etc.
| Stuff that is necessary for most applications today. Would love
| to see more example apps that involve networking
| KronisLV wrote:
| Agreed!
|
| Anyone who could comment on any sort of support in Lazarus
| and fcl/lcl for the following would be appreciated:
| - HTTP(S) servers - SOAP - REST - gRPC
| - GraphQL
|
| The closest i've found is this:
| https://wiki.lazarus.freepascal.org/fpWeb_Tutorial
|
| But it doesn't really have the sort of structure that one
| would expect from a mature web framework, feels a bit worse
| than PHP (no automatic (de)serialization of objects, path
| variable and query parameter expansion, middleware etc.).
|
| Is there anything like Spring/Django/Express.js/ASP.NET Core
| in the world of Lazarus/FreePascal?
|
| Of course it's unfair to expect that Lazarus would have
| support for everything out of the box, so are there any
| external frameworks that are as mature as any of the above?
|
| I've only found the following: -
| https://github.com/fanoframework/fano -
| https://github.com/risoflora/brookfreepascal
|
| And they don't seem quite as mature yet... How have people
| been doing webdev in Pascal up until now?
| criddell wrote:
| Does it work for Android and iOS applications?
| KronisLV wrote:
| Here are a few links which contain some useful information to
| answer this: -
| https://wiki.lazarus.freepascal.org/Category:Android -
| https://wiki.freepascal.org/Category:iOS
|
| So, to the best of my knowledge, the answer here is "sort of"
| (don't expect things to be as polished as something like
| Xamarin or Kotlin, or even Dart/Flutter, but with enough time
| you could knock something together).
| the_only_law wrote:
| Last time I used Lazarus I could figure out how to layout
| controls. I was also disappointed by the control selection,
| although it was interesting watching the entire IDE recompile
| when I pulled in a 3rd party control.
| narag wrote:
| I'd rather not comment on current popularity of Delphi, Free
| Pascal and family. I won't touch commercial situation with a ten
| feet pole either.
|
| But I would like to mention what exactly made Delphi so nice to
| work with: language enabling design-time information, run-time
| type information, flexible memory management (some of it
| automatic, but also possible to do it manually), 95% of time
| safety but still possible to mess with internals, component
| architecture, clear exception handling and a very nice community.
| ozim wrote:
| There was a joke about Delphi convention being canceled because
| one dev got sick, second had a funeral and third one could go
| but, what would he do on his own?
| daitangio wrote:
| > I won't touch commercial situation with a ten feet pole
| either. Why? I mean, Delphi seems a good language... what
| prevent you from developing with it?
| dmitriid wrote:
| Borland was eventually bought by Embarcadero which was
| eventually bought by Idera.
|
| Idera specializes in extending a very thin lifeline to
| technologies which can still be milked for licenses and
| support.
|
| There's no real development or innovation behind products
| gobbled by Idera.
|
| Prior to that Borland was already severely lagging behind in
| dev tools.
| rahoulb wrote:
| I invested years of my time into delphi and that was pretty
| much devalued because of choices Borland made.
| narag wrote:
| Sorry, I didn't mean not programming with it, but entering
| the discussion of why I don't trust the company management
| anymore.
|
| Free Pascal + Lazarus is a fine free alternative if the
| language suits you.
| sigzero wrote:
| There is also the Delphi Community Edition for developing
| free stuff.
| narag wrote:
| The punchline. That's exactly the reason I didn't want to
| get involved in this thread.
| nicklecompte wrote:
| I think the parent commenter's issue with Delphi wasn't
| technological but rather the "commercial situation" - that
| Delphi is proprietary and a bit expensive, which is both an
| annoyance and potentially a serious liability. Especially
| given that Delphi, while far from dead, is in a tenuous
| market position.
| wdb wrote:
| The community version of are Remobjects Elements is a joy
| to use. I am using it in a professional/commercial manner
| to write closed source libraries for iOS, Android and Wasm
| all written in Swift.
| fiddlerwoaroof wrote:
| Lazarus is pretty good, although somewhat unstable
| mikewarot wrote:
| >Lazarus is pretty good, although somewhat unstable
|
| The most serious problem I have with it (I can't afford
| Delphi, or I would buy my way out) is the lack of actual
| documentation. Sure, there is a wiki, but it is just the
| output of a program stripping docstrings, nothing
| actually useful when you just need to use a part from a
| given library.
|
| There are no working code examples, or tips about corner
| cases, etc.
|
| Turbo Pascal had very good documentation, and it got
| better over time.
| pjmlp wrote:
| I still keep my Turbo Pascal manuals, and some generous
| souls have uploaded most of them to bitsavers.
| blibble wrote:
| plus it generated a single exe file that would run anywhere
| without installation or 20 dlls in the system directory
| narag wrote:
| Of course, I only mentioned language-level goodies. But then
| there was the best database access, rich GUI applications,
| etc. And my favourite: compiling big projects in seconds.
| koo6 wrote:
| yes/and the superb GUI designer .. Now look at QtCreator or
| how we build web apps .. it's all a joke, in comparison. That
| said ... the other product with similar GUI design system
| was/is ... VB :)
| codebolt wrote:
| The GUI designer for C# with WinForms is at least equally
| good, I'd say. I also like WPF but it requires a bit more
| careful thinking.
| linknoid wrote:
| Having worked extensively with both WinForms and Delphi
| GUI designers, I consider WinForms far better.
|
| WinForms designer is actual C# code, you can copy and
| execute that code outside of the designer. It's possible
| to search for references to a control in the designer,
| just the same as any other code. Often in Delphi, trying
| to accomplish the same thing in code as in the designer
| had a very obscure relationship. WPF feels much closer to
| the way Delphi did things, where your GUI is defined in
| different format than your code.
|
| In WinForms, creating a new control requires, well, just
| write a class that descends from Control, compile, and
| then you can start using it. In Delphi, creating a new
| control means you need an independent project, compile it
| into a package, and figuring out how to install it. I
| remember fighting Delphi trying to understand the package
| management system, and it was way more complicated.
|
| In WinForms, when you design a new control, it actually
| executes your code, so design time behaviors actually
| reflect what will happen at runtime. I remember having
| stuff in Delphi where a large control would be collapsed
| into a single line, and you couldn't actually tell what
| you were working with until you run it.
| skeletal88 wrote:
| Yes, the Delphi GUI designer was and still is the best
| there was (unless I have some kind on nostalgia glasses on
| accidentally). I started my dev career on a Delphi CRM
| project in 2006, then years later when I had to work on an
| Android application the first thought was "You have to be
| joking, this is how you desing an UI?". Also used Qt a lot
| between these two.. So, currently the best UI designer and
| framework is Qt for me. Everything else seems atrociously
| complicated and just.. developer-unfriendly, needlessly
| complex.
| tomc1985 wrote:
| Have you tried Lazarus? It's the FreePascal IDE and it
| tickles my VB funnybone pretty well
| unnouinceput wrote:
| Lazarus IDE is stuck in its Delphi 7 interface for years
| while Delphi was seeing fast iterations past years. Have
| you seen latest Delphi (10.4.2 from Feb. this year)? But
| most importantly did you tried its godly compiling speed?
| tomc1985 wrote:
| If there's a way to build with it free of charge, I'd
| check it out
| unnouinceput wrote:
| You can try its Community Edition. If you're a business
| building a commercial application then I doubt the
| license fee, while expensive for small developers, is
| expensive for the business too.
| romwell wrote:
| >That said ... the other product with similar GUI design
| system was/is ... VB :)
|
| That's because the guy in charge of Delphi left for
| Microsoft and is still in charge of Visual Studio :)
| unnouinceput wrote:
| Anders is in charge of C#, not VB.
| narag wrote:
| VB is older than Delphi. Anders went to Microsoft years
| later.
| xchaotic wrote:
| Things changed very quickly. I was writing a warehouse
| management app around 2000 and my first version was in
| Delphi. The sql components did require additional install and
| libraries. But v2 was in PHP and served over the Internet as
| that could run with no client install whatsoever- just a
| browser. It was much easier to manage the dependencies on my
| side and not worry about customer antivirus blocking the
| install etc.
| zabzonk wrote:
| > Today Delphi is still extremely successful compared to Oberon
|
| Yes, but not compared with just about anything else. I used to
| make some of my living as a Delphi consultant, but I had to give
| it up as you couldn't make any money doing it, particularly when
| compared with C#, C++ and Java.
| pjmlp wrote:
| At least in Germany there is still enough to be made, that
| guaranteed an yearly conference (pre-covid) and regular
| presence on Windows and .NET developer magazines.
| brylie wrote:
| Do you suppose Delphi would have wider adoption if it were
| open-source? E.g. are the Delphi language features and
| ecosystem compelling when compared with more widely adopted
| languages with a community governance structure?
| antaviana wrote:
| Delphi would have a much wider adoption if the compiler was
| open source and the IDE was propietary and sold only as a
| subscription, that is, similar to Jetbrains Kotlin model.
|
| Unfortunately it will not happen because Embarcadero current
| strategy revolves around milking their existing enterprise
| customers while their IT policies require that an aplication
| in production is built with components that have a support
| contract in place.
| pjmlp wrote:
| Ironically, when I watched the Kotlin conf, that seems
| exactly where JetBrains is trying to drive Kotlin, boosted
| by Android's adoption, trying to make a Kotlin eco-system
| out of it.
|
| I am betting it is going the Delphi way.
| jen20 wrote:
| It's unclear which "that" you mean here, but:
|
| - if you're alluding to the idea that Kotlin would be
| driven in the direction of closed source compilers and
| tooling in order to "milk" enterprise adopters: that
| would require a bizaare set of changes, including
| changing the license of both the tooling and the compiler
| - neither of which require copyright assignment, so
| JetBrains are not even free to do.
|
| - if you're betting on an open compiler but closed
| tooling, again that would require changing the license of
| the tooling, which JetBrains is not entirely free to do
| since it does not get assigned copyright on
| contributions.
|
| I don't know what agreement JetBrains has in place with
| Google, but I'd wager it precludes making Kotlin
| proprietary.
| pjmlp wrote:
| I am alluding to the tooling features only available in
| Clion and Enterprise version, alongside the comprising
| language design to be able to satisfy JVM, JS, Native,
| ART and WebAssembly.
|
| And the active role to make it a InteliJ language for
| most part, withdrawing support for Eclipse.
| lelanthran wrote:
| I don't understand what you and grandparent are trying to
| say; can you explain in more detail about the parallels
| you see between JB/Kotlin and Borland/Delphi?
| pjmlp wrote:
| Delphi fall apart because Borland trying to grow bigger
| than they could chew, ignored their independence
| developer customer base and turned into enterprise
| customers as their main selling target.
|
| Now after a couple of changing hands, about 4 of them,
| they are trying to grow back the numbers of the small
| shops.
|
| Likewise JetBrains seems to have forgotten the JVM roots
| of Kotlin and is now trying to go beyond JVM, comprising
| language design choices on features that don't have the
| same semantics, e.g. value types on JVM vs JS/ART/Native,
| or the incompatible memory semantics of immutable types
| on Kotlin/Native.
| vbezhenar wrote:
| What do you mean about Jetbrains? Idea Community Edition is
| free, open source and supports Kotlin.
| antaviana wrote:
| I meant that it gives Kotlin adopters the sense that
| there is no vendor lock-in on the code they write, while
| at the same time they keep a strong bind on the present
| and future market IDE for Kotlin (if a competitor
| appears, Jetbrains will be first to market for everything
| Kotlin so they will have a persistent edge), capturing
| with the IDE the dollars of those who seriously plan to
| develop for Kotlin.
|
| The fact that they have a freemium model is irrelevant to
| that goal of owing the Kotlin IDE space.
|
| The free offering you mention is used both for funnelling
| or for having customers do the market segmentation
| themselves, as there are customers that want to pay for
| everyone in the team, there are customers who want to pay
| for only some of members of the team and those who do not
| want to pay for anyone in the team.
| zabzonk wrote:
| There is an open source implementation: https://www.lazarus-
| ide.org/
|
| I don't see it getting wide adoption, but it's not bad for
| open source. But compared with C# (which is basically Delphi
| as it should originally have been, by the same designer) -
| nah.
| sigg3 wrote:
| Just wanted to add that as a total newbie to Free Pascal, I
| used Lazarus and enjoyed it very much.
|
| I still remain a total newbie but that's not because of
| Lazarus.
| squarefoot wrote:
| > I don't see it getting wide adoption
|
| It will get it, eventually. It can produce native
| executables without cross compiling on ARM systems too,
| which is a huge selling point to me. Think Raspberry PI,
| other small ARM boards, etc. and the PinePhone too.
|
| https://forum.lazarus.freepascal.org/index.php?topic=52217.
| 0
| 7thaccount wrote:
| C# does not compile to native apps by default unless you're
| using dotnet core or whatever it is called. Powerful
| language sure, but there is definitely a bit of a divide
| between the languages just because of that even if they
| have a similar syntax and high level design
| prosaic-hacker wrote:
| Viral expansion of any tool depends on (pardon the pandemic
| reference) a super spreader event or 10. Success needs: 1 A
| killer app. Pascal/Turbo Pascal, Email/nascent Internet,
| VisiCalc/Apple II, 123/IBM PC. 2 decade long over night
| success like Python
|
| I acquired my "10K hour" badge with Pascal in the late 70s
| (CDC Cyber 6600) and Mid 80s (PC) and then again with Perl
| (late 80s to early 2Ks) when each of these peaked. Coming
| back to the 2015+ versions (Lazarus / Perl 5.24+) of both
| was nostalgic but the communities were in the backwaters of
| programming due to viral success of some many others.
|
| A compelling event would have to happen to elevate them
| again. It could happen: Something pushed Ada to almost
| triple its "popularity" ( to < 1%.) According to PYPL
| (https://pypl.github.io/PYPL.html) in the last year.
| cwbrandsma wrote:
| I would say it would have helped...but that wouldn't happen.
| Borland as a company depended on Delphi as a revenue source.
|
| Microsoft and Sun did not. So they could both give their
| products away for free and open source them, plus keep people
| working on those products.
| zabzonk wrote:
| Well, Microsoft did and do make money from selling
| development tools and programming language products. Sun of
| course nearly went bust and were taken over by Oracle. So,
| maybe not good examples?
| daitangio wrote:
| Java had a massive push by Sun. If you have a old java
| codebase, it is easy to "wrap" around a big proxy and
| continue to expand it in Java, without learning a new
| language. Language library is quite well optimized.
|
| I like Pascal but its scope rules are Crazy compared to
| C/Java/C#, nerveless Pascal compiler is reported faster
| than Java one
| Jtsummers wrote:
| > I like Pascal but its scope rules are Crazy compared to
| C/Java/C#, nerveless Pascal compiler is reported faster
| than Java one
|
| Admittedly a long time since I used Pascal proper, but my
| recollection (and a quick search seems to confirm) that
| its scope rules are "simply" lexical scoping. Variables
| are visible only within the area they are declared and
| not outside, and variables can shadow variables from a
| higher level. So a global variable can become shadowed by
| a procedure variable. That's pretty much the same as the
| other languages use.
___________________________________________________________________
(page generated 2021-04-03 23:01 UTC)