aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBenoit Germain <b n t DOT g e r m a i n AT g m a i l DOT c o m>2018-11-02 16:00:41 +0100
committerBenoit Germain <b n t DOT g e r m a i n AT g m a i l DOT c o m>2018-11-02 16:00:41 +0100
commit846322e52afdad04c92c90c8d43ecc19e46a2b9e (patch)
treec661a76382c3fb4f562bf7aca93a26143749c731 /src
parente21a392b9c5f22c92e56fb0e0897cb8e77d51d0f (diff)
downloadlanes-846322e52afdad04c92c90c8d43ecc19e46a2b9e.tar.gz
lanes-846322e52afdad04c92c90c8d43ecc19e46a2b9e.tar.bz2
lanes-846322e52afdad04c92c90c8d43ecc19e46a2b9e.zip
Enum buildfix
Diffstat (limited to 'src')
-rw-r--r--src/deep.h13
-rw-r--r--src/lanes.c4
-rw-r--r--src/tools.h8
3 files changed, 12 insertions, 13 deletions
diff --git a/src/deep.h b/src/deep.h
index aeeb828..918de6a 100644
--- a/src/deep.h
+++ b/src/deep.h
@@ -12,8 +12,6 @@
12// forwards 12// forwards
13struct s_Universe; 13struct s_Universe;
14typedef struct s_Universe Universe; 14typedef struct s_Universe Universe;
15enum eLookupMode;
16typedef enum eLookupMode LookupMode;
17 15
18#if !defined LANES_API // when deep is compiled standalone outside Lanes 16#if !defined LANES_API // when deep is compiled standalone outside Lanes
19#if (defined PLATFORM_WIN32) || (defined PLATFORM_POCKETPC) 17#if (defined PLATFORM_WIN32) || (defined PLATFORM_POCKETPC)
@@ -23,6 +21,14 @@ typedef enum eLookupMode LookupMode;
23#endif // (defined PLATFORM_WIN32) || (defined PLATFORM_POCKETPC) 21#endif // (defined PLATFORM_WIN32) || (defined PLATFORM_POCKETPC)
24#endif // LANES_API 22#endif // LANES_API
25 23
24enum eLookupMode
25{
26 eLM_LaneBody, // send the lane body directly from the source to the destination lane
27 eLM_ToKeeper, // send a function from a lane to a keeper state
28 eLM_FromKeeper // send a function from a keeper state to a lane
29};
30typedef enum eLookupMode LookupMode;
31
26enum eDeepOp 32enum eDeepOp
27{ 33{
28 eDO_new, 34 eDO_new,
@@ -30,8 +36,9 @@ enum eDeepOp
30 eDO_metatable, 36 eDO_metatable,
31 eDO_module, 37 eDO_module,
32}; 38};
39typedef enum eDeepOp DeepOp;
33 40
34typedef void* (*luaG_IdFunction)( lua_State* L, enum eDeepOp op_); 41typedef void* (*luaG_IdFunction)( lua_State* L, DeepOp op_);
35 42
36// ################################################################################################ 43// ################################################################################################
37 44
diff --git a/src/lanes.c b/src/lanes.c
index aeba5fb..b89e3f5 100644
--- a/src/lanes.c
+++ b/src/lanes.c
@@ -430,7 +430,7 @@ struct s_Linda
430}; 430};
431#define LINDA_KEEPER_HASHSEED( linda) (linda->group ? linda->group : (ptrdiff_t)linda) 431#define LINDA_KEEPER_HASHSEED( linda) (linda->group ? linda->group : (ptrdiff_t)linda)
432 432
433static void* linda_id( lua_State*, enum eDeepOp); 433static void* linda_id( lua_State*, DeepOp);
434 434
435static inline struct s_Linda* lua_toLinda( lua_State* L, int idx_) 435static inline struct s_Linda* lua_toLinda( lua_State* L, int idx_)
436{ 436{
@@ -1126,7 +1126,7 @@ LUAG_FUNC( linda_towatch)
1126* For any other strings, the ID function must not react at all. This allows 1126* For any other strings, the ID function must not react at all. This allows
1127* future extensions of the system. 1127* future extensions of the system.
1128*/ 1128*/
1129static void* linda_id( lua_State* L, enum eDeepOp op_) 1129static void* linda_id( lua_State* L, DeepOp op_)
1130{ 1130{
1131 switch( op_) 1131 switch( op_)
1132 { 1132 {
diff --git a/src/tools.h b/src/tools.h
index df429f7..11a541c 100644
--- a/src/tools.h
+++ b/src/tools.h
@@ -25,14 +25,6 @@ void luaG_copy_one_time_settings( Universe* U, lua_State* L, lua_State* L2);
25 25
26// ################################################################################################ 26// ################################################################################################
27 27
28enum eLookupMode
29{
30 eLM_LaneBody, // send the lane body directly from the source to the destination lane
31 eLM_ToKeeper, // send a function from a lane to a keeper state
32 eLM_FromKeeper // send a function from a keeper state to a lane
33};
34typedef enum eLookupMode LookupMode;
35
36int luaG_inter_copy_package( Universe* U, lua_State* L, lua_State* L2, int package_idx_, LookupMode mode_); 28int luaG_inter_copy_package( Universe* U, lua_State* L, lua_State* L2, int package_idx_, LookupMode mode_);
37 29
38int luaG_inter_copy( Universe* U, lua_State* L, lua_State* L2, uint_t n, LookupMode mode_); 30int luaG_inter_copy( Universe* U, lua_State* L, lua_State* L2, uint_t n, LookupMode mode_);