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-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,79bbf7e359159d0d X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-04-10 07:03:59 PST Path: supernews.google.com!sn-xit-02!supernews.com!news.gv.tsc.tdk.com!falcon.america.net!sunqbc.risq.qc.ca!nntp1.njy.teleglobe.net!teleglobe.net!newsfeed.mesh.ad.jp!newsranger.com!www.newsranger.com!not-for-mail Newsgroups: comp.lang.ada From: Ted Dennison Sender: usenet@www.newsranger.com References: <9ao1if$cq9$1@taliesin.netcom.net.uk> <3ACFC902.115624A1@mindspring.com> <9atph1$n3h$1@taliesin.netcom.net.uk> Subject: Re: newbie can't get exceptions to work! Message-ID: Date: Tue, 10 Apr 2001 14:00:14 GMT NNTP-Posting-Host: 209.208.22.130 X-Complaints-To: abuse@newsranger.com X-Trace: www.newsranger.com 986911214 209.208.22.130 (Tue, 10 Apr 2001 10:00:14 EDT) NNTP-Posting-Date: Tue, 10 Apr 2001 10:00:14 EDT Organization: http://www.newsranger.com Xref: supernews.google.com comp.lang.ada:6706 Date: 2001-04-10T14:00:14+00:00 List-Id: In article <9atph1$n3h$1@taliesin.netcom.net.uk>, Ayende Rahien says... > > >"Ted Dennison" wrote in message >news:KgqA6.1193$FY5.91793@www.newsranger.com... >> little more specific. I still don't see why someone trying to track down >> an unrelated problem in some source code always needs to know that a >> particular value came out of an array instead of a function. > >What about just *understanding* a code? >For large works, you need to read a lot of code, and knowing that X is an That's my exact point. For small works, its OK to try to take in every little detail about how everything works in at once. If you are a reaonsably sharp person, you ought to be able to do it. But attempting to do that in a large program would be disasterous. If you can do that, you should be off defeating Kasparof and Deep Blue, not toying around with programming. :-) For a large program, you need to be able to read things in general first, without getting bogged down in nitty implementation details. You'd like to know generally where data comes from in the system, which you should be able to get from the object/subprogram name. But how that data is retrieved (record, array, complicated calculation, etc.) is only important for the particular path that contains the bug you are looking for (or other paths that you suspect might). There are only so many things I can keep in my head at once. If the syntax provides detailed implementation information when I don't need it, it is squandering some of my brain space. Perhaps some of you are just much better endowed than I in that regard. :-) >An array is a container for data, a function is something that return data >based on some code that is in it. When its just sitting in memory doing nothing, yes its just data. But if you want to access that data by indexing into the array, that takes code to accomplish. We are not talking about an array, we are talking about an array *indexing operation*. This is something that returns data, using a canned function that maps one discrete value to a (hopefully) pre-loaded object using a simple mathamatical calculation. There is code involved, just like with any function. In fact we could, if we wanted, write a (pragma inlined) function that did the exact same thing and generates the exact same object code. But since this particular function is so common and useful, it got its own type and syntax. That doesn't make it fundametally different from a function. --- T.E.D. homepage - http://www.telepath.com/dennison/Ted/TED.html home email - mailto:dennison@telepath.com