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=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail From: "J-P. Rosen" Newsgroups: comp.lang.ada Subject: Re: Build language with weak typing, then add scaffolding later to strengthen it? Date: Fri, 22 May 2015 17:37:56 +0200 Organization: A noiseless patient Spider Message-ID: References: <127b004d-2163-477b-9209-49d30d2da5e1@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit Injection-Date: Fri, 22 May 2015 15:36:49 +0000 (UTC) Injection-Info: mx02.eternal-september.org; posting-host="d2244c1c164cf9db972ffa8be95c9640"; logging-data="14967"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/Ohh+tl8msSmD+BONmYquk" User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 In-Reply-To: Cancel-Lock: sha1:IkUqhzT6z6lNjjLyVGeSaK7EV8Q= Xref: news.eternal-september.org comp.lang.ada:25951 Date: 2015-05-22T17:37:56+02:00 List-Id: Le 22/05/2015 16:01, kalvin.news@gmail.com a écrit : > I don't agree. C is a low level language, and good at that. Its types >> are those of the machine: bytes and addresses, the rest is a (small >> quantity of) syntactic sugar. >> >> If you need strong typing, use a strongly typed language. But don't >> blame C for not being strongly typed, it was simply not part of the >> requirements. >> (Making my point clearer after various reactions). Languages have history; they stemmed from a need for solving a certain class of problems. Then people tend to use them for different purposes. My point is that each language should be used for what it's good at. C was created for writing an operating system, and it's initial requirement were to be a "portable assembly language". At that level, there is no place for typing: a machine word is what you make of it, there is no difference between a float, an int, or whatever. I certainly wouldn't object to writing a device driver in C. Now, it's true that people use it to write higher level applications. That doesn't make the language higher level. After all, when I started programming, almost any serious application was written in assembly. I have seen people writing databases in APL, real-time programs in Java, high-reliability applications in C, etc. My plea is "use the right tool for the job". I wouldn't advocate Ada for "throw-away" programs with a life-time of one day. But when it comes to safety-critical and/or long-lived and/or high reliability and/or etc... -- 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