home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.modula2
- Path: sparky!uunet!psgrain!randy
- From: randy@psg.com (Randy Bush)
- Subject: Re: pascal code to modula
- Message-ID: <1993Jan22.163533.8577@psg.com>
- Organization: Pacific Systems Group, Portland Oregon, US
- References: <8267@kielo.uta.fi>
- Date: Fri, 22 Jan 1993 16:35:33 GMT
- Lines: 18
-
- csfraw@vehka.cs.uta.fi (Francis Akoto) writes:
- > This is a pascal code
- > i,j: integer ;
- > i := i or j ;
-
- That most certainly is *not* Pascal code.
-
- If you are trying to achieve a bitwise inclusive OR of the two integers, then
- you would have to go through tagless variant records in a dirty hack.
-
- To do this in Modula-2, one would do something like
-
- VAR i, j : INTEGER;
- i := INTEGER ( BITSET(i) OR BITSET(j) )
-
- randy
- --
- randy@psg.com ...!uunet!m2xenix!randy
-