www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/05/21/11:20:59

Message-ID: <3927FB98.4EB4F413@mtu-net.ru>
Date: Sun, 21 May 2000 19:07:04 +0400
From: "Alexei A. Frounze" <alex DOT fru AT mtu-net DOT ru>
X-Mailer: Mozilla 4.72 [en] (Win95; I)
X-Accept-Language: ru,en
MIME-Version: 1.0
To: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
Cc: djgpp AT delorie DOT com
Subject: Re: C++, complex, etc
References: <Pine DOT SUN DOT 3 DOT 91 DOT 1000521153547 DOT 18201D-100000 AT is>
X-Recipient: eliz AT is DOT elta DOT co DOT il
Reply-To: djgpp AT delorie DOT com

Eli Zaretskii wrote:
> 
> On Sun, 21 May 2000, Alexei A. Frounze wrote:
> 
> > > > How do I work with all those types? For example, if file position depends on
> > > > a string length, how do I mix those size_t and fpos_t correctly?
> > >
> > > In general, there should be no need to mix them.  There should be no
> > > reason for a file position to depend on a string length.
> >
> > IMHO C/C++ is for programming. Not for figuring out why your idea/algorithm
> > is faulty, although it's clear and logical.
> 
> Sorry, I don't follow.  Please explain how does this comment pertain to
> the question you asked and my response.

Okay. You said "there should be no need to mix them", right? Is somewhere
stated that I can't use strlen()s, sizeof()s, etc for making file offsets,
array indexes, etc? If nowhere this stated that implies I *can*. It's a very
logical thing: add sizes/lengths of objects and you'll find offset/index.
Right? And this idea is compiler independant.
If this is correct, why I can't mix those types (size_t, fpos_t, etc)? 
Or better in other words: how do I mix them correctly?

bye.
-- 
Alexei A. Frounze
-----------------------------------------
Homepage: http://alexfru.chat.ru
Mirror:   http://members.xoom.com/alexfru


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019