[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Getfem-commits] (no subject)
From: |
Liang Jin Lim |
Subject: |
[Getfem-commits] (no subject) |
Date: |
Tue, 10 Jul 2018 08:03:18 -0400 (EDT) |
branch: race_condition_in_ga_define_function
commit 6e56db8d83edea1b8dc02dd42b52b9c140f8b369
Author: lj <address@hidden>
Date: Tue Jul 10 14:02:51 2018 +0200
Have to explicitly cast to tuple as compiler gives error.
---
src/getfem/getfem_generic_assembly_compile_and_exec.h | 17 ++++++++---------
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/src/getfem/getfem_generic_assembly_compile_and_exec.h
b/src/getfem/getfem_generic_assembly_compile_and_exec.h
index a9eb562..6da88d8 100644
--- a/src/getfem/getfem_generic_assembly_compile_and_exec.h
+++ b/src/getfem/getfem_generic_assembly_compile_and_exec.h
@@ -99,15 +99,14 @@ namespace getfem {
fem_precomp_pool fp_pool;
std::map<gauss_pt_corresp, bgeot::pstored_point_tab> neighbour_corresp;
- struct region_mim
- : std::tuple<const mesh_im *, const mesh_region *, psecondary_domain> {
- const mesh_im* mim() const { return std::get<0>(*this); }
- const mesh_region* region() const { return std::get<1>(*this); }
- psecondary_domain psd() const { return std::get<2>(*this); }
- region_mim(const mesh_im *mim_, const mesh_region *region_,
- psecondary_domain psd) :
- std::tuple<const mesh_im *, const mesh_region *, psecondary_domain>
- (mim_, region_, psd) {}
+ using region_mim_tuple = std::tuple<const mesh_im *, const mesh_region *,
psecondary_domain>;
+ struct region_mim : public region_mim_tuple {
+ const mesh_im* mim() const {return
std::get<0>(static_cast<region_mim_tuple>(*this));}
+ const mesh_region* region() const {return
std::get<1>(static_cast<region_mim_tuple>(*this));}
+ psecondary_domain psd() const {return
std::get<2>(static_cast<region_mim_tuple>(*this));}
+
+ region_mim(const mesh_im *mim_, const mesh_region *region_,
psecondary_domain psd)
+ : region_mim_tuple(mim_, region_, psd) {}
};
std::map<std::string, const base_vector *> extended_vars;