TIP: Click on subject to list as thread! ANSI
echo: aust_c_here
to: Paul Wankadia
from: Michael Stapleton
date: 1996-10-25 19:27:00
subject: Re: Auto string-length determination

-=> Quoting Paul Wankadia to Paul Edwards <=-

Hello Paul,

PW> "sizeof String" ???  Are you SURE???  No one else has pointed
PW> that out!

PE> No one else would call you a Borland Fan if you went "void main"
PE> either, doesn't say much.

PW> I don't usually return values from programs, that's all :)

What, aren't they good enough to be used in batch files?  :) 

PE> The sizeof operator yields the size (in bytes) of its operand,
PE> which may be an expression or the parenthesized name of a type.

PW> Oo er...

PE> Now, as far as I am aware, an "expression" would include putting
PE> the variable in parentheses, e.g.  x and (x) should both be
PE> valid

PW> Well, I hope so.  Maybe that's why I couldn't get the sizeof
PW> String when I was in a different function?  :)

Yep.

PE> Until then, for the simple cases, I'll just do as they said
PE> above.  At least for the same reason that I don't go x = (y) *
PE> (4).

PW> Don't you?  How strange...  :) I suppose, since sizeof is an
PW> operator...?  (It IS an operator, isn't it?)

It sure is.

Michael Stapleton of Graphic Bits.

 * AmyBW v2.10 *
... This tagline is encrypted
--- AdeptXBBS v1.07f (Registered)
* Origin: Mach One BBS (3:713/615)
SEEN-BY: 633/267 270
@PATH: 713/317 711/808 50/99 635/728 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.