0

I have a typedef defined in a header as such below:

typedef struct data
{
    std::string id;
    std::string status;

} data_set;

I want to be able to wrap this in a Boost Python Module to make it available since it's passed into other methods. Would this be wrapped as a class in boost? or is there a specific way to wrap typedefs?

Sal
  • 625
  • 2
  • 7
  • 11

1 Answers1

0

I don't think you need the typedef here. Simply

struct data_set
{
    std::string id;
    std::string status;

};

is mostly equivalent. That being said, now you can just treat it as a class with the Boost Python Module.

Toonijn
  • 394
  • 2
  • 10