Commit 72de18bc6755069457338fb35362ec91c302e28a
Committed by
Stéphane Raimbault
1 parent
788d7bb2
Place MODBUS_END_DECLS after including backend header files
All declarations in modbus-rtu.h and modbus-tcp.h should be inside MODBUS_BEGIN_DECLS and MODBUS_END_DECLS in order to make that functions properly accessible in C++ files. Signed-off-by: Stéphane Raimbault <stephane.raimbault@gmail.com>
Showing
1 changed file
with
2 additions
and
2 deletions
src/modbus.h
| @@ -193,9 +193,9 @@ uint8_t modbus_get_byte_from_bits(const uint8_t *src, int address, unsigned int | @@ -193,9 +193,9 @@ uint8_t modbus_get_byte_from_bits(const uint8_t *src, int address, unsigned int | ||
| 193 | float modbus_get_float(const uint16_t *src); | 193 | float modbus_get_float(const uint16_t *src); |
| 194 | void modbus_set_float(float real, uint16_t *dest); | 194 | void modbus_set_float(float real, uint16_t *dest); |
| 195 | 195 | ||
| 196 | -MODBUS_END_DECLS | ||
| 197 | - | ||
| 198 | #include "modbus-tcp.h" | 196 | #include "modbus-tcp.h" |
| 199 | #include "modbus-rtu.h" | 197 | #include "modbus-rtu.h" |
| 200 | 198 | ||
| 199 | +MODBUS_END_DECLS | ||
| 200 | + | ||
| 201 | #endif /* _MODBUS_H_ */ | 201 | #endif /* _MODBUS_H_ */ |