Mindset Nim

2023-09-22 Thread radekm
I believe it's not expected because in Pluto order of cells should not matter. They write: > Cells can even be placed in arbitrary order - intelligent syntax analysis > figures out the dependencies between them and takes care of execution. in [Readme](https://github.com/fonsp/Pluto.jl). But rea

Mindset Nim

2023-09-20 Thread radekm
> At any instant, the program state is completely described by the code you see. I think that is generally not true in Pluto. Citing from : # Example (each row in a separate Pluto cell): a = [4, 3, 2, 1] a # prints [4, 3, 2,

Mastering Nim 2.0

2023-08-28 Thread radekm
Amazon says that book was published on June 22, 2022. Is this okay? Will I get the updated edition?

One language to rule them all.

2023-08-25 Thread radekm
Church-Turing thesis says that certain theoretical computation models compute same functions (or in simpler words solve same problems). Unfortunately these models are theoretical and assume unbounded memory. Church-Turing thesis also doesn't bother with the "speed" of these models or how comfor

Using asm or intrinsic C functions from Nim

2023-08-25 Thread radekm
Yes, I think using C intrinsics makes sense. Same approach is used by

[Scala background] How does a macro in Scala differs from macro in Nim?

2023-08-14 Thread radekm
I believe (not sure) that in Nim macros run before typechecking so you can't get typed AST?

Nim 2 and need for try-finally?

2023-08-11 Thread radekm
Hi, since Nim 2 brought ARC/ORC it is tempting to stop using try-finally for disposing resources. Because now `=destroy` will be called automatically when reference count drops to 0. But some examples in `stdlib` documentation eg. `std/httpclient` still use try-finally. When I looked into the

Plans for improving tagged enum (ADT) syntax?

2022-11-27 Thread radekm
> you cannot initialize a case object with the case data only, you need to > instantiate the "shell" type On the other hand the advantage of Nim case objects is that tags are first class. So you can pass only a tag to a function or change a tag if you remain in the same branch. > A tagged enum

Choosing Nim out of a crowded market for systems programming languages

2022-11-26 Thread radekm
I'm mostly Kotlin and F# programmer and one of the biggest advantages of Nim over those languages is deterministic performance and super easy FFI with C.

Nimble and two different C files with the same name

2022-08-20 Thread radekm
Awesome. You're right, it works!

Nimble and two different C files with the same name

2022-08-20 Thread radekm
Thanks for the answer. The problem with Zippy is that it doesn't support gzips with multiple members ie. multiple concatenated gzips (which is according to the standard RFC 1952 still valid gzip and all unix tools normally support that). The culprit in Zippy is

Nimble and two different C files with the same name

2022-08-19 Thread radekm
s.c", compile: "libdeflate_gzip/private/libdeflate/lib/crc32.c", compile: "libdeflate_gzip/private/libdeflate/lib/gzip_decompress.c" .} Run Unfortunately when linking my test I'm getting error duplicate symbol '