Skip to content

Commit

Permalink
move extern into the .h file, remove unused includes
Browse files Browse the repository at this point in the history
  • Loading branch information
camila314 committed Jan 16, 2025
1 parent f98be38 commit da5d6ac
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
8 changes: 8 additions & 0 deletions include/geode-ipc.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@
#include <stdbool.h>
#include <stddef.h>

#ifdef __cplusplus
extern "C" {
#endif

/**
* Send IPC message. Response needs to be freed.
* Message is NULL if Geode IPC could not be connected to.
Expand All @@ -15,3 +19,7 @@ char* geode_ipc_send(char const* message);
* Message is NULL if Geode IPC could not be connected to.
*/
char* geode_ipc_send_timeout(char const* message, double timeout);

#ifdef __cplusplus
}
#endif
4 changes: 0 additions & 4 deletions include/geode-ipc.hpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
#include <string>
#include <matjson.hpp>

extern "C" {
#include "geode-ipc.h"
}

namespace GeodeIPC {
/**
* Send raw string and accept raw value. Not recommended,
Expand Down
3 changes: 2 additions & 1 deletion src/geode-ipc.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <geode-ipc.hpp>
#include <iostream>
#include <geode-ipc.h>

using namespace geode;
using namespace matjson;

Expand Down

0 comments on commit da5d6ac

Please sign in to comment.