File: utils.h

package info (click to toggle)
lua-torch-torch7 0~20170926-g89ede3b-6
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 2,336 kB
  • sloc: ansic: 19,550; makefile: 79; sh: 20
file content (36 lines) | stat: -rw-r--r-- 678 bytes parent folder | download | duplicates (2)
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
32
33
34
35
36
#ifndef TORCH_UTILS_INC
#define TORCH_UTILS_INC

#include "luaT.h"
#include "TH.h"

#include <lua.h>
#include <lualib.h>

#ifdef _WIN32
#else
#include <unistd.h>
#endif

#ifdef __cplusplus
# define TORCH_EXTERNC extern "C"
#else
# define TORCH_EXTERNC extern
#endif

#ifdef _WIN32
# ifdef torch_EXPORTS
#  define TORCH_API TORCH_EXTERNC __declspec(dllexport)
# else
#  define TORCH_API TORCH_EXTERNC __declspec(dllimport)
# endif
#else
# define TORCH_API TORCH_EXTERNC
#endif


TORCH_API THLongStorage* torch_checklongargs(lua_State *L, int index);
TORCH_API int torch_islongargs(lua_State *L, int index);
TORCH_API const char* torch_getdefaulttensortype(lua_State *L);

#endif