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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,f3bebae566a54cab X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,UTF8 Path: g2news1.google.com!news3.google.com!feeder.news-service.com!94.75.214.39.MISMATCH!aioe.org!.POSTED!not-for-mail From: =?utf-8?Q?Yannick_Duch=C3=AAne_=28Hibou57?= =?utf-8?Q?=29?= Newsgroups: comp.lang.ada Subject: Re: Some exciting new trends in concurrency and software design Date: Thu, 23 Jun 2011 11:59:51 +0200 Organization: Ada @ Home Message-ID: References: <8a5765ba-622a-42cd-9886-28ed7cfed31e@s17g2000yqs.googlegroups.com> <4dff5be5$0$6565$9b4e6d93@newsspool3.arcor-online.net> <9b65f3c7-caee-440f-99ed-0b257221ce58@m24g2000yqc.googlegroups.com> NNTP-Posting-Host: HfNAdMB88ZE8crK0iV2fMQ.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes Content-Transfer-Encoding: Quoted-Printable X-Complaints-To: abuse@aioe.org User-Agent: Opera Mail/11.11 (Linux) X-Notice: Filtered by postfilter v. 0.8.2 Xref: g2news1.google.com comp.lang.ada:20011 Date: 2011-06-23T11:59:51+02:00 List-Id: Le Tue, 21 Jun 2011 11:36:31 +0200, steveh44 a =C3= =A9crit: > On Jun 20, 4:56 pm, jonathan wrote: > >> >> Functional programming doesn't appeal to me, > > I also tried FP, and I did not like it either. I you just (and not more) used it as a clean base from which to derive = other implementations, in say, Ada, you may had another feeling. Sure FP= = lacks things like the expression of concrete hardware (real life machine= s) = limitations: typically, with FP, you will not bother about defining a = range for an integer type, instead, it may rely on big numbers, which ar= e = obviously less efficient and only limited by available memory and CPU = speed, which is obviously not acceptable at all in many case. Keep in mind: FP does not focus on the same thing a language like Ada do= ; = however, multiple views is often a good thing. I like to think for some = = area (not all, don't forget), FP is nice for a first model, from which y= ou = will derive a concrete implementation. You will then not throw it away, = = because it may help you to compare result of both FP and Ada = implementation, if ever some suspicious results occurs with the release = = implementation, or if you lost some tracks due to some side-effect mess.= = You think of an FP model as a documentation for an Ada implementation, a= s = a way to explain it (providing the FP text is documented enough, of cour= se) Also, as Phil outlined, being expression based (no side effect), FP also= = leave you a chance to turn a sequential implementation into a concurrent= = implementation, which is not the least. Whatever an Ada implementation i= s, = try to turn a sequential design into a concurrent design, and tell about= = it after you did. As a rule of thumb, although its not true for every thing, keep in mind = FP = is not good for final release implementation. > I could write some cool looking code, which does > something amazing in few lines, but when I come > back few days later and look at it, I find myself > struggling to understand it. As Phil and Shark said: use =E2=80=9C(*=E2=80=9D comments =E2=80=9C*)=E2= =80=9D ;) (aren't you talking in = an Ada Usenet here ? ;) ) > FP seems to be good for short programs. But try to > build a large software system with it, and things > start falling apart quickly. That is true of any bad design, what ever the language is. Also note tha= t = SML comes with Signature, Structure, and Functor, which all may help her= e. -- = =E2=80=9CSyntactic sugar causes cancer of the semi-colons.=E2=80=9D [Ep= igrams on = Programming =E2=80=94 Alan J. =E2=80=94 P. Yale University] =E2=80=9CStructured Programming supports the law of the excluded muddle.= =E2=80=9D [Idem] Java: Write once, Never revisit