Add units to swig_int and swig_double

Closes #1072
This commit is contained in:
Derek Bankieris 2020-11-05 09:49:02 -06:00
parent 3bffe16e2c
commit 3190292cf3
2 changed files with 8 additions and 0 deletions

View File

@ -1,6 +1,8 @@
%module swig_double
%include "std_string.i"
%{
#include "trick/swig/swig_double.hh"
@ -11,6 +13,8 @@
// expose the __str__ function to swig so that it can do pretty prints of parameters with units
class swig_double {
public:
std::string units;
char * __str__() ;
char * __repr__() ;

View File

@ -1,6 +1,8 @@
%module swig_int
%include "std_string.i"
%{
#include "trick/swig/swig_int.hh"
@ -11,6 +13,8 @@
// expose the __str__ function to swig so that it can do pretty prints of parameters with units
class swig_int {
public:
std::string units;
char * __str__() ;
char * __repr__() ;