Thrift compiler improvements, two modes for PHP
Summary: Complete PHP generator and CPP generator to new formats, and offer PHP generator that generates inline code free of any TProtocol abstraction
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@664771 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/compiler/cpp/src/parse/t_function.h b/compiler/cpp/src/parse/t_function.h
index 9e6c56a..58667d8 100644
--- a/compiler/cpp/src/parse/t_function.h
+++ b/compiler/cpp/src/parse/t_function.h
@@ -20,6 +20,20 @@
returntype_(returntype),
name_(name),
arglist_(arglist),
+ async_(async) {
+ xceptions_ = new t_struct;
+ }
+
+
+ t_function(t_type* returntype,
+ std::string name,
+ t_struct* arglist,
+ t_struct* xceptions,
+ bool async=false) :
+ returntype_(returntype),
+ name_(name),
+ arglist_(arglist),
+ xceptions_(xceptions),
async_(async) {}
~t_function() {}
@@ -27,12 +41,14 @@
t_type* get_returntype() const { return returntype_; }
const std::string& get_name() const { return name_; }
t_struct* get_arglist() const { return arglist_; }
+ t_struct* get_xceptions() const { return xceptions_; }
bool is_async() const { return async_; }
private:
t_type* returntype_;
std::string name_;
t_struct* arglist_;
+ t_struct* xceptions_;
bool async_;
};