Thrift: docstring revamp step 1.
Summary:
Allow constants to be documented.
Now any "Definition" can be documented, so we can move the docstring stuff
up to a a higher node in the parse tree.
Reviewed By: mcslee
Test Plan:
Recompiled thrift.
Checked out DocTest.thrift and a few other thrifts.
Revert Plan: ok
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665200 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/test/DocTest.thrift b/test/DocTest.thrift
index 361bdde..e202b0e 100755
--- a/test/DocTest.thrift
+++ b/test/DocTest.thrift
@@ -45,6 +45,14 @@
11: i64 i64_thing
}
+/**
+ * You can document constants now too. Yeehaw!
+ */
+const i32 INT32CONSTANT = 9853
+const i16 INT16CONSTANT = 1616
+/** Everyone get in on the docu-action! */
+const map<string,string> MAPCONSTANT = {'hello':'world', 'goodnight':'moon'}
+
struct Xtruct2
{
1: byte byte_thing,