<p style="white-space: pre-wrap; word-wrap: break-word;">I don't like such kind of functions doing simple things like:</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">  return foo == "bar";</pre><p style="white-space: pre-wrap; word-wrap: break-word;">Probably you win shorter line length:</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">  if (Misc_Helpers.mp_osmocom_stack_version == "nightly") { ... }</pre><p style="white-space: pre-wrap; word-wrap: break-word;">vs</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">  if (f_is_osmocom_nightly()) { ... }</pre><p style="white-space: pre-wrap; word-wrap: break-word;">but still I would go for something more generic, like having an enumerated type:</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">  type enumerated OsmoSUTVer {<br>    OSMO_SUT_VER_NIGHTLY,<br>    OSMO_SUT_VER_LATEST,<br>    OSMO_SUT_VER_2021Q4<br>  };</pre><p style="white-space: pre-wrap; word-wrap: break-word;">and then a single function:</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">  function f_osmo_sut_ver_is(template OsmoSUTVer ver)<br>  return boolean {<br>    return match(mp_osmocom_stack_version, ver);<br>  }</pre><p style="white-space: pre-wrap; word-wrap: break-word;">This approach is cleaner IMO, and allows to match several variants at a time:</p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">  if (f_osmo_sut_ver_is((OSMO_SUT_VER_LATEST, OSMO_SUT_VER_2021Q4))) { ... }</pre><p>Patch set 1:<span style="border-radius: 3px; display: inline-block; margin: 0 2px; padding: 4px;background-color: #ffd4d4;">Code-Review -1</span></p><p><a href="https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/26386">View Change</a></p><ul style="list-style: none; padding: 0;"></ul><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/26386">change 26386</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/osmo-ttcn3-hacks/+/26386"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-ttcn3-hacks </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: Ic33d08992ea84af006d133db6aec508a7b7c7f28 </div>
<div style="display:none"> Gerrit-Change-Number: 26386 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: osmith <osmith@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: Jenkins Builder </div>
<div style="display:none"> Gerrit-Reviewer: dexter <pmaier@sysmocom.de> </div>
<div style="display:none"> Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de> </div>
<div style="display:none"> Gerrit-CC: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-Comment-Date: Fri, 26 Nov 2021 15:13:12 +0000 </div>
<div style="display:none"> Gerrit-HasComments: No </div>
<div style="display:none"> Gerrit-Has-Labels: Yes </div>
<div style="display:none"> Gerrit-MessageType: comment </div>