🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.modula2
Article #2622

Re: Report on defect in M2 vs C (Was Modula-2, Modula-3, C or C++)

#2622
From: Robert Dewar
Date: Sat, 14 Oct 1995 19:36
8 lines
1175 bytes
        char p[10], q[10];
        int r = &p[5] - &q[2];

this is plainly incorrect C, so this is not the kind of issue that arises
in bounds checking. THe problem is that pointers can be havily aliased 
in C, and I repeat my observation, without auxiliary data structures of som
e kind you can't tell if a pointer is a pointer to an integer or a pointer
to an element of an array, so you can't tell if it is valid to decrement it.
Technical Details
Message-ID: <dewar.813699321@schonberg>
Path: arc1-ca.pugleaf.net!news.mathworks.com!panix!cmcl2!schonberg!dewar
References: <44hcri$rsm@theopolis.orl.mmc.com> <44rv1u$dfk@apollo.ekfido.kodak.com> <44uccq$lkd@theopolis.orl.mmc.com> <DFyAJF.KpC@research.att.com> <DAGENAIS.95Oct6084824@gutrune.vlsi.polymtl.ca> <dewar.813243156@schonberg> <45lj1i$o5i@frigate.doc.ic.ac.uk>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!news.mathworks.com!panix!cmcl2!schonberg!dewar
From: dewar@cs.nyu.edu (Robert Dewar)
Newsgroups: comp.lang.modula2,comp.lang.modula3,comp.lang.c,comp.lang.c++,comp.lang.ada
Subject: Re: Report on defect in M2 vs C (Was Modula-2, Modula-3, C or C++)
Date: 14 Oct 1995 15:36:38 -0400
Organization: Courant Institute of Mathematical Sciences
Message-ID: <dewar.813699321@schonberg>
References: <44hcri$rsm@theopolis.orl.mmc.com> <44rv1u$dfk@apollo.ekfido.kodak.com>  <44uccq$lkd@theopolis.orl.mmc.com> <DFyAJF.KpC@research.att.com> <DAGENAIS.95Oct6084824@gutrune.vlsi.polymtl.ca> <dewar.813243156@schonberg> <45lj1i$o5i@frigate.doc.ic.ac.uk>
NNTP-Posting-Host: schonberg.cs.nyu.edu
X-Newsreader: NN version 6.5.0 (NOV)