Recent

Author Topic: Why are types sometimes interchangeable  (Read 34686 times)

MarkMLl

  • Hero Member
  • *****
  • Posts: 8575
Re: Why are types sometimes interchangeable
« Reply #30 on: January 06, 2023, 09:36:49 pm »
Also note Ada can be a firey woman, to the point you want a divorce. <sigh>
She hates pressing the compile button before you have written your code correctly. <citation needed: I made that one up>

Actually, I've been musing over the last few days about the extent to which the complexity of modern languages effectively requires mere mortals to rely heavily on compiler error reporting.

I'm by no means innocent of premature compilation, but I find it slightly disturbing after having started off on FORTRAN with 12-hour turnaround and a five-runs-per-week limit.

Times have changed... /$DEITY/ but how times have changed... but should we really be dependent on that?

Quote
Not very surpising, if you are not given working hardware..in here lifetime: since the 21th century there's a working copy of Babbage's design.

Of his design, yes. But I'm not at all happy with the assumptions they've made about the precision/accuracy of the machining required to achieve that. Let's not go there...

Quote
Ada is not easy on that range of the keyboard, think her good friend Mary Shelley (whom, however a bit older, belonged to her inner circle)....could have written the manual... %)

We've learned a great deal about how to document languages over the last 50 years. But it must be admitted that Ada's documentation- at least in its mature form- is methodical and thorough. None of the "is that zero- or one-based?" that we have to tolerate when considering other languages.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

MarkMLl

  • Hero Member
  • *****
  • Posts: 8575
Re: Why are types sometimes interchangeable
« Reply #31 on: January 06, 2023, 09:55:17 pm »
I don't think you want to do any form of RAD or Agile software development in ADA.

Stop /thinking/ and spell it properly to start with!

I think you're mixing up a whole lot of things there. Ada might be /intended/ to have robust central control, but there again so were Modula-2 and -3. There's no reason what Ada- as a language- couldn't be divorced from its existing development environment and shoehorned into something more user-friendly.

However at that point I think we need to split out the sort of RAD that Emacs and Eclipse are intended to do (i.e. making the edit-compile-debug cycle tolerable) and the UI-designers provided by VB, Delphi, Lazarus and... well, very little else.

I think (Peter) that https://www.revk.uk/2017/11/ada.html is relevant. The writer owns (among other things) an ISP, and writes bare-metal firmware for a range of routers which are well-respected. Broadly-speaking, he liked Ada when he tried it

Quote
but I am not re-working OpenSSL from scratch in Ada.

That's the bottom line. There's a whole lot of utter crap that gets recycled on a regular basis: arbitrary Python and JavaScript that people use with minimal consideration of whether they can prove or even demonstrate that's it's "correct". But on occasion one comes across trusted code that it makes sense to want to use, and if the application language obstructs that then one has very real problems.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

Joanna

  • Hero Member
  • *****
  • Posts: 1463
Re: Why are types sometimes interchangeable
« Reply #32 on: January 06, 2023, 11:37:33 pm »
Quote
  (come on Joanna, you can use Google better than that can't you >:-)
Sorry but I prefer chatting with live people over relying upon search engines with skewed search results.

Everyone says Ada is so important and used for big things and to its credit it’s IRC channel seems ok but I’ve never seen any books, courses or job listings for it. I’ve heard stories that Ada was being replaced with C++ because of a shortage of programmers for it which seems deliberate since it’s not taught anywhere that I know of.

I’ve looked at it and noticed that you have to say what the ends are for. That seems very sensible. Judging by the obscurity of Ada and the popularity of unsafe languages I’d say that the trend is going in the wrong direction especially with too many things being connected to the internet.

Does anyone here know Ada well enough to answer the question if two distinct types can be created from real in the fashion that ctk would like?

VisualLab

  • Hero Member
  • *****
  • Posts: 742
Re: Why are types sometimes interchangeable
« Reply #33 on: January 06, 2023, 11:42:24 pm »
However at that point I think we need to split out the sort of RAD that Emacs and Eclipse are intended to do (i.e. making the edit-compile-debug cycle tolerable) and the UI-designers provided by VB, Delphi, Lazarus and... well, very little else.

As far as I remember, Emacs is just an extended (ancient) text editor and Eclipse is an IDE. Maybe instead of Eclipse you meant NetBeans? Only the last 3 are RAD.

That's the bottom line. There's a whole lot of utter crap that gets recycled on a regular basis: arbitrary Python and JavaScript that people use with minimal consideration of whether they can prove or even demonstrate that's it's "correct".

What era, what fashion. Perhaps nowadays more and more people suffer from excess free time.
« Last Edit: January 07, 2023, 12:21:21 am by VisualLab »

VisualLab

  • Hero Member
  • *****
  • Posts: 742
Re: Why are types sometimes interchangeable
« Reply #34 on: January 07, 2023, 12:17:06 am »
And a reason I don't see Pascal as a usable language, due to warts (such as this one) in its featureset.

There are many languages that are not considered useful languages by different people. It's just that people have different expectations and preferences regarding tools. Everyone has their own personal opinion of a given language. For example, I find Python completely useless to me. And the C language is of very little use. Others think otherwise. And this is due to my needs and expectations. Simply.

Pascal will not be fixed anyway, as it is set in stone now...

Maybe it doesn't need fixing. There's a sound rule that says, "Don't fix what ain't broke." So you think Pascal needs fixing and I think it's not broken so it doesn't need fixing. I suspect that when I say C is broken, you might (I speculate) say it doesn't need fixing because it's well designed. And it all comes from needs and expectations.

Every older language is carved in stone. For example, C, C++ as well as Java or C#. They are only extended, but the same approach is applied to Pascal. A separate issue is the removal of existing and used language features. Is this a good solution? Well, it depends how you look at it. For example, the C++ committee believes not. The people responsible for the development of Object Pascal (Delphi) also think so. But Guido and his friends, for example, don't think so anymore. And what was the reaction of Python users? And there are probably several such languages, apparently: Scala, Swift (I don't use it, I'm just quoting rumors).

...so the best I can hope is its users will move on to better-designed languages, after acquiring a sense for what good design is. (which my posting here might help with)

And what does better designed mean? This is a rather vague and general statement. If you ask for clarification, everyone will list slightly different sets of features. Again: it all depends on your needs and expectations. For example, the build system. If someone values time and convenience, they use, for example, Delphi (lazarus) or Visual Studio, and then for some reason they have to use CMake, then they go to hell. So Pascal is better designed for me. And I hope that gradually people will switch from various "strange" languages to Pascal :)

It worked with some other type earlier, so this is inconsistent and arbitrary.

Oh, there are many inconsistencies in different languages. After all, this is related to design decisions. It's impossible to please everyone. That's why everyone chooses the language that bothers him the least :)
« Last Edit: January 07, 2023, 12:28:11 am by VisualLab »

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Why are types sometimes interchangeable
« Reply #35 on: January 07, 2023, 12:27:54 am »
Oh, there are many inconsistencies in different languages. After all, this is related to design decisions. It's impossible to please everyone. That's why everyone chooses the language that bothers him the least :)

Exactly....

There are many things that bother me in Pascal. And currently the only Pascal I use is free pascal.
And many of those things are done how I prefer in a many other popular languages...

But the number of things that bother and annoy me in all the other popular languages I know far outweigh the things that I find irritating in Pascal...

Pick your poison...




ctk

  • New Member
  • *
  • Posts: 19
Re: Why are types sometimes interchangeable
« Reply #36 on: January 07, 2023, 12:56:44 am »
Hello! I will answer your questions, and flat out (but tersely) disagree with the general sentiment of defeatist relativism you're pushing out of personal taste.
A separate issue is the removal of existing and used language features. Is this a good solution?
An excellent one, that would gain from being planned from day one in any language that comes into existence.
It's quite simple: you would add a note at the beginning of your file that e.g. you're not going to use any deprecated features, and this makes them forbidden from use *in the current file*.
Simple. Elegant. Backwards-compatible: you can always use all the features that have been deprecated if you don't make a note in any given file that you don't.

And what does better designed mean
I linked this, which is the first criterion I need here: https://en.wikipedia.org/wiki/Principle_of_least_astonishment

Oh, there are many inconsistencies in different languages.
Yes, let's fix the issues in other languages too. I'm serious. One feature at a time.
Here it's a matter of who, of us two, lives longer than the other; try as you might, you can not dent my idealism, and I can not lift you up from the doldrums of defeatist relativism.

Joanna

  • Hero Member
  • *****
  • Posts: 1463
Re: Why are types sometimes interchangeable
« Reply #37 on: January 07, 2023, 01:33:16 am »
I just finished reading
Quote
I think (Peter) that https://www.revk.uk/2017/11/ada.html is relevant.

He was enthusiastic about Ada until discovering that nobody had written the libraries he needed for him in Ada. So he just gave up on using Ada presumably until someone creates them.

 The phenomenon of being so dependent upon existing libraries is a serious and pervasive problem. Occasionally there Is news of someone who wrote opensource libraries punishing freeloaders for not being more appreciative of his work. I think as a rule most people are just lazy and want to mooch.

Existing libraries could be full of bugs and malware and probably could be greatly improved by being redone in Ada. Also translating existing code into Ada would provide an excellent learning opportunity. The result of his article does nothing but discourage people from using Ada I think.

I sometimes hear similar arguments from people who know little about fpc claiming that oh it doesn’t have libraries for modern computing.. :(

Joanna

  • Hero Member
  • *****
  • Posts: 1463
Re: Why are types sometimes interchangeable
« Reply #38 on: January 07, 2023, 01:46:30 am »
Quote
you can not dent my idealism, and I can not lift you up from the doldrums of defeatist relativism.
Ctk can you please share which language you program with and what sort of programming you have done?

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Why are types sometimes interchangeable
« Reply #39 on: January 07, 2023, 01:50:49 am »
I just finished reading
Quote
I think (Peter) that https://www.revk.uk/2017/11/ada.html is relevant.

He was enthusiastic about Ada until discovering that nobody had written the libraries he needed for him in Ada. So he just gave up on using Ada presumably until someone creates them.

The phenomenon of being so dependent upon existing libraries is a serious and pervasive problem. Occasionally there Is news of someone who wrote opensource libraries punishing freeloaders for not being more appreciative of his work. I think as a rule most people are just lazy and want to mooch.

Time. Not everyone has unlimited free time.


Existing libraries could be full of bugs and malware and probably could be greatly improved by being redone in Ada. Also translating existing code into Ada would provide an excellent learning opportunity. The result of his article does nothing but discourage people from using Ada I think.

Seriously? Malware? When have you heard in the news there was malware in Ada libraries?
Show me a news report.

I sometimes hear similar arguments from people who know little about fpc claiming that oh it doesn’t have libraries for modern computing.. :(

Same. Time. They have what they need in other environments, but they do not have what they need with FPC.

You need to spend a few years using something other then Pascal.
And doing something productive in several other programming environments.

They will get some understanding where they are coming from rather just just assuming they want to be hard on pascal unfairly.

In general your programming world view is very myopic. You do to not seem to realize Pascal and Lazarus have many faults. And you go after anyone who points out those faults.



« Last Edit: January 07, 2023, 01:52:34 am by Bogen85 »

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Why are types sometimes interchangeable
« Reply #40 on: January 07, 2023, 01:51:54 am »
Quote
you can not dent my idealism, and I can not lift you up from the doldrums of defeatist relativism.
Ctk can you please share which language you program with and what sort of programming you have done?

Why does Ctk need to answer to you on this? You brought up this subject.
Ctk only came here after the fact.

Joanna

  • Hero Member
  • *****
  • Posts: 1463
Re: Why are types sometimes interchangeable
« Reply #41 on: January 07, 2023, 02:13:44 am »
Quote
Seriously? Malware? When have you heard in the news there was malware in Ada libraries?
Show me a news report.
I think you mis read what I said. I didn’t accuse ada of having malware

I hope ctk will answer my question about what language he uses because I want to find out what the “perfect language“ that we are missing out on is.

If he has not written applications of any substance it’s easy to go around nitpicking how languages could be better whilst ignoring that fact that his proposed changes would probably break a lot of things.

Yes I understand that some people don’t have time but in most cases they have plenty of time that they would rather spend watching tv, playing computer games or fooling around on the Internet. I’ve been guilty of some of these things myself.

What it takes is dedication>:D
The developers of fpc and Lazarus managed to find the time to create and improve code despite most of them probably having full time jobs.

I’m going to have to agree with ctk in this case
Quote
I can not lift you up from the doldrums of defeatist relativism.

I want nothing to do with using junk code that could be better and employers cutting corners and encouraging “copy paste” programming or even worse blackbox libraries  is an irresponsible solution with no foresight or care about the future consequences.
Code can and should be improved regularly. I’ve Lost count of how many times I’ve redone my code and I will do it again.

Joanna

  • Hero Member
  • *****
  • Posts: 1463
Re: Why are types sometimes interchangeable
« Reply #42 on: January 07, 2023, 02:16:22 am »
Quote
Why does Ctk need to answer to you on this? You brought up this subject.
Ctk only came here after the fact.
I think you need to work on your reading comprehension skills and reread my and ctks first posts

Bogen85

  • Hero Member
  • *****
  • Posts: 703
Re: Why are types sometimes interchangeable
« Reply #43 on: January 07, 2023, 02:25:36 am »
Quote
Why does Ctk need to answer to you on this? You brought up this subject.
Ctk only came here after the fact.
I think you need to work on your reading comprehension skills and reread my and ctks first posts

Ctk only has two posts on this forum.
They are both in this topic.

I have read them both.

I find what Ctk has said in both to be very reasonable, and I agree with much of what was said.

MarkMLl

  • Hero Member
  • *****
  • Posts: 8575
Re: Why are types sometimes interchangeable
« Reply #44 on: January 07, 2023, 10:02:34 am »
However at that point I think we need to split out the sort of RAD that Emacs and Eclipse are intended to do (i.e. making the edit-compile-debug cycle tolerable) and the UI-designers provided by VB, Delphi, Lazarus and... well, very little else.

As far as I remember, Emacs is just an extended (ancient) text editor and Eclipse is an IDE. Maybe instead of Eclipse you meant NetBeans? Only the last 3 are RAD.

I meant what I wrote. I'm splitting out development environments which make at least some attempt to ease the edit-compile-debug cycle, which include in particular Emacs and Eclipse, and the form designer part. They're distinct.

MarkMLl
MT+86 & Turbo Pascal v1 on CCP/M-86, multitasking with LAN & graphics in 128Kb.
Logitech, TopSpeed & FTL Modula-2 on bare metal (Z80, '286 protected mode).
Pet hate: people who boast about the size and sophistication of their computer.
GitHub repositories: https://github.com/MarkMLl?tab=repositories

 

TinyPortal © 2005-2018