home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!munnari.oz.au!yoyo.aarnet.edu.au!news.adelaide.edu.au!news.adelaide.edu.au!usenet
- From: phil@iagu.itd.adelaide.edu.au (Phil Kernick)
- Newsgroups: alt.folklore.computers
- Subject: Re: command abbreviation
- Date: 23 Nov 1992 00:16:25 GMT
- Organization: Psychology Department, University of Adelaide
- Lines: 35
- Distribution: world
- Message-ID: <1ep7spINN364@huon.itd.adelaide.edu.au>
- References: <1992Nov13.190208.17876@cubic.com> <1ei49vINNr2c@uniwa.uwa.edu.au>
- Reply-To: phil@adam.adelaide.edu.au
- NNTP-Posting-Host: iagu.itd.adelaide.edu.au
-
- In article <1ei49vINNr2c@uniwa.uwa.edu.au>, john@gu.uwa.edu.au (John West) writes:
- > Zilog got it right (LoaD dest,src)
- > Motorola got it right (MOVE src,dest)
- > Intel got it wrong (MOVe dest,src)
- >
- > You can have the operands either way around, but *please*, at least get the
- > name right. strcpy should be src,dest (copy THIS to THAT).
-
- But you need to realise *why* strcpy is there.
-
- strcpy(t, s)
-
- is semantically equal in other languages to:
-
- t := s;
-
- That is, it is an assignment, and as such it should have its operands in the
- same order as an assignment. Since strings in C are not a primative type,
- but the assignment operator is still a requirement, strcpy is necessary.
- Now I grant you it might have been better to call is strassign...
-
- > Oh dear. Is this called a religious issue?
-
- Yep.
-
-
-
- Regards,
- Phil.
-
- --
- _-_|\ Phil Kernick "Sleep all day,
- / \ University of Adelaide Party all night,
- \_.-*_/ E-Mail: phil@adam.adelaide.edu.au It's fun to be a
- v Phone: +61 8 228 5914 Vampire!"
-