Skip to content
Snippets Groups Projects
Commit 782724ba authored by Stanley Cheung's avatar Stanley Cheung Committed by GitHub
Browse files

Merge pull request #9321 from stanley-cheung/fix-various-php-bugs

Fix various php bugs
parents 5868c833 50c87808
No related branches found
No related tags found
No related merge requests found
...@@ -39,10 +39,13 @@ protoc --proto_path=src/proto/math \ ...@@ -39,10 +39,13 @@ protoc --proto_path=src/proto/math \
# replace the Empty message with EmptyMessage # replace the Empty message with EmptyMessage
# because Empty is a PHP reserved word # because Empty is a PHP reserved word
sed -i 's/message Empty/message EmptyMessage/g' \ output_file=$(mktemp)
src/proto/grpc/testing/empty.proto sed 's/message Empty/message EmptyMessage/g' \
sed -i 's/grpc\.testing\.Empty/grpc\.testing\.EmptyMessage/g' \ src/proto/grpc/testing/empty.proto > $output_file
src/proto/grpc/testing/test.proto mv $output_file ./src/proto/grpc/testing/empty.proto
sed 's/grpc\.testing\.Empty/grpc\.testing\.EmptyMessage/g' \
src/proto/grpc/testing/test.proto > $output_file
mv $output_file ./src/proto/grpc/testing/test.proto
protoc --proto_path=. \ protoc --proto_path=. \
--php_out=src/php/tests/interop \ --php_out=src/php/tests/interop \
...@@ -53,7 +56,10 @@ protoc --proto_path=. \ ...@@ -53,7 +56,10 @@ protoc --proto_path=. \
src/proto/grpc/testing/test.proto src/proto/grpc/testing/test.proto
# change it back # change it back
sed -i 's/message EmptyMessage/message Empty/g' \ sed 's/message EmptyMessage/message Empty/g' \
src/proto/grpc/testing/empty.proto src/proto/grpc/testing/empty.proto > $output_file
sed -i 's/grpc\.testing\.EmptyMessage/grpc\.testing\.Empty/g' \ mv $output_file ./src/proto/grpc/testing/empty.proto
src/proto/grpc/testing/test.proto sed 's/grpc\.testing\.EmptyMessage/grpc\.testing\.Empty/g' \
src/proto/grpc/testing/test.proto > $output_file
mv $output_file ./src/proto/grpc/testing/test.proto
...@@ -271,7 +271,7 @@ class BaseStub ...@@ -271,7 +271,7 @@ class BaseStub
* @return ClientStreamingSurfaceActiveCall The active call object * @return ClientStreamingSurfaceActiveCall The active call object
*/ */
public function _clientStreamRequest($method, public function _clientStreamRequest($method,
callable $deserialize, $deserialize,
array $metadata = [], array $metadata = [],
array $options = []) array $options = [])
{ {
...@@ -307,7 +307,7 @@ class BaseStub ...@@ -307,7 +307,7 @@ class BaseStub
*/ */
public function _serverStreamRequest($method, public function _serverStreamRequest($method,
$argument, $argument,
callable $deserialize, $deserialize,
array $metadata = [], array $metadata = [],
array $options = []) array $options = [])
{ {
...@@ -340,7 +340,7 @@ class BaseStub ...@@ -340,7 +340,7 @@ class BaseStub
* @return BidiStreamingSurfaceActiveCall The active call object * @return BidiStreamingSurfaceActiveCall The active call object
*/ */
public function _bidiRequest($method, public function _bidiRequest($method,
callable $deserialize, $deserialize,
array $metadata = [], array $metadata = [],
array $options = []) array $options = [])
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment