From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, FREEMAIL_REPLY autolearn=no autolearn_force=no version=3.4.4 X-Received: by 10.66.224.73 with SMTP id ra9mr12587003pac.9.1432327140508; Fri, 22 May 2015 13:39:00 -0700 (PDT) X-Received: by 10.140.84.202 with SMTP id l68mr154478qgd.5.1432327140455; Fri, 22 May 2015 13:39:00 -0700 (PDT) Path: buffer1.nntp.dca1.giganews.com!border1.nntp.dca1.giganews.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!h15no7681195igd.0!news-out.google.com!k20ni44847qgd.0!nntp.google.com!z60no3275270qgd.1!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 22 May 2015 13:39:00 -0700 (PDT) In-Reply-To: <46b2dce1-2a1c-455d-b041-3a9d217e2c3f@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=105.237.112.50; posting-account=orbgeAkAAADzWCTlruxuX_Ts4lIq8C5J NNTP-Posting-Host: 105.237.112.50 References: <127b004d-2163-477b-9209-49d30d2da5e1@googlegroups.com> <59a4ee45-23fb-4b0e-905c-cc16ce46b5f6@googlegroups.com> <46b2dce1-2a1c-455d-b041-3a9d217e2c3f@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <7ac8be18-bf22-4e7b-afcc-4da5c92049f3@googlegroups.com> Subject: Re: Build language with weak typing, then add scaffolding later to strengthen it? From: jan.de.kruyf@gmail.com Injection-Date: Fri, 22 May 2015 20:39:00 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Xref: number.nntp.giganews.com comp.lang.ada:193275 Date: 2015-05-22T13:39:00-07:00 List-Id: On Friday, May 22, 2015 at 10:04:17 PM UTC+2, kalvi...@gmail.com wrote: > perjantai 22. toukokuuta 2015 22.41.15 UTC+3 J-P. Rosen kirjoitti: > > Le 22/05/2015 19:51, kalvin-nospamhere-.news@gmail.com a =E9crit : > > > Yes, I understand. I just wanted to make a point here, that an int > > should not be considered type compatible with another int if they are > > declared using different typedefs. Neverthless, my argument is still > > valid if I had used unsigned int, uint16_t or uint32_t: > > >=20 > > > typedef uint16_t Cylinder; > > > typedef uint16_t Head; > > > typedef uint32_t Sector; > > >=20 > > > The variables of type Cyliner, Head and Sector should be treated by > > > the compiler as incompatible and different types unless they are > > > explicitly typecasted. > > Of course, being a long time supporter of strong typing, I agree with > > that view. But if you think in terms of abstract types and problem > > domain rather than bits and addresses, don't use C. I see no point in > > trying to make a low-level language higher level: use a language > > designed to support higher level views. > >=20 > > To take an analogy: nobody would be so fool as to use a language > > designed for making animations on web pages in a real-time context ;-) > >=20 > > --=20 > > J-P. Rosen > > Adalog > > 2 rue du Docteur Lombard, 92441 Issy-les-Moulineaux CEDEX > > Tel: +33 1 45 29 21 52, Fax: +33 1 45 29 25 00 > > http://www.adalog.fr >=20 > Reality bites. It is very easy to get a decent and free/inexpensive compi= ler for almost any microcontroller on the market. And it is quite easy the = find developers how are familiar with C/C++. And it is very hard to convinc= e managers to invest to new tools that they do not know or understand, or t= heir knowledge is based on outdated information (like "Yeah, I know Ada. On= e of my friends worked with Ada in 80's and it was *very* slow, the compile= r produced terrible code and they needed Vax-cluster to run the compiler. A= da is so big."). So, we are dealing with a cultural, economical and practic= al challenges as well as historical burden and bad reputation. The historical burden and the bad reputation have not kept me away. And just read the blurp on the adacore website about all the military-, air= craft-, and financial applications. It certainly convinces my customers. so it must be cultural, or tribal if you wish, this whole issue. >=20 > I do not claim that even Ada would be the ultimate solution. Someone made= a good point above that, for example Oberon manual is only like 17 pages a= nd Ada RM is over 1000 pages. There might be something wrong here, and may = explain partly why Ada has not gain popularity. I was told in good faith the other day by some small business owner that ha= cks code at times for his products, after I explained what I was doing at t= he moment and what tools I use, that I should invest in Java. I would be up= and running in 14 days he said.=20 So now, what do we deduce: 1. java has glamour (this has been discussed here before) 2. the basics of java are easily grasped by a weekend hacker 3. he obviously has friends that keep him nice and cosy within the circle o= f the believers. And I think the last point is the deciding factor. At least research in the= process of religious conversion says so. You join a crowd because you like= some of the people, and after a while you start to think that there is som= ething in what they teach there. >=20 > In my opinion, one of Ada's problem is that it is not allowed to call a c= ompiler an Ada compiler if it implements only a subset of the language and = the compiler has not beed certified. Please correct me if I am wrong here. = I would consider a subset of Ada quite attractive if it provided same funct= ionality as a C99, providing Ada's strong type checking and better grammar = etc. - and if the compiler would be available even for the smaller microcon= trollers for free (in the similar manner as C is available). Well uh . .=20 I have not yet had a gpl ada compiler out of Adacore that was certified or = complete.=20 I was just part of Adacores quality control system. More users catch more b= ugs. And rest assured most compiler vendors know this trick. And otherwise: a person is free to use a subset of the animal if that is wh= at you like to do. Just look around. some runtimes for microcontrollers are available. And the= y are not difficult to make yourself. If gcc has a back end, I am sure the = gnat front end will work. j.