mirror of
https://github.com/status-im/realm-js.git
synced 2025-01-11 23:04:29 +00:00
Fix some typos in comments
This commit is contained in:
parent
b42bf25c99
commit
2bcf42904a
@ -34,7 +34,7 @@ NotificationToken::~NotificationToken()
|
||||
// atomically to ensure that there are no data races when the token is
|
||||
// destroyed after being modified on a different thread.
|
||||
// This is needed despite the token not being thread-safe in general as
|
||||
// users find it very surpringing for obj-c objects to care about what
|
||||
// users find it very surprising for obj-c objects to care about what
|
||||
// thread they are deallocated on.
|
||||
if (auto notifier = m_notifier.exchange({})) {
|
||||
notifier->remove_callback(m_token);
|
||||
|
@ -581,8 +581,8 @@ CollectionChangeBuilder CollectionChangeBuilder::calculate(std::vector<size_t> c
|
||||
});
|
||||
|
||||
// Don't add rows which were modified to not match the query to `deletions`
|
||||
// immediately because the unsorted move logic needs to be able to distinuish
|
||||
// them from rows which were outright deleted
|
||||
// immediately because the unsorted move logic needs to be able to
|
||||
// distinguish them from rows which were outright deleted
|
||||
IndexSet removed;
|
||||
|
||||
// Now that our old and new sets of rows are sorted by row index, we can
|
||||
|
@ -288,8 +288,9 @@ bool CollectionNotifier::deliver(Realm& realm, SharedGroup& sg, std::exception_p
|
||||
bool should_call_callbacks = do_deliver(sg);
|
||||
m_changes_to_deliver = std::move(m_accumulated_changes);
|
||||
|
||||
// FIXME: ugh
|
||||
// fixup modifications to be source rows rather than dest rows
|
||||
// FIXME: the actual change calculations should be updated to just calculate
|
||||
// the correct thing instead
|
||||
m_changes_to_deliver.modifications.erase_at(m_changes_to_deliver.insertions);
|
||||
m_changes_to_deliver.modifications.shift_for_insert_at(m_changes_to_deliver.deletions);
|
||||
|
||||
|
@ -385,7 +385,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
// Copy the list change info if there's multiple LinkViews for the same LinkList
|
||||
// Copy the list change info if there are multiple LinkViews for the same LinkList
|
||||
auto id = [](auto const& list) { return std::tie(list.table_ndx, list.col_ndx, list.row_ndx); };
|
||||
for (size_t i = 1; i < m_current->lists.size(); ++i) {
|
||||
for (size_t j = i; j > 0; --j) {
|
||||
|
@ -335,7 +335,7 @@ public:
|
||||
}
|
||||
else {
|
||||
// Array KVO can only send a single kind of change at a time, so
|
||||
// if there's multiple just give up and send "Set"
|
||||
// if there are multiple just give up and send "Set"
|
||||
o->indices.set(0);
|
||||
o->kind = ColumnInfo::Kind::SetAll;
|
||||
}
|
||||
|
@ -189,7 +189,7 @@ public:
|
||||
// Remove all indexes from the set
|
||||
void clear();
|
||||
|
||||
// An iterator over the indivual indices in the set rather than the ranges
|
||||
// An iterator over the individual indices in the set rather than the ranges
|
||||
class IndexIterator : public std::iterator<std::forward_iterator_tag, size_t> {
|
||||
public:
|
||||
IndexIterator(IndexSet::const_iterator it) : m_iterator(it) { }
|
||||
|
@ -63,7 +63,7 @@ namespace realm {
|
||||
bool in_memory = false;
|
||||
|
||||
// The following are intended for internal/testing purposes and
|
||||
// should not be publically exposed in binding APIs
|
||||
// should not be publicly exposed in binding APIs
|
||||
|
||||
// If false, always return a new Realm instance, and don't return
|
||||
// that Realm instance for other requests for a cached Realm. Useful
|
||||
|
Loading…
x
Reference in New Issue
Block a user