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=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,763b126bf5276f4c X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news4.google.com!feeder.news-service.com!kanaga.switch.ch!news-zh.switch.ch!switch.ch!newsfeed-0.progon.net!progon.net!uucp.gnuu.de!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Wed, 29 Dec 2010 17:32:31 +0100 From: Georg Bauhaus User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Communications of ACM: Sir, Please Step Away from the ASR-33! References: <72b8fb96-2b5e-4ef8-8099-39361eeea853@glegroupsg2000goo.googlegroups.com> <878vzbwa61.fsf@hugsarin.sparre-andersen.dk> <8ns4v1Fk2dU1@mid.individual.net> <2vc8dxz8lc3t$.frc39a6lzjvt.dlg@40tude.net> <8ntp4kFo9qU1@mid.individual.net> <9cqhbxmdgs8x.nohduviggb5a$.dlg@40tude.net> <4d19c37f$0$7669$9b4e6d93@newsspool1.arcor-online.net> <1hd23hih9nr3v$.qzcce27pd1u1.dlg@40tude.net> <4d19e020$0$6885$9b4e6d93@newsspool2.arcor-online.net> <1sa8js3de7m9a.1u4v3u0e8fpvy$.dlg@40tude.net> <4d1a0531$0$6980$9b4e6d93@newsspool4.arcor-online.net> <1hok68cs370tc.1lt858ruxu3m5.dlg@40tude.net> <4d1b2fe1$0$7654$9b4e6d93@newsspool1.arcor-online.net> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <4d1b629f$0$7653$9b4e6d93@newsspool1.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 29 Dec 2010 17:32:31 CET NNTP-Posting-Host: 9b18897b.newsspool1.arcor-online.net X-Trace: DXC=XG6ZP^9;gon^Y=RbYBPl4`ic==]BZ:afn4Fo<]lROoRa<`=YMgDjhgbMBHNc?NkSHnnc\616M64>jLh>_cHTX3jm_YQM>K80Koa X-Complaints-To: usenet-abuse@arcor.de Xref: g2news2.google.com comp.lang.ada:17202 Date: 2010-12-29T17:32:31+01:00 List-Id: On 29.12.10 15:52, Dmitry A. Kazakov wrote: >> No, using tools, they will be guided in the direction the >> tool knows best. Just like an Ada compiler will instruct >> us to not leave out values in a case distinction. > > Ada is capable of this because it has types. It is not because Ada knows > anything about specific types, but because the programmer can use the type > system to express constraints the compiler will then check. There is no > magic knowledge Ada oracle sheds to guide programmers. All information is > exclusively from the programmer. The information in models is man-made, too. > Any tool is no different, it is a > dangerous delusion to believe otherwise. There are differences among tools' domains. (In what they are about, in what they can express.) Tools are different, and so are the benefits. Even when two tools are in the same class of tools: An Ada compiler will treat a case statement in a way that is different from the way a C compiler treats a switch. Both are, by intent, case distinctions. So even among compilers guidance is different. The crucial part is that an Ada compiler guides you by answering the question "Which case distinctions do I have to change?" (provided you don't use C style "others" for subtypes typically appearing in case statements). A C compiler typically cannot do this. Modeling tools will answer different questions. But they will answer them when answers are more difficult to find using only Ada source text and human inference. This is because, when modeling, humans have expressed one set of notions. This set is slightly different from the set expressed in Ada source. >> Even StP went far to make >> sure your model was checked in all sorts of directions. > > Assembler checks the code in that sorts of direction too. Assembly language cannot, for example, *express* IS-A relations, Ada can (there is syntax for it), UML too, and more than this. You can have conventions in assembly language, like the first parameter pushed for a call is a pointer to a memory location, and the first word there is a pointer that either represents the null pointer or is a pointer to another memory location of similar structure. (...) I think this isn't meant by *express* IS-A. >> The compiler is a guide where it "knows the area". > > Why this area must be different for an Ada compiler and a UML diagram > interpreter? Ada and UML deal with a different set of objects and notions. There is some correspondence, but the focus is different. >> These associations, >> relations, etc. are not easily spotted, not in one >> place, in a source program. The compiler won't tell you. > > and UML would? Yes. BON, e.g., is a particularly simple way to express relations and orders of communication. UML has this, too. Formally, unlike comments. > Why a thing important to the program must > be external to it? The system architecture is such that concurrent processes communicate via a data store. So the important thing happens to be external to the program. It is a requirement that I cannot change. But a model can express the external control as a system element nevertheless. > Why this thing must be external in Ada, but internal in > UML? An external control can be an element of a UML diagram or other modes of expression, but not in Ada (not directly). The set of objects directly expressible in some modeling language may be larger (or different). >> Suppose there is a setup like the following: some external entity >> acts as a mutex controlling concurrent activities of >> co-operating "jobs". > > Don't use low-level concurrency primitives. Ada has better means for that. That's the non-argument I'd like to again ask to avoid: the setup is given, as is. When I can use Ada to cope with the given setup, I'll have to act as if Ada had no direct support for the CSP mechanisms permitted in the given setup. However, direct support is available in other (modeling) formalisms. They can be mapped to Ada (in several ways). I pick a mapping that matches the setup. The model is clear, the implementation in Ada is up to the programmer.