File: main.cpp

package info (click to toggle)
xsimd 14.0.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 3,144 kB
  • sloc: cpp: 41,628; sh: 541; makefile: 184; python: 117
file content (31 lines) | stat: -rw-r--r-- 1,140 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/***************************************************************************
 * Copyright (c) Johan Mabille, Sylvain Corlay, Wolf Vollprecht and         *
 * Martin Renou                                                             *
 * Copyright (c) QuantStack                                                 *
 * Copyright (c) Serge Guelton                                              *
 *                                                                          *
 * Distributed under the terms of the BSD 3-Clause License.                 *
 *                                                                          *
 * The full license is in the file LICENSE, distributed with this software. *
 ****************************************************************************/
#ifndef EMSCRIPTEN
#define DOCTEST_CONFIG_IMPLEMENT_WITH_MAIN
#include "doctest/doctest.h"
#else

#define DOCTEST_CONFIG_IMPLEMENT
#include "doctest/doctest.h"
#include <emscripten/bind.h>

int run_tests()
{
    doctest::Context context;
    return context.run();
}

EMSCRIPTEN_BINDINGS(my_module)
{
    emscripten::function("run_tests", &run_tests);
}

#endif