Rollback a few recent Erlang changes to fix blame data
My combined patch for THRIFT-599 was committed, but it is preferable
commit the individual patches to preserve the more detailed log and
blame data. I'll recommit r987018 as a sequence of patches and r988722
as its own rev.
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@990957 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/test/erl/src/test_membuffer.erl b/test/erl/src/test_membuffer.erl
index 19ac527..7bd23a0 100644
--- a/test/erl/src/test_membuffer.erl
+++ b/test/erl/src/test_membuffer.erl
@@ -30,12 +30,12 @@
t1() ->
{ok, Transport} = thrift_memory_buffer:new(),
- {ok, Protocol0} = thrift_binary_protocol:new(Transport),
+ {ok, Protocol} = thrift_binary_protocol:new(Transport),
TestData = test_data(),
- {Protocol1, ok} = thrift_protocol:write(Protocol0,
+ ok = thrift_protocol:write(Protocol,
{{struct, element(2, thriftTest_types:struct_info('xtruct'))},
TestData}),
- {_Protocol2, {ok, Result}} = thrift_protocol:read(Protocol1,
+ {ok, Result} = thrift_protocol:read(Protocol,
{struct, element(2, thriftTest_types:struct_info('xtruct'))},
'xtruct'),
@@ -44,12 +44,12 @@
t2() ->
{ok, Transport} = thrift_memory_buffer:new(),
- {ok, Protocol0} = thrift_binary_protocol:new(Transport),
+ {ok, Protocol} = thrift_binary_protocol:new(Transport),
TestData = test_data(),
- {Protocol1, ok} = thrift_protocol:write(Protocol0,
+ ok = thrift_protocol:write(Protocol,
{{struct, element(2, thriftTest_types:struct_info('xtruct'))},
TestData}),
- {_Protocol2, {ok, Result}} = thrift_protocol:read(Protocol1,
+ {ok, Result} = thrift_protocol:read(Protocol,
{struct, element(2, thriftTest_types:struct_info('xtruct3'))},
'xtruct3'),
@@ -61,12 +61,12 @@
t3() ->
{ok, Transport} = thrift_memory_buffer:new(),
- {ok, Protocol0} = thrift_binary_protocol:new(Transport),
+ {ok, Protocol} = thrift_binary_protocol:new(Transport),
TestData = #bools{im_true = true, im_false = false},
- {Protocol1, ok} = thrift_protocol:write(Protocol0,
+ ok = thrift_protocol:write(Protocol,
{{struct, element(2, thriftTest_types:struct_info('bools'))},
TestData}),
- {_Protocol2, {ok, Result}} = thrift_protocol:read(Protocol1,
+ {ok, Result} = thrift_protocol:read(Protocol,
{struct, element(2, thriftTest_types:struct_info('bools'))},
'bools'),
@@ -74,23 +74,8 @@
true = TestData#bools.im_false =:= Result#bools.im_false.
-t4() ->
- {ok, Transport} = thrift_memory_buffer:new(),
- {ok, Protocol0} = thrift_binary_protocol:new(Transport),
- TestData = #insanity{xtructs=[]},
- {Protocol1, ok} = thrift_protocol:write(Protocol0,
- {{struct, element(2, thriftTest_types:struct_info('insanity'))},
- TestData}),
- {_Protocol2, {ok, Result}} = thrift_protocol:read(Protocol1,
- {struct, element(2, thriftTest_types:struct_info('insanity'))},
- 'insanity'),
-
- TestData = Result.
-
-
t() ->
t1(),
t2(),
- t3(),
- t4().
+ t3().