🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #2310

Re: TIdHashMessageDigest5 and BCB 6

#2310
From: Andrue Cope [TeamB]
Date: Tue, 27 Jun 2006 12:36
32 lines
1910 bytes
Lapo Guidi wrote:

That error message means that the compiler was expecting to assign a
value into something and the something you gave it isn't something that
can be assigned to.

>  T4x4LongWordRecord Hash;
>  AnsiString Hex;
>  TIdHashMessageDigest5 *MD5=new TIdHashMessageDigest5();
>  Hash=MD5->HashValue("testmessage");

I haven't used Indy but looking at the online docs it appears that
HashValue() returns an array of 32 bit values. That means you're trying
to assign to an array which is not allowed in C++ eg;

typedef DWORD array[ 4 ] Tbaddy;

Tbaddy someFunction();

Tbaddy array=someFunction(); 
// An array cannot be assigned to hence is not a valid Left Hand Side 
//   of an expression

Then again why call it 'T4x4LongWord/Record/' if it is an array?

Presumably there is some C++ specific workaround implemented - what
does the C++ specific documentation say for HashValue() and
T4x4LongWord?
-- 
Andrue Cope [TeamB]
[Bicester, Uk]
http://info.borland.com/newsgroups/guide.html
Technical Details
Message-ID: <44a12658$1@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <44a11d2e@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,c6188de51aacc8b4
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Andrue Cope [TeamB]" <no.spam@not.a.valid.address>
Subject: Re: TIdHashMessageDigest5 and BCB 6
Newsgroups: borland.public.cppbuilder.internet.socket
References: <44a11d2e@newsgroups.borland.com>
User-Agent: XanaNews/1.18.1.1
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
NNTP-Posting-Host: 217.207.223.34
Message-ID: <44a12658$1@newsgroups.borland.com>
Date: 27 Jun 2006 05:36:40 -0700
X-Trace: newsgroups.borland.com 1151411800 217.207.223.34 (27 Jun 2006 05:36:40 -0700)
Lines: 32
X-Authenticated-User: acope
Path: arc1-ca.pugleaf.net!g2news2.google.com!news4.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail