Type mistmatch for `int` and `sink T`

2022-12-29 Thread shirleyquirk
You are trying to insert an `int` into a seq of `byte`

Roadmap 2023

2022-12-29 Thread jasonfi
I read that the higher-level async modules will be moved out of core, not async itself.

Roadmap 2023

2022-12-29 Thread elcritch
> I applaud removing async and spawn from the stdlib, that's a bold move for a > 'batteries-included' language but it's a credit to the language that such a > thing is possible, and to the ecosystem that we have several robust and > mature replacements. I'm glad the selectors.nim would remain t

Extracting multiple base types on FFI

2022-12-29 Thread sls1005
No, it's the 1st generic type argument of the 2nd argument, not the 2nd generic type argument of the 1st argument.

Is flags={SocketFlag.Peek} buggy or am I missing something ?

2022-12-29 Thread void09
I have this code with asyncSocket on linux: while true: var msgSize = "" while msgSize.len == 0: try: msgSize = await asocket.recv(4, flags={SocketFlag.Peek}) await sleepAsync(200) except ... try: resp = await a

Show Nim: Mummy, a new HTTP + WebSocket server that returns to the ancient ways of threads

2022-12-29 Thread guzba
Thanks for trying out Mummy. I have a theory on the issue you're facing. By default Mummy only listens on "localhost" meaning the port is not externally accessible. This is an important default for security reasons, however for a public web server this is a no-go. To address this you'll want to

Type mistmatch for `int` and `sink T`

2022-12-29 Thread Nlits
I have this code: proc encode*(s: openArray[int], lo: var int): seq[byte] = var mlength = findMaxLen(s, true) mlength = mlength.binLen + 1 var cache = "" for i in s: cache &= toBin(i, mlength) lo = mlength

Downloading files with missing protocol in redirect url

2022-12-29 Thread Araq
Patch httpclient please and create a PR.

Roadmap 2023

2022-12-29 Thread Hlaaftana
For the record about "working" callOperator all bugs related to callOperator were fixed recently

Roadmap 2023

2022-12-29 Thread shirleyquirk
Brilliant! IC plus useable nimsuggest would be such a huge step forward. I applaud removing async and spawn from the stdlib, that's a bold move for a 'batteries-included' language but it's a credit to the language that such a thing is possible, and to the ecosystem that we have several robust an

Downloading files with missing protocol in redirect url

2022-12-29 Thread yister
I'm trying to download a file ( ) using httpclient, and it looks like the download is redirected twice, the first one being: //api.anaconda.org/download/conda-forge/micromamba/1.1.0/linux-64/micromamba-1.1.0-0.tar.bz2

Roadmap 2023

2022-12-29 Thread Araq
See here: There is one more RFC in the works dealing with the eternal question of our time: What is an exception?

Splat operator implementation with macros

2022-12-29 Thread SolitudeSF
nsfw macro activity

Extracting multiple base types on FFI

2022-12-29 Thread Araq
Not sure, via `'*2`?

Extracting multiple base types on FFI

2022-12-29 Thread sls1005
In a format string for `{.importcpp.}`, `'1` is the type of the 1st argument, `'*1` is the 1st base type of the 1st argument, then how to get the 2nd base type of the 1st argument (e.g. `B` from `Table[A, B]`) ?

Splat operator implementation with macros

2022-12-29 Thread yglukhov
Finally got around to test my idea above and here's what it looks like: import macros proc addTupleToCall(c: NimNode, t: NimNode, temps: NimNode) = let typ = getType(t) var s = t if t.kind != nnkSym: # If it's something more complex than sym, store i