Re: Safe ANSI C Subset

flux@stack.nl (Mark van der Aalst)
7 Dec 1996 22:50:02 -0500

          From comp.compilers

Related articles
Safe ANSI C Subset Jan.Soderberg@mecel.se (Jan Soderberg) (1996-12-03)
Re: Safe ANSI C Subset clfranck@worldnet.att.net (Craig Franck) (1996-12-07)
Re: Safe ANSI C Subset flux@stack.nl (1996-12-07)
Re: Safe ANSI C Subset ae59@rz.uni-karlsruhe.de (1996-12-07)
Re: Safe ANSI C Subset winney@erim.org (1996-12-07)
Re: Safe ANSI C Subset vonbrand@inf.utfsm.cl (Horst von Brand) (1996-12-10)
Re: Safe ANSI C Subset Roger@natron.demon.co.uk (Roger Barnett) (1996-12-15)
Re: Safe ANSI C Subset dmason@jupiter.scs.ryerson.ca (Dave Mason) (1997-01-09)
| List of all articles for this month |

From: flux@stack.nl (Mark van der Aalst)
Newsgroups: comp.compilers,comp.lang.c,comp.lang.c.moderated
Date: 7 Dec 1996 22:50:02 -0500
Organization: MCGV Stack, Eindhoven University of Technology, the Netherlands.
References: 96-12-030
Keywords: C, realtime

Jan Soderberg (Jan.Soderberg@mecel.se) wrote:
> Does anyone know of any ANSI C subsets defined for safety critical
> real-time applications?


Short answer ;


Yes, there's a 'subset' called C++


A bit longer answer ;


I am not aware of any subsets of 'C' wich handle this sort of thing, I
do know that most military applications (at least in this country) are
written in plain 'C' - although they do use specific libraries wich
were made for some critical operations (but even those are mainly
system-dependant parts wich deal with stuff like atomic timers,
etc). This is actually quite an interesting thing, Maybe it would be
an idea to ask around at NASA - they probably know more about this
sort of thing - although I'm not even sure if they use 'C' ... but
then again, maybe they do, e.g.


  int i;


  for( i = 10 ; i > -1 ; i--)
        do_countdown(i);


  boost_rockets();


  while(not_crashed)
    {
        g_force++;


        if(!doors_closed)
                shout("oh dear...");


        if(out_of_orbit)
          {
            if(landed)
              {
                  if(aliens_present)
                      notify_mulder_and_scully();
                  else
                      play_some_weightless_basketball();
              }
        }
    }


;)


Cheers, flux.
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.