<p><a href="https://gerrit.osmocom.org/c/libosmocore/+/18540">View Change</a></p><p>4 comments:</p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0;"><p><a href="https://gerrit.osmocom.org/c/libosmocore/+/18540/1/include/osmocom/gsm/gsm23236.h">File include/osmocom/gsm/gsm23236.h:</a></p><ul style="list-style: none; padding: 0;"><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/libosmocore/+/18540/1/include/osmocom/gsm/gsm23236.h@28">Patch Set #1, Line 28:</a> <code style="font-family:monospace,monospace">struct llist_head *nri_ranges</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">can probably be 'const' as the nri_ranges list is iterated only for reading?</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/libosmocore/+/18540/1/include/osmocom/gsm/gsm23236.h@29">Patch Set #1, Line 29:</a> <code style="font-family:monospace,monospace">struct llist_head *nri_ranges</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">same here, shouldn't it also be const?</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/libosmocore/+/18540/1/include/osmocom/gsm/gsm23236.h@30">Patch Set #1, Line 30:</a> <code style="font-family:monospace,monospace">(void *ctx, struct llist_head *nri_range</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">one *could* (not saying you must if you don't like it) create a 'osmo_nri_range_list' or 'osmo_nri_ranges' struct which stores the master llist_head, the nri_bitlen and which also serves as talloc context for any osmo_nri_range allocations.   This way the function signatures (and hence usage) would be simplified without having to manually specify ctx and/or nri_bitlen.  If the osmo_nri_range had a back-pointer to the ramnge_list/ranges "parent", then even functions only receiving a single osmo_nri_range as argument can get to the nri_Bitlen.</p></li><li style="margin: 0; padding: 0 0 0 16px;"><p style="margin-bottom: 4px;"><a href="https://gerrit.osmocom.org/c/libosmocore/+/18540/1/include/osmocom/gsm/gsm23236.h@42">Patch Set #1, Line 42:</a> <code style="font-family:monospace,monospace">struct</code></p><p style="white-space: pre-wrap; word-wrap: break-word;">const again?</p></li></ul></li></ul><p>To view, visit <a href="https://gerrit.osmocom.org/c/libosmocore/+/18540">change 18540</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/libosmocore/+/18540"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: libosmocore </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I68e4156824032772f460042499bbc693380186dc </div>
<div style="display:none"> Gerrit-Change-Number: 18540 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: neels <nhofmeyr@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-CC: laforge <laforge@osmocom.org> </div>
<div style="display:none"> Gerrit-Comment-Date: Thu, 28 May 2020 09:08:42 +0000 </div>
<div style="display:none"> Gerrit-HasComments: Yes </div>
<div style="display:none"> Gerrit-Has-Labels: No </div>
<div style="display:none"> Gerrit-MessageType: comment </div>