thrift/lib/cpp/test
Jake Farrell f9f01fa1e0 THRIFT-1394:Treatment of optional fields is not consistent between C++ and Java
Client: cpp
Patch: Diwaker Gupta

In CPP, all optional fields are guarded by the isset helper struct. On Java, however, the generated code takes advantage of nullable types: for containers, structs, exceptions, enums, and, notably, strings, the generator elides explicit use of an "isset" bit vector and instead emits checks of the form "field null". This leads to varying behavior between the two languages: an optional string field with a default value will have {{isset[fieldid]}} false on C, but the equivalent test in Java will be true.



git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1236529 13f79535-47bb-0310-9956-ffa450edef68
2012-01-27 04:48:26 +00:00
..
AllProtocolTests.cpp THRIFT-916 compile with -Wall -Wextra without warning on Debian Lenny 2010-11-17 22:11:26 +00:00
AllProtocolTests.tcc THRIFT-503. cpp: Move the tests built by "make check" under lib/cpp 2010-08-31 16:51:19 +00:00
Benchmark.cpp THRIFT-1459 declare shared_ptr as boost::shared_ptr 2011-12-11 22:08:51 +00:00
DebugProtoTest_extras.cpp THRIFT-916 compile with -Wall -Wextra without warning on Debian Lenny 2010-11-17 22:11:26 +00:00
DebugProtoTest.cpp THRIFT-916: Commit THRIFT-916_fix_no-overflow.patch -- remove overflow coming from a few constants. 2010-11-28 14:34:26 +00:00
DenseProtoTest.cpp THRIFT-503. cpp: Move the tests built by "make check" under lib/cpp 2010-08-31 16:51:19 +00:00
GenericHelpers.h THRIFT-503. cpp: Move the tests built by "make check" under lib/cpp 2010-08-31 16:51:19 +00:00
JSONProtoTest.cpp THRIFT-916: Commit THRIFT-916_fix_no-overflow.patch -- remove overflow coming from a few constants. 2010-11-28 14:34:26 +00:00
Makefile.am THRIFT-1461 Recent TNonblockingServer changes broke --enable-boostthreads=yes, Windows 2011-12-14 23:35:28 +00:00
OptionalRequiredTest.cpp THRIFT-1394:Treatment of optional fields is not consistent between C++ and Java 2012-01-27 04:48:26 +00:00
RWMutexStarveTest.cpp THRIFT-1459 declare shared_ptr as boost::shared_ptr 2011-12-11 22:08:51 +00:00
SpecializationTest.cpp THRIFT-916: Commit THRIFT-916_fix_no-overflow.patch -- remove overflow coming from a few constants. 2010-11-28 14:34:26 +00:00
TBufferBaseTest.cpp THRIFT-916: Fix warnings in C++ when compiling with -Wall. 2010-11-04 20:35:15 +00:00
TFDTransportTest.cpp THRIFT-503. cpp: Move the tests built by "make check" under lib/cpp 2010-08-31 16:51:19 +00:00
TFileTransportTest.cpp THRIFT-1320 Consistency of configure generated config.h 2011-09-05 19:15:53 +00:00
ThriftTest_extras.cpp THRIFT-503. cpp: Move the tests built by "make check" under lib/cpp 2010-08-31 16:51:19 +00:00
TMemoryBufferTest.cpp THRIFT-916 no errors on GNU/Linux when compiling with CXXFLAGS="-Wall -Wextra -pedantic" 2010-10-13 18:10:18 +00:00
TPipedTransportTest.cpp THRIFT-1459 declare shared_ptr as boost::shared_ptr 2011-12-11 22:08:51 +00:00
TransportTest.cpp THRIFT-1361 revert compiler/cpp/src/thrifty.yy change 2011-11-06 12:04:28 +00:00
UnitTestMain.cpp THRIFT-953: Fix compilation of TransportTest.cpp on Mac (actual tests still fail) and fix boost m4 macros for Mac. 2010-11-04 18:51:42 +00:00
ZlibTest.cpp THRIFT-1459 declare shared_ptr as boost::shared_ptr 2011-12-11 22:08:51 +00:00