aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os/event_defs.h
blob: 983b70be97d46da438948900639126903d4f79ed (plain) (blame)
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
#ifndef NVIM_OS_EVENT_DEFS_H
#define NVIM_OS_EVENT_DEFS_H

#include "nvim/os/job_defs.h"
#include "nvim/os/rstream_defs.h"

typedef enum {
  kEventSignal,
  kEventRStreamData,
  kEventJobExit
} EventType;

typedef struct {
  EventType type;
  union {
    int signum;
    struct {
      RStream *ptr;
      bool eof;
    } rstream;
    Job *job;
  } data;
} Event;

#endif  // NVIM_OS_EVENT_DEFS_H