Skip to content

Commit 5afae42

Browse files
committed
Ifdef cplusplus in headers
1 parent 5c89bc3 commit 5afae42

22 files changed

+177
-0
lines changed

include/ladel.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@
1212
#ifndef LADEL_H
1313
#define LADEL_H
1414

15+
#ifdef __cplusplus
16+
extern "C" {
17+
#endif
18+
1519
#include "ladel_col_counts.h"
1620
#include "ladel_constants.h"
1721
#include "ladel_copy.h"
@@ -251,4 +255,8 @@ ladel_int ladel_row_del(ladel_factor *LD,
251255
* @}
252256
*/
253257

258+
#ifdef __cplusplus
259+
}
260+
#endif
261+
254262
#endif /*LADEL_H*/

include/ladel_add.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@
99
#ifndef LADEL_ADD_H
1010
#define LADEL_ADD_H
1111

12+
#ifdef __cplusplus
13+
extern "C" {
14+
#endif
15+
1216
#include "ladel_types.h"
1317

1418
/**
@@ -58,4 +62,8 @@ ladel_sparse_matrix *ladel_add_matrices_advanced( ladel_double alpha,
5862
ladel_int values,
5963
ladel_work *work);
6064

65+
#ifdef __cplusplus
66+
}
67+
#endif
68+
6169
#endif /* LADEL_ADD_H */

include/ladel_col_counts.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@
1010
#ifndef LADEL_COL_COUNTS_H
1111
#define LADEL_COL_COUNTS_H
1212

13+
#ifdef __cplusplus
14+
extern "C" {
15+
#endif
16+
1317
#include "ladel_types.h"
1418

1519
/**
@@ -26,4 +30,8 @@ ladel_int ladel_col_counts( ladel_sparse_matrix *M,
2630
ladel_symbolics *sym,
2731
ladel_work *work);
2832

33+
#ifdef __cplusplus
34+
}
35+
#endif
36+
2937
#endif /*LADEL_COL_COUNTS_H*/

include/ladel_constants.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
#ifndef LADEL_CONSTANTS_H
88
#define LADEL_CONSTANTS_H
99

10+
#ifdef __cplusplus
11+
extern "C" {
12+
#endif
13+
1014
/**
1115
* @name Constants
1216
* @{
@@ -64,4 +68,8 @@
6468
* @}
6569
*/
6670

71+
#ifdef __cplusplus
72+
}
73+
#endif
74+
6775
#endif /*LADEL_CONSTANTS_H*/

include/ladel_copy.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
#ifndef LADEL_COPY_H
88
#define LADEL_COPY_H
99

10+
#ifdef __cplusplus
11+
extern "C" {
12+
#endif
13+
1014
#include "ladel_types.h"
1115

1216
/**
@@ -51,4 +55,8 @@ void ladel_double_vector_copy( ladel_double *x,
5155
ladel_int size,
5256
ladel_double *y);
5357

58+
#ifdef __cplusplus
59+
}
60+
#endif
61+
5462
#endif /*LADEL_COPY_H*/

include/ladel_debug_print.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@
88
#ifndef LADEL_DEBUG_PRINT_H
99
#define LADEL_DEBUG_PRINT_H
1010

11+
#ifdef __cplusplus
12+
extern "C" {
13+
#endif
14+
1115
#include "ladel_global.h"
1216
#include "ladel_types.h"
1317

@@ -62,4 +66,8 @@ void ladel_print_factor_matlab(ladel_factor *LD);
6266
*/
6367
void ladel_print_set(ladel_set *set);
6468

69+
#ifdef __cplusplus
70+
}
71+
#endif
72+
6573
#endif

include/ladel_etree.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@
1010
#ifndef LADEL_ETREE_H
1111
#define LADEL_ETREE_H
1212

13+
#ifdef __cplusplus
14+
extern "C" {
15+
#endif
16+
1317
#include "ladel_types.h"
1418
/**
1519
* Computes the elimination tree of a matrix.
@@ -43,4 +47,8 @@ ladel_int ladel_etree_and_col_counts( ladel_sparse_matrix *M,
4347
ladel_work *work);
4448
#endif
4549

50+
#ifdef __cplusplus
51+
}
52+
#endif
53+
4654
#endif /*LADEL_ETREE_H*/

include/ladel_global.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
#ifndef LADEL_GLOBAL_H
88
#define LADEL_GLOBAL_H
99

10+
#ifdef __cplusplus
11+
extern "C" {
12+
#endif
13+
1014
#include "ladel_types.h"
1115
#include "ladel_constants.h"
1216
#include "ladel_copy.h"
@@ -199,4 +203,8 @@ ladel_work *ladel_workspace_free(ladel_work* work);
199203
ladel_work *ladel_workspace_allocate(ladel_int ncol);
200204

201205

206+
#ifdef __cplusplus
207+
}
208+
#endif
209+
202210
#endif /*LADEL_GLOBAL_H*/

include/ladel_ldl_numeric.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
#ifndef LDL_NUMERIC_H
88
#define LDL_NUMERIC_H
99

10+
#ifdef __cplusplus
11+
extern "C" {
12+
#endif
13+
1014
#include "ladel_types.h"
1115

1216
/**
@@ -39,4 +43,8 @@ ladel_int ladel_ldl_numeric(ladel_sparse_matrix *Mpp,
3943
ladel_factor *LD,
4044
ladel_work *work);
4145

46+
#ifdef __cplusplus
47+
}
48+
#endif
49+
4250
#endif /*LDL_NUMERIC_H*/

include/ladel_ldl_symbolic.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@
77
#ifndef LADEL_LDL_SYMBOLIC_H
88
#define LADEL_LDL_SYMBOLIC_H
99

10+
#ifdef __cplusplus
11+
extern "C" {
12+
#endif
13+
1014
#include "ladel_types.h"
1115

1216
/**
@@ -25,4 +29,8 @@ ladel_int ladel_ldl_symbolic( ladel_sparse_matrix *M,
2529
ladel_sparse_matrix *Mpp,
2630
ladel_work *work);
2731

32+
#ifdef __cplusplus
33+
}
34+
#endif
35+
2836
#endif /*LADEL_LDL_SYMBOLIC_H*/

0 commit comments

Comments
 (0)