Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.programming.threads > #4388

I think there is still a "big" problem with C++ and C..

Path csiph.com!eternal-september.org!feeder.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail
From Sky89 <Sky89@sky68.com>
Newsgroups comp.programming.threads
Subject I think there is still a "big" problem with C++ and C..
Date Wed, 6 Jun 2018 15:17:05 -0400
Organization A noiseless patient Spider
Lines 53
Message-ID <pf9c01$sr1$4@dont-email.me> (permalink)
Mime-Version 1.0
Content-Type text/plain; charset=utf-8; format=flowed
Content-Transfer-Encoding 7bit
Injection-Date Wed, 6 Jun 2018 19:17:21 -0000 (UTC)
Injection-Info reader02.eternal-september.org; posting-host="8316e9034bf55d87c3b53114a0144957"; logging-data="29537"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19rzKFsQtyu/xj77WAh7tcy"
User-Agent Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0
Cancel-Lock sha1:08JPUb2bgyCk/ef0TBxdgjQuKTo=
Content-Language en-US
X-Mozilla-News-Host news://news.eternal-september.org:119
Xref csiph.com comp.programming.threads:4388

Show key headers only | View raw


Hello...


I think there is still a "big" problem with C++ and C..

Look at C++ explicit conversion functions, they were introduced in 
C++11, but this doesn't come by "default" in C++, like in modern Object 
Pascal of Delphi and FreePascal and like in ADA , because in C++ you 
have to write explicit conversion functions,  so this is not good for 
reliability in C++, and C++ doesn't by "default" come with range 
checking and Run-time checks that catch conversion from negative signed 
to unsigned, you have for example to add and use SafeInt library for 
that, and C++ doesn't by "default" catch out-of-bounds indices of 
dynamic and static arrays and catch, this is why C++ is not good for 
reliability.

But Delphi and FreePascal like ADA come with range checking and Run-time 
checks that catch conversion from negative signed to unsigned , and 
catch out-of-bounds indices of dynamic and static arrays and catch 
arithmetic overflow etc. and you can also dynamically catch this 
exception of ERangeError etc. and they do not allow those bad
implicit type conversions of C++ that are not good for reliability.

And you can carefully read the following, it is very important:

https://critical.eschertech.com/2010/07/07/run-time-checks-are-they-worth-it/


And about Escher C++ Verifier, read carefully:

"Escher C Verifier enables the development of formally-verifiable 
software in a subset of C (based on MISRA-C 2012)."

Read here:

http://www.eschertech.com/products/index.php


So it verifies just a "subset" of C, so that's not good for C++
because for other applications that are not a subset of C , it can
not do for example Run-time checks, so we are again into
this problem again that  C++ and C don't have range checking and many 
Run-time checks, so that's not good in C++ and C because it is not good 
for reliability and it is not good for safety-critical systems.


So for all the reasons above , i think i will stop coding in C++ and
i will quit C++.



Thank you,
Amine Moulay Ramdane.

Back to comp.programming.threads | Previous | Next | Find similar | Unroll thread


Thread

I think there is still a "big" problem with C++ and C.. Sky89 <Sky89@sky68.com> - 2018-06-06 15:17 -0400

csiph-web