This is an automated email from the ASF dual-hosted git repository.

jking pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/thrift.git


The following commit(s) were added to refs/heads/master by this push:
     new 74d6d9d  Initialisation of immutable data in static constructors has 
been deprecated.  They now need to be initialised in shared static constructors.
74d6d9d is described below

commit 74d6d9d3d6400d1672f48b4acf5bc7d1260ad96d
Author: Laeeth Isharc <lae...@kaleidic.io>
AuthorDate: Mon Aug 5 13:23:29 2019 +0100

    Initialisation of immutable data in static constructors has been
    deprecated.  They now need to be initialised in shared static
    constructors.
    
    This change brings the generator for D up to date with the latest
    version of the compiler, but it should continue to work with older
    versions.
---
 compiler/cpp/src/thrift/generate/t_d_generator.cc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/compiler/cpp/src/thrift/generate/t_d_generator.cc 
b/compiler/cpp/src/thrift/generate/t_d_generator.cc
index b844204..65f4b44 100644
--- a/compiler/cpp/src/thrift/generate/t_d_generator.cc
+++ b/compiler/cpp/src/thrift/generate/t_d_generator.cc
@@ -145,7 +145,7 @@ protected:
         indent(f_consts) << "immutable(" << render_type_name(type) << ") " << 
name << ";" << endl;
       }
 
-      f_consts << endl << "static this() {" << endl;
+      f_consts << endl << "shared static this() {" << endl;
       indent_up();
 
       bool first = true;

Reply via email to