Changeset 7258c6a in buchla-68k for lib700


Ignore:
Timestamp:
07/09/2017 04:45:34 PM (7 years ago)
Author:
Thomas Lopatic <thomas@…>
Branches:
master
Children:
8618599
Parents:
0292fbb
Message:

Use standard integer types.

Location:
lib700
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • lib700/bitrev.c

    r0292fbb r7258c6a  
    66*/
    77
    8 static int bitmask[] = {
     8static int16_t bitmask[] = {
    99
    1010        0x0001, 0x0002, 0x0004, 0x0008,
     
    2222*/
    2323
    24 int bitrev(int bitsin, int nbits)
     24int16_t bitrev(int16_t bitsin, int16_t nbits)
    2525{
    26         int     m, n;
     26        int16_t m, n;
    2727
    2828        n = 0;
  • lib700/ctype.c

    r0292fbb r7258c6a  
    3737}
    3838
    39 char __atab[] = {       /* EOF won't work properly with this table */
     39int8_t __atab[] = {     /* EOF won't work properly with this table */
    4040#endif
    4141
  • lib700/ispow2.c

    r0292fbb r7258c6a  
    1313#include "stddefs.h"
    1414
    15 short ispow2(long x)
     15int16_t ispow2(int32_t x)
    1616{
    17         register short i;
    18         register long k;
     17        register int16_t i;
     18        register int32_t k;
    1919
    2020        k = 0x00000001L;                /* setup the bit mask in k */
  • lib700/mangle.c

    r0292fbb r7258c6a  
    2020*/
    2121
    22 long mangle(long *bitmap, short nb, long ib)
     22int32_t mangle(int32_t *bitmap, int16_t nb, int32_t ib)
    2323{
    24         register long   bm;                     /* scan mask */
    25         register long   rv;                     /* result value */
    26         register short  bn;                     /* bit number (bitmap index) */
     24        register int32_t        bm;                     /* scan mask */
     25        register int32_t        rv;                     /* result value */
     26        register int16_t        bn;                     /* bit number (bitmap index) */
    2727
    2828        bm = 0x00000001L;                       /* setup scan mask */
  • lib700/micons.c

    r0292fbb r7258c6a  
    3535*/
    3636
    37 short micons(short wi)
     37int16_t micons(int16_t wi)
    3838{
    39         return((short)( ((wi << 8) & 0xFF00) | ((wi >> 8) & 0x00FF) ) );
     39        return((int16_t)( ((wi << 8) & 0xFF00) | ((wi >> 8) & 0x00FF) ) );
    4040}
    4141
     
    4646*/
    4747
    48 int miconi(int wi)
     48int16_t miconi(int16_t wi)
    4949{
    50         if (sizeof (int) == 4)
     50        if (sizeof (int16_t) == 4)
    5151                return( ((wi << 24) & 0xFF000000L) | ((wi << 8) & 0x00FF0000L) |
    5252                        ((wi >> 8) & 0x0000FF00L) | ((wi >> 24) & 0x000000FFL) );
     
    6161*/
    6262
    63 long miconl(long wi)
     63int32_t miconl(int32_t wi)
    6464{
    6565        return( ((wi << 24) & 0xFF000000L) | ((wi << 8) & 0x00FF0000L) |
  • lib700/tolower.c

    r0292fbb r7258c6a  
    1414*/
    1515
    16 int tolower(int c)
     16int16_t tolower(int16_t c)
    1717{
    18         int     x;
     18        int16_t x;
    1919
    2020        if (isascii(c)) {
  • lib700/toupper.c

    r0292fbb r7258c6a  
    1414*/
    1515
    16 int toupper(int c)
     16int16_t toupper(int16_t c)
    1717{
    18         int     x;
     18        int16_t x;
    1919
    2020        if (isascii(c)) {
Note: See TracChangeset for help on using the changeset viewer.