source: git/Singular/dyn_modules/bigintm/mod_main.cc @ b5dd9b

fieker-DuValspielwiese
Last change on this file since b5dd9b was b5dd9b, checked in by Hans Schönemann <hannes@…>, 7 years ago
use include ".." for singular related .h, p1
  • Property mode set to 100644
File size: 992 bytes
Line 
1#include "kernel/mod2.h"
2
3#include "Singular/mod_lib.h"
4
5#include "Singular/blackbox.h"
6
7#include "Singular/tok.h"
8#include "Singular/ipid.h"
9#include "Singular/lists.h"
10
11#include <dlfcn.h>
12
13#include "bigintm.h"
14
15namespace
16{
17
18static inline void NoReturn(leftv& res)
19{
20  res->rtyp = NONE;
21  res->data = NULL;
22}
23
24
25/// listing all blackbox types (debug stuff)
26static BOOLEAN printBlackboxTypes0(leftv __res, leftv /*__v*/)
27{
28  NoReturn(__res);
29  printBlackboxTypes();
30  return FALSE;
31}
32
33/// init the bigintm (a sample blackbox) type
34static BOOLEAN bigintm_setup0(leftv __res, leftv /*__v*/)
35{
36  NoReturn(__res);
37  return bigintm_setup();
38}
39
40}
41
42
43extern "C" int SI_MOD_INIT(bigintm)(SModulFunctions* psModulFunctions)
44{
45   psModulFunctions->iiAddCproc(currPack->libname,(char*)"printBlackboxTypes",FALSE, printBlackboxTypes0);
46   psModulFunctions->iiAddCproc(currPack->libname,(char*)"bigintm_setup",FALSE, bigintm_setup0);
47
48   // Q: should we call 'bigintm_setup' here??!?!?
49   return MAX_TOK;
50}
Note: See TracBrowser for help on using the repository browser.