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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,703c4f68db81387d X-Google-Thread: 109fba,703c4f68db81387d X-Google-Thread: 115aec,703c4f68db81387d X-Google-Thread: f43e6,703c4f68db81387d X-Google-Attributes: gid103376,gid109fba,gid115aec,gidf43e6,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!news.glorb.com!news.addix.net!border2.nntp.ams.giganews.com!nntp.giganews.com!feeder.news-service.com!post.news-service.com!news1.surfino.com!not-for-mail Message-Id: <1939901.m0aFKdFWhT@linux1.krischik.com> From: Martin Krischik Subject: Re: [OT] Re: Teaching new tricks to an old dog (C++ -->Ada) Newsgroups: comp.lang.ada,comp.lang.c++,comp.realtime,comp.software-eng Reply-To: martin@krischik.com Date: Sat, 05 Mar 2005 22:32:37 +0100 References: <4229bad9$0$1019$afc38c87@news.optusnet.com.au> <1110032222.447846.167060@g14g2000cwa.googlegroups.com> <871xau9nlh.fsf@insalien.org> <3SjWd.103128$Vf.3969241@news000.worldonline.dk> <2826628.d8srykTIx7@linux1.krischik.com> <1110053691.117106@athnrd02> Organization: None User-Agent: KNode/0.8.0 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit X-Complaints-To: abuse@surfino.com NNTP-Posting-Host: 83.169.175.19 (83.169.175.19) NNTP-Posting-Date: Sun, 06 Mar 2005 09:00:13 +0100 X-Trace: 9f5f3422ab88df60c0ab621917 Xref: g2news1.google.com comp.lang.ada:8727 comp.lang.c++:44301 comp.realtime:1003 comp.software-eng:4534 Date: 2005-03-05T22:32:37+01:00 List-Id: Ioannis Vranos wrote: > Martin Krischik wrote: > >> Well that's easy: >> >> unsigned int X = -1; >> >> char Y [10]; >> Y [10] = "X"; >> >> Or bit more subtle: >> >> unsigned int X Day_Of_Month = 32; > Day_Of_Month does not compile. Shure - the X is to much - a cut/copy/paste mistake. > You can make the Day_Of_Month an enum: Day_Of_Month - not Day_Of_Week ;-) > Bottom line is in C++ you can be as safe and as high level you like. > Just pick the suitable libraries or frameworks. I know. But the *default* is unsave - you have to explicitly *activate* save. While in Ada it's the other way round (yes you can deactivate save in Ada if you need to). Martin -- mailto://krischik@users.sourceforge.net Ada programming at: http://ada.krischik.com