Skip to content
This repository was archived by the owner on Dec 20, 2023. It is now read-only.

Commit df7d18b

Browse files
committed
Incorporate code review feedback to use IgnoreUnusedVariable rather than an explicit cast.
1 parent f858bdf commit df7d18b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/test-apps/TestEventLogging.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2033,7 +2033,7 @@ static void CheckGapDetection(nlTestSuite *inSuite, void *inContext)
20332033
event_id_t eventId_A = nl::Weave::Profiles::DataManagement::LogEvent(testSchema, nl::SerializedDataToTLVWriterHelper, (void *)&appData);
20342034
event_id_t eventId_B = nl::Weave::Profiles::DataManagement::LogEvent(testSchema, nl::SerializedDataToTLVWriterHelper, (void *)&appData);
20352035

2036-
(void)eventId_B;
2036+
IgnoreUnusedVariable(eventId_B);
20372037

20382038
// Arrange testReader with all events from the start
20392039
err = FetchEventsHelper(testReader, eventId_A, backingStore, sizeof(backingStore));
@@ -2052,7 +2052,7 @@ static void CheckGapDetection(nlTestSuite *inSuite, void *inContext)
20522052
event_id_t eventId_C = nl::Weave::Profiles::DataManagement::LogEvent(testSchema, nl::SerializedDataToTLVWriterHelper, (void *)&appData);
20532053
event_id_t eventId_D = nl::Weave::Profiles::DataManagement::LogEvent(testSchema, nl::SerializedDataToTLVWriterHelper, (void *)&appData);
20542054

2055-
(void)eventId_C;
2055+
IgnoreUnusedVariable(eventId_C);
20562056

20572057
// Arrange testReader skipping eventId_C
20582058
err = FetchEventsHelper(testReader, eventId_D, backingStore, sizeof(backingStore));
@@ -2115,8 +2115,8 @@ static void CheckDropOverlap(nlTestSuite *inSuite, void *inContext)
21152115
event_id_t eventId_C = nl::Weave::Profiles::DataManagement::LogEvent(testSchema, nl::SerializedDataToTLVWriterHelper, (void *)&appData);
21162116
event_id_t eventId_D = nl::Weave::Profiles::DataManagement::LogEvent(testSchema, nl::SerializedDataToTLVWriterHelper, (void *)&appData);
21172117

2118-
(void)eventId_C;
2119-
(void)eventId_D;
2118+
IgnoreUnusedVariable(eventId_C);
2119+
IgnoreUnusedVariable(eventId_D);
21202120

21212121
// Arrange testReader overlapping eventId_B
21222122
err = FetchEventsHelper(testReader, eventId_B, backingStore, sizeof(backingStore));

0 commit comments

Comments
 (0)