blueloveTH 1 год назад
Родитель
Сommit
b63ae3741d
3 измененных файлов с 11 добавлено и 11 удалено
  1. 4 4
      include/pocketpy/objects/dict.h
  2. 3 3
      include/pocketpy/objects/pyvar.h
  3. 4 4
      include/pocketpy/objects/sourcedata.h

+ 4 - 4
include/pocketpy/objects/dict.h

@@ -1,13 +1,13 @@
 #pragma once
 #pragma once
 
 
-#ifdef __cplusplus
-extern "C" {
-#endif
-
 #include <stdbool.h>
 #include <stdbool.h>
 #include "pocketpy/objects/pyvar.h"
 #include "pocketpy/objects/pyvar.h"
 #include "pocketpy/common/vector.h"
 #include "pocketpy/common/vector.h"
 
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 /** @brief `pkpy_Dict` is the Dict type in Python */
 /** @brief `pkpy_Dict` is the Dict type in Python */
 typedef struct {
 typedef struct {
     int count;             /** number of elements in the dictionary */
     int count;             /** number of elements in the dictionary */

+ 3 - 3
include/pocketpy/objects/pyvar.h

@@ -1,12 +1,12 @@
 #pragma once
 #pragma once
 
 
+#include <stdbool.h>
+#include <stdint.h>
+
 #ifdef __cplusplus
 #ifdef __cplusplus
 extern "C" {
 extern "C" {
 #endif
 #endif
 
 
-#include <stdbool.h>
-#include <stdint.h>
-
 /**
 /**
  * @brief A python value in pocketpy.
  * @brief A python value in pocketpy.
  */
  */

+ 4 - 4
include/pocketpy/objects/sourcedata.h

@@ -1,13 +1,13 @@
 #pragma once
 #pragma once
 
 
-#ifdef __cplusplus
-extern "C" {
-#endif
-
 #include <stdbool.h>
 #include <stdbool.h>
 #include "pocketpy/common/str.h"
 #include "pocketpy/common/str.h"
 #include "pocketpy/common/vector.h"
 #include "pocketpy/common/vector.h"
 
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 enum CompileMode { EXEC_MODE, EVAL_MODE, REPL_MODE, JSON_MODE, CELL_MODE };
 enum CompileMode { EXEC_MODE, EVAL_MODE, REPL_MODE, JSON_MODE, CELL_MODE };
 
 
 struct pkpy_SourceData {
 struct pkpy_SourceData {