Skip to content

Commit 4130f38

Browse files
Tradiascopybara-github
authored andcommitted
Remove unused references to internal::DownCast (#19372)
Closes #19372 COPYBARA_INTEGRATE_REVIEW=#19372 from Tradias:remove-downcast f126025 PiperOrigin-RevId: 700363447
1 parent 70730f5 commit 4130f38

File tree

4 files changed

+0
-8
lines changed

4 files changed

+0
-8
lines changed

src/google/protobuf/extension_set_unittest.cc

-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ extern bool fully_verify_message_sets_opt_out;
5252

5353
namespace {
5454

55-
using ::google::protobuf::internal::DownCast;
5655
using TestUtil::EqualsToSerialized;
5756

5857
// This test closely mirrors google/protobuf/compiler/cpp/unittest.cc

src/google/protobuf/map_test.inc

-1
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,6 @@ struct MapTestPeer {
217217
};
218218

219219
namespace {
220-
using internal::DownCast;
221220

222221
// Map API Test =====================================================
223222

src/google/protobuf/message_lite.h

-5
Original file line numberDiff line numberDiff line change
@@ -1200,11 +1200,6 @@ T* OnShutdownDelete(T* p) {
12001200
return p;
12011201
}
12021202

1203-
inline void AssertDownCast(const MessageLite& from, const MessageLite& to) {
1204-
ABSL_DCHECK(TypeId::Get(from) == TypeId::Get(to))
1205-
<< "Cannot downcast " << from.GetTypeName() << " to " << to.GetTypeName();
1206-
}
1207-
12081203
template <bool test_call, typename MessageLite>
12091204
PROTOBUF_ALWAYS_INLINE MessageLite* MessageCreator::PlacementNew(
12101205
const MessageLite* prototype_for_func,

src/google/protobuf/repeated_field_reflection_unittest.inc

-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ namespace protobuf {
2222
namespace {
2323

2424

25-
using internal::DownCast;
2625
using UNITTEST::ForeignMessage;
2726
using UNITTEST::TestAllExtensions;
2827
using UNITTEST::TestAllTypes;

0 commit comments

Comments
 (0)