nim-basics icon indicating copy to clipboard operation
nim-basics copied to clipboard

Add a small section on structs

Open richardanaya opened this issue 5 years ago • 4 comments

I think structs could very simply be described to some degree in the basics section

richardanaya avatar Apr 14 '19 23:04 richardanaya

I've thought about adding user-defined types, including objects/structs, but in the end I decided against it. This would make the tutorial quite longer and less beginner-friendly, as it would have to include lots of detailed explanations, including the differences between object and ref object, which in turn gets us in explanations about pointers, ...

My conclusion was that this, among some other more advanced things, belongs to "Nim not-so-basics", which would be a separate tutorial. I haven't had the time to work on it, but who knows what will future bring :)

narimiran avatar Apr 26 '19 17:04 narimiran

This would make the tutorial quite longer and less beginner-friendly

Well, you could make a separate second part to it, for intermediate topics. If you're inclined to keep doing tutorials. (And even a third part for advanced stuff.)

I was gonna suggest a small section explaining funcs and methods and when (and if ever) to use them (I'm trying to understand that now myself -- because the official tutorial is too technical and also doesn't explain what dynamic dispatch is).

Skaruts avatar Jul 14 '19 07:07 Skaruts

you could make a separate second part to it, for intermediate topics

As I already said in the above reply:

... this, among some other more advanced things, belongs to "Nim not-so-basics", which would be a separate tutorial. I haven't had the time to work on it, but who knows what will future bring :)


I was gonna suggest a small section explaining funcs and methods and when (and if ever) to use them (I'm trying to understand that now myself -- because the official tutorial is too technical and also doesn't explain what dynamic dispatch is).

This also belongs for some intermediate tutorial, for which I still don't have the time to write, sorry.

narimiran avatar Jul 14 '19 10:07 narimiran

As I already said in the above reply:

I overlooked it. Sorry.

Alright then. Thanks anyway. You did a great job with the existing one btw. :)

Cheers.

Skaruts avatar Jul 15 '19 06:07 Skaruts