#include "binary.h"
#include "misc.h"
#include "scrmreader.h"
#include "typedefs.h"
#include "error.h"
#include <ctype.h>
#include <errno.h>
#include <getopt.h>
#include <gsl/gsl_rng.h>
#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
|
| struct | Stack |
| | Treat a vector of tipId_t values as a push-down stack. More...
|
| |
|
|
static void | usage (void) |
| | Print usage message and die.
|
| |
| static Stack * | Stack_new (int dim, tipId_t buff[dim]) |
| | This stack is local to this file. More...
|
| |
|
static void | Stack_free (Stack *stk) |
| | Frees the stack but not the underlying buffer.
|
| |
|
static void | Stack_push (Stack *self, tipId_t x) |
| | Add an entry to the tail of the stack, checking bounds.
|
| |
|
static void | generatePatterns (int bit, int npops, Stack *stk, tipId_t pat, int doSing) |
| | Call as generatePatterns(0, npops, stk, 0); Recursive function, which generates all legal site patterns and pushes them onto a stack.
|
| |
|
int | main (int argc, char **argv) |
| |
◆ Stack_new()
| static Stack * Stack_new |
( |
int |
dim, |
|
|
tipId_t |
buff[dim] |
|
) |
| |
|
static |
This stack is local to this file.
It provides a bounds-controlled interface to an external array, which is passed as an argument, buff, to Stack_new.
◆ useMsg
Initial value:=
"\nUsage: scrmpat [options] <x> <y> ...\n"
" where <x>, <y>, etc. are arbitrary labels, whose number and order\n"
" must agree with that of the populations specified in the scrm command\n"
" line (using scrm arguments -I and -eI). Labels may not include the\n"
" character \":\". Writes to standard output."