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.2 required=5.0 tests=BAYES_00,INVALID_MSGID, TO_MALFORMED autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,fee8802cc3d8334d X-Google-Attributes: gid103376,public X-Google-Thread: 10a146,fee8802cc3d8334d X-Google-Attributes: gid10a146,public From: D'Arcy Smith Subject: Re: Ada and Java. different behaviour. casting long to int problem. Date: 1999/06/16 Message-ID: <37680F83.4426B424@itools.symantec.com>#1/1 X-Deja-AN: 490406547 Content-Transfer-Encoding: 7bit References: <7jt2c0$vrb@drn.newsguy.com> <7k57vb$1ipf@drn.newsguy.com> <3766650F.705125B7@pwfl.com> <7k64t7$igo$1@its.hooked.net> <7k689a$ci2@drn.newsguy.com> <3766C842.E1EAB60A@pwfl.com> <3766D1CC.D712895E@itools.symantec.com> <7k8nn5$qcb$1@its.hooked.net> <3767E8A2.EF1A0570@itools.symantec.com> <7k8tv3$3gm@drn.newsguy.com> To: kirk@spam_free X-Accept-Language: en Content-Type: text/plain; charset=us-ascii X-Complaints-To: news@itools.symantec.com X-Trace: it.visualcafe.com 929566452 19855 155.64.77.40 (16 Jun 1999 20:54:12 GMT) Organization: Internet Tools Division, Symantec Corp. Mime-Version: 1.0 NNTP-Posting-Date: 16 Jun 1999 20:54:12 GMT Newsgroups: comp.lang.ada,comp.lang.java.programmer Date: 1999-06-16T20:54:12+00:00 List-Id: kirk@spam_free wrote: > In article <3767E8A2.EF1A0570@itools.symantec.com>, D'Arcy says... > >How long has C been around? > And how long have we had buggy code? And how wide a margine can you miss my point by? "> Things designed to be used by humans should strive for "reasonable", > "expected" behavior whenever possible, and should notify the human when > that's not possible." If you come from C the expected behaviour is exactly what Java does. You may not agree with the behaviour but it is completely expected given what influenced Java. Perhaps if you look at it like this: Java is not an end. We had C... good. C++ came along and removed some of the "bad" things - use const instead of #define etc... Java came along and removed some additional "bad" things from C and then removed some "bad" things from C++. Java also did some silly things. One day a language is going to come along and take parts of Java and we will wind up with something that is "better". Please note the use of ""s all over there. > >Its not like this is a new issue. > I agree. less than best language features are nothing new. > C/C++ as well as Java have them. I'm sure Ada has some silly things as well... I don't know what they are since I've never used it. > >And if you take the people using Java as a first language then > >there is no issue (they get told that this is the way it is). > you are repeating the same argument you said over and over, which is, > as long as it is documented, then it is OK. No I never said that. I said (or implied) as long as it is documented and people screw up then it is THEIR fault not the fault of the language. > The point of this discussion is beyond this simple view. It is about > one language aspect of java that many think is bad. replying by saying: > "but it is documented" is a cop-out argument in my opinion. I've agreed that it probably would be better to handle it in a different way. It doesn't get over it. > >for some things)... but get over it. > get over it? we hear some people who want to use Java to build nuclear > plant control software with and to use Java to write the software that > will control systems that if failed will end up killing many people. Ada software has _never_ failed? Ada software has never had programmers who make mistakes. Cool. Good for you. Now if you say Ada offers features to avoid certain types of mistakes then I'll agree. Can Java programmers do something to work around the fact that the language doens't support overflow exceptions? Sure I've already given a code snippet. Makes to code slower and move verbose but it does what you want (or at least is the basis for that). Would Java be more robust if it handled overlows - sure. > It is important that people know about the lack of safety in Java, so > not everyone get caught in the hype that is going around. Ummm... if people don;t read the language spec then that is their problem (and yes I have read the C/C++/Java language specs). Now in the case of a nuclear power plant (which unless the Java license has changed you can't use Java for IIRC) then yes it is all of our problem. But I am sure that someone writing bad Ada code could cause just as many problems (just different ones :-) > when my life is on line, I will not get over it. Again - there has _never_ been a bug in any Ada software? > it is too bad that the java designers did not take the time and go all > the way and design a really good language, they seem to have started > doing this, but the Sun marketing guys must have told to hurry up, and > they sort of handed over a half completed job of whatever they had > completed at the time. I'll agree with that - but I really doubt that they would have made the Overflow change that you are wanting. ..darcy -- D'Arcy Smith Sr. Software Engineer Symantec, Internet Tools Division If you simply reply to this email it will get forwarded to /dev/null My Email address is darcy at itools dot symantec dot com