From a9bcc33c7e1a83b280fd335f2b9779d00c1005cd Mon Sep 17 00:00:00 2001 From: Olivier Parcollet Date: Sun, 11 May 2014 21:54:46 +0200 Subject: [PATCH] minor correction for linux - vector on C++14 has explicit default (until C++14 apparently) it is a small difference between libc++ and gnu libstdC++ --- pytriqs/gf/local/gf_desc.py | 3 +-- triqs/gfs/tools.hpp | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/pytriqs/gf/local/gf_desc.py b/pytriqs/gf/local/gf_desc.py index 05308847..bd470597 100644 --- a/pytriqs/gf/local/gf_desc.py +++ b/pytriqs/gf/local/gf_desc.py @@ -202,8 +202,7 @@ def make_gf( py_type, c_tag, is_complex_data = True, is_im = False) : arithmetic = ("algebra",data_type) ) - g.add_constructor(signature = "(gf_mesh<%s> mesh, mini_vector shape, std::vector> indices = {}, std::string name = "")"%c_tag, - python_precall = "pytriqs.gf.local._gf_%s.init"%c_tag) + g.add_constructor(signature = "(gf_mesh<%s> mesh, mini_vector shape, std::vector> indices = std::vector>{}, std::string name = "")"%c_tag, python_precall = "pytriqs.gf.local._gf_%s.init"%c_tag) g.add_method_copy() g.add_method_copy_from() diff --git a/triqs/gfs/tools.hpp b/triqs/gfs/tools.hpp index 9a0276b9..cb583954 100644 --- a/triqs/gfs/tools.hpp +++ b/triqs/gfs/tools.hpp @@ -94,7 +94,7 @@ namespace gfs { std::vector operator[](int i) const { if (is_empty()) - return {}; + return std::vector {}; else return ind[i]; }