Sha256: 9bd719785d8f753837cb1735e6e83485a8a09f88fb7eddc33c4ed6a5c1ab1454

Contents?: true

Size: 657 Bytes

Versions: 15

Compression:

Stored size: 657 Bytes

Contents

#ifndef PAIR_H_INCLUDED
#define PAIR_H_INCLUDED

#include "ruby.h"
#include "common.h"

enum { PAIR_ACTIVE = 1, PAIR_INACTIVE = 2 };

typedef struct PairStruct {
    char fst;
    char snd;
    char status;
    char __align;
} Pair;

typedef struct PairArrayStruct {
    Pair *pairs;
    int len;
} PairArray;

PairArray *PairArray_new(VALUE tokens);
#define pair_equal(a, b) \
    ((a).fst == (b).fst && (a).snd == (b).snd && ((a).status & (b).status & PAIR_ACTIVE))
double pair_array_match(PairArray *self, PairArray *other);
void pair_array_destroy(PairArray *pair_array);
void pair_print(Pair pair);
void pair_array_reactivate(PairArray *self);

#endif

Version data entries

15 entries across 15 versions & 3 rubygems

Version Path
amatch-0.4.1 ext/pair.h
amatch-0.4.0 ext/pair.h
amatch-0.3.1 ext/pair.h
patmcnally-amatch-0.2.4 ext/pair.h
amatch-0.3.0 ext/pair.h
amatch-rbx-0.2.12 ext/pair.h
amatch-0.2.11 ext/pair.h
amatch-0.2.10 ext/pair.h
amatch-0.2.9 ext/pair.h
amatch-0.2.8 ext/pair.h
amatch-0.2.7 ext/pair.h
amatch-0.2.6 ext/pair.h
amatch-0.2.5-x86-mswin32 ext/pair.h
amatch-0.2.5 ext/pair.h
amatch-0.2.4 ext/pair.h