diff --git a/src/cc/api/BPFTable.cc b/src/cc/api/BPFTable.cc
index c6d7928..33803ad 100644
--- a/src/cc/api/BPFTable.cc
+++ b/src/cc/api/BPFTable.cc
@@ -191,6 +191,9 @@
                              bool use_debug_file,
                              bool check_debug_file_crc)
     : BPFTableBase<int, stacktrace_t>(desc) {
+  if (desc.type != BPF_MAP_TYPE_STACK_TRACE)
+    throw std::invalid_argument("Table '" + desc.name + "' is not a stack table");
+
   symbol_option_ = {
     .use_debug_file = use_debug_file,
     .check_debug_file_crc = check_debug_file_crc,
@@ -254,6 +257,12 @@
   return res;
 }
 
+BPFPerfBuffer::BPFPerfBuffer(const TableDesc& desc)
+  : BPFTableBase<int, int>(desc), epfd_(-1) {
+  if (desc.type != BPF_MAP_TYPE_PERF_EVENT_ARRAY)
+    throw std::invalid_argument("Table '" + desc.name + "' is not a perf buffer");
+}
+
 StatusTuple BPFPerfBuffer::open_on_cpu(perf_reader_raw_cb cb,
                                        perf_reader_lost_cb lost_cb, int cpu,
                                        void* cb_cookie, int page_cnt) {
@@ -363,6 +372,12 @@
               << std::endl;
 }
 
+BPFPerfEventArray::BPFPerfEventArray(const TableDesc& desc)
+  : BPFTableBase<int, int>(desc) {
+  if (desc.type != BPF_MAP_TYPE_PERF_EVENT_ARRAY)
+    throw std::invalid_argument("Table '" + desc.name + "' is not a perf event array");
+}
+
 StatusTuple BPFPerfEventArray::open_all_cpu(uint32_t type, uint64_t config) {
   if (cpu_fds_.size() != 0)
     return StatusTuple(-1, "Previously opened perf event not cleaned");
@@ -436,6 +451,12 @@
   }
 }
 
+BPFProgTable::BPFProgTable(const TableDesc& desc)
+  : BPFTableBase<int, int>(desc) {
+  if (desc.type != BPF_MAP_TYPE_PROG_ARRAY)
+    throw std::invalid_argument("Table '" + desc.name + "' is not a prog table");
+}
+
 StatusTuple BPFProgTable::update_value(const int& index, const int& prog_fd) {
   if (!this->update(const_cast<int*>(&index), const_cast<int*>(&prog_fd)))
     return StatusTuple(-1, "Error updating value: %s", std::strerror(errno));
@@ -448,6 +469,12 @@
   return StatusTuple(0);
 }
 
+BPFCgroupArray::BPFCgroupArray(const TableDesc& desc)
+  : BPFTableBase<int, int>(desc) {
+  if (desc.type != BPF_MAP_TYPE_CGROUP_ARRAY)
+    throw std::invalid_argument("Table '" + desc.name + "' is not a cgroup array");
+}
+
 StatusTuple BPFCgroupArray::update_value(const int& index,
                                          const int& cgroup2_fd) {
   if (!this->update(const_cast<int*>(&index), const_cast<int*>(&cgroup2_fd)))
diff --git a/src/cc/api/BPFTable.h b/src/cc/api/BPFTable.h
index 2ec3210..6eb1bd7 100644
--- a/src/cc/api/BPFTable.h
+++ b/src/cc/api/BPFTable.h
@@ -299,8 +299,7 @@
 
 class BPFPerfBuffer : public BPFTableBase<int, int> {
  public:
-  BPFPerfBuffer(const TableDesc& desc)
-      : BPFTableBase<int, int>(desc), epfd_(-1) {}
+  BPFPerfBuffer(const TableDesc& desc);
   ~BPFPerfBuffer();
 
   StatusTuple open_all_cpu(perf_reader_raw_cb cb, perf_reader_lost_cb lost_cb,
@@ -321,8 +320,7 @@
 
 class BPFPerfEventArray : public BPFTableBase<int, int> {
  public:
-  BPFPerfEventArray(const TableDesc& desc)
-      : BPFTableBase<int, int>(desc) {}
+  BPFPerfEventArray(const TableDesc& desc);
   ~BPFPerfEventArray();
 
   StatusTuple open_all_cpu(uint32_t type, uint64_t config);
@@ -337,11 +335,7 @@
 
 class BPFProgTable : public BPFTableBase<int, int> {
 public:
-  BPFProgTable(const TableDesc& desc)
-      : BPFTableBase<int, int>(desc) {
-    if (desc.type != BPF_MAP_TYPE_PROG_ARRAY)
-      throw std::invalid_argument("Table '" + desc.name + "' is not a prog table");
-  }
+  BPFProgTable(const TableDesc& desc);
 
   StatusTuple update_value(const int& index, const int& prog_fd);
   StatusTuple remove_value(const int& index);
@@ -349,11 +343,7 @@
 
 class BPFCgroupArray : public BPFTableBase<int, int> {
 public:
-  BPFCgroupArray(const TableDesc& desc)
-      : BPFTableBase<int, int>(desc) {
-    if (desc.type != BPF_MAP_TYPE_CGROUP_ARRAY)
-      throw std::invalid_argument("Table '" + desc.name + "' is not a cgroup array");
-  }
+  BPFCgroupArray(const TableDesc& desc);
 
   StatusTuple update_value(const int& index, const int& cgroup2_fd);
   StatusTuple update_value(const int& index, const std::string& cgroup2_path);
