[sdiy] Programming Language Recommendation
jason at tribbeck.com
Tue Dec 8 08:42:19 CET 2020
That sort of reminds me of a friend of mine who was using a CPU (and
compiler) whose NULL address was 0x80000000.
Caused no end of trouble when porting code from programmers who instead of
comparing a pointer with NULL just checked it against zero...
I.e. they did this:
if (my_pointer) address_is_valid();
if (my_pointer != NULL) address_is_valid();
On Tue, 8 Dec 2020, 07:34 Ben Bradley, <ben.pi.bradley at gmail.com> wrote:
> The C99 standard points out one of the subtle differences between C
> and C++, as well as between one standard and the previous.The
> differences appear to have grown as the languages have gone through
> In the original C (and even in C++ today to remain compatible with so
> much code that operates this way), a "boolean" was just an integer,
> with false being the value 0 and true being any other value. C++ has
> the intrinsic type bool as part of the language which can have a value
> of either true or false, and this is preferred over using integers for
> boolean operations. C99 copied this, NOT by adding an intrinsic type,
> but by adding the stdbool.h header file to define these, as explained
> at this link. Just reading through it shows how "minute" changes in
> standards can cause problems with legacy code. Long story short, this
> is why programming can be such a pain:
> On Tue, Dec 8, 2020 at 1:48 AM john slee <indigoid at oldcorollas.org> wrote:
> > On Tue, 8 Dec 2020 at 07:48, Michael E Caloroso <
> mec.forumreader at gmail.com> wrote:
> > > Give me mid-level languages like C any day. You get non-cryptic error
> > > messages that are solved quickly and the language has been cast in
> > > stone since the 1980s.
> > If by "stone" you actually mean "mud", sure. The standard was updated in
> 1999 (C99), 2011 (C11) and again in 2018 (C17). Some major updates in there.
> > O'Reilly have a pretty good book covering the C99 changes called "21st
> Century C"
> > https://www.oreilly.com/library/view/21st-century-c/9781491904428/
> > John
> > _______________________________________________
> > Synth-diy mailing list
> > Synth-diy at synth-diy.org
> > http://synth-diy.org/mailman/listinfo/synth-diy
> > Selling or trading? Use marketplace at synth-diy.org
> Synth-diy mailing list
> Synth-diy at synth-diy.org
> Selling or trading? Use marketplace at synth-diy.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Synth-diy