summary refs log tree commit diff stats
path: root/tests/cpp/tasync_cpp.nim
diff options
context:
space:
mode:
authorEtan Kissling <etan@status.im>2021-10-22 17:32:02 +0200
committerGitHub <noreply@github.com>2021-10-22 17:32:02 +0200
commit490c4226a55e8abd7cb504d4e24fcb714bff23f1 (patch)
tree50f45d0b0a32dc4d308bc36f2aa0433014a37038 /tests/cpp/tasync_cpp.nim
parent4d8108046b71b6e40d88cde7496e687e68116877 (diff)
downloadNim-490c4226a55e8abd7cb504d4e24fcb714bff23f1.tar.gz
allow converting static vars to `openArray` (#19035)
When assigning constant output to a seq, and then passing that static
seq to other functions that take `openArray`, the compiler may end up
producing errors, as it does not know how to convert `static[seq[T]]`
to `openArray[T]`. By ignoring the `static` wrapper on the type for
the purpose of determining data memory location and length, this gets
resolved cleanly. Unfortunately, it is relatively tricky to come up
with a minimal example, as there are followup problems from the failing
conversion, e.g., this may lead to `internal error: inconsistent
environment type`, instead of the relevant `openArrayLoc` error message.
Diffstat (limited to 'tests/cpp/tasync_cpp.nim')
0 files changed, 0 insertions, 0 deletions