File tree 3 files changed +5
-6
lines changed
data-model-providers/codegen
3 files changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ class ServerClusterInterface
44
44
45
45
// /////////////////////////////////// Cluster Metadata Support //////////////////////////////////////////////////
46
46
47
- // / The path where this cluster operates on .
47
+ // / The path to this cluster instance .
48
48
// /
49
49
// / This path (endpointid,clusterid) is expected to be fixed once the server
50
50
// / cluster interface is in use.
Original file line number Diff line number Diff line change @@ -83,7 +83,7 @@ ServerClusterInterface * ServerClusterInterfaceRegistry::Unregister(const Concre
83
83
mCachedInterface = nullptr ;
84
84
}
85
85
86
- current->next = nullptr ; // some clearing
86
+ current->next = nullptr ; // Make sure current does not look like part of a list.
87
87
return current->serverClusterInterface ;
88
88
}
89
89
@@ -121,7 +121,7 @@ void ServerClusterInterfaceRegistry::UnregisterAllFromEndpoint(EndpointId endpoi
121
121
prev->next = current->next ;
122
122
}
123
123
ServerClusterRegistration * actual_next = current->next ;
124
- current->next = nullptr ; // some clearing
124
+ current->next = nullptr ; // Make sure current does not look like part of a list.
125
125
current = actual_next;
126
126
}
127
127
else
Original file line number Diff line number Diff line change @@ -31,14 +31,13 @@ namespace app {
31
31
struct ServerClusterRegistration
32
32
{
33
33
// A single-linked list of clusters registered for the given `endpointId`
34
- ServerClusterInterface * serverClusterInterface;
34
+ ServerClusterInterface * const serverClusterInterface;
35
35
ServerClusterRegistration * next;
36
36
37
37
constexpr ServerClusterRegistration (ServerClusterInterface &interface, ServerClusterRegistration * next_item = nullptr ) :
38
38
serverClusterInterface(&interface), next(next_item)
39
39
{}
40
40
ServerClusterRegistration (ServerClusterRegistration &&other) = default ;
41
- ServerClusterRegistration& operator =(ServerClusterRegistration &&other) = default ;
42
41
43
42
// we generally do not want to allow copies as those may have different "next" entries.
44
43
ServerClusterRegistration (const ServerClusterRegistration &other) = delete ;
@@ -118,7 +117,7 @@ class ServerClusterInterfaceRegistry
118
117
119
118
// / Provides a list of clusters that are registered for the given endpoint.
120
119
// /
121
- // / As ClustersList points inside the internal registrations of the registry,
120
+ // / ClustersList points inside the internal registrations of the registry, so
122
121
// / the list is only valid as long as the registry is not modified.
123
122
ClustersList ClustersOnEndpoint (EndpointId endpointId);
124
123
You can’t perform that action at this time.
0 commit comments