🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.fortran
Article #4494

Re: IAND(I,J) IOR(I,J) ???

#4494
From: Mark Stucky
Date: Mon, 25 Jan 1993 19:12
42 lines
1787 bytes
kroeker@oc1.oc.chemie.th-darmstadt.de (Martin Kroeker) writes:
: Could somebody please point me to a fortran source code that provides the
: functionality of the non-standard functions IAND, IOR, IEOR and BTEST ?
: I am trying to port a database application from a soon-to-be-junked IBM
: mainframe to a workstation where the fortran compiler is in fact f2c, and my
: own attempts at these bit-handling functions have failed miserably.
: Thanks in advance,
: Martin

Here's some...

      INTEGER*2 FUNCTION IAND(I1,I2)
C BITWISE LOGICAL FUNCTIONS - MAY HAVE TO BE CHANGED
C  ACCORDING TO A GIVEN SYSTEM'S IMPLEMENTATION
      INTEGER*2 I1,I2
      IAND = I1.AND.I2
      RETURN
      END

      INTEGER*2 FUNCTION IXOR(I1,I2)
      INTEGER*2 I1,I2
      IXOR = I1.XOR.I2
      RETURN
      END

      INTEGER*2 FUNCTION IOR(I1,I2)
      INTEGER*2 I1,I2
      IOR = I1.OR.I2
      RETURN
      END

      INTEGER*2 FUNCTION INOT(I1)
      INTEGER*2 I1
      INOT = .NOT.I1
      RETURN
      END

-- 
------------------------------------------------------------------------------
| Mark Stucky                         | Email:                               |
| United Technologies Research Center |     mark@ardnt1.res.utc.com          |
| East Hartford, CT.                  |or   mbs@utrcgw.res.utc.com           |
Technical Details
Message-ID: <1993Jan25.191236.27552@sun1x.actc.res.utc.com>
Path: arc1-ca.pugleaf.net!sparky!uunet!gatech!darwin.sura.net!newsserver.jvnc.net!yale.edu!yale!actcnews!sun1x!mark
References: <1jv0c0INNeco@rs2.hrz.th-darmstadt.de>

Show Full Headers
Complete Article Headers
Newsgroups: comp.lang.fortran
Path: arc1-ca.pugleaf.net!sparky!uunet!gatech!darwin.sura.net!newsserver.jvnc.net!yale.edu!yale!actcnews!sun1x!mark
From: mark@sun1x.actc.res.utc.com (Mark Stucky)
Subject: Re: IAND(I,J) IOR(I,J) ???
Message-ID: <1993Jan25.191236.27552@sun1x.actc.res.utc.com>
Organization: United Technologies Research Center
References: <1jv0c0INNeco@rs2.hrz.th-darmstadt.de>
Date: Mon, 25 Jan 1993 19:12:36 GMT
Lines: 42