diff options
author | bptato <nincsnevem662@gmail.com> | 2023-09-15 11:52:26 +0200 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2023-09-15 11:52:26 +0200 |
commit | 73c9788a7bd64a7f74d9e40b8ab5963817dad59e (patch) | |
tree | e9cc21dcda6bcd5c3471602fcec634299856d970 /src/utils | |
parent | 2cf74b74d1c57940037d23c4a7b44ba2afd38725 (diff) | |
download | chawan-73c9788a7bd64a7f74d9e40b8ab5963817dad59e.tar.gz |
Fix compilation with --assertions:off
Remove side effects from assert statements. The flag is not used currently, but let's not depend on that.
Diffstat (limited to 'src/utils')
-rw-r--r-- | src/utils/twtstr.nim | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/utils/twtstr.nim b/src/utils/twtstr.nim index 33806ba3..257bdc66 100644 --- a/src/utils/twtstr.nim +++ b/src/utils/twtstr.nim @@ -633,7 +633,8 @@ func processIdna(str: string, checkhyphens, checkbidi, checkjoiners, transitiona var cr: CharRange {.cast(noSideEffect).}: cr_init(addr cr, nil, passRealloc) - assert unicode_general_category(addr cr, "Mark") == 0 + let r = unicode_general_category(addr cr, "Mark") + assert r == 0 var labels: seq[string] for label in ($mapped).split('.'): if label.startsWith("xn--"): |