Generics may well be added at some point. We don’t feel an urgency for them, although we understand some programmers do.

Generics are convenient but they come at a cost in complexity in the type system and run-time. We haven’t yet found a design that gives value proportionate to the complexity, although we continue to think about it. Meanwhile, Go’s built-in maps and slices, plus the ability to use the empty interface to construct containers (with explicit unboxing) mean in many cases it is possible to write code that does what generics would enable, if less smoothly.

https://golang.org/doc/faq#generics

#golang #go #generics #programming

բնօրինակ սփիւռքում(եւ մեկնաբանութիւննե՞ր)

discussing go, one says:

why this func incTwo(a, b int) (c, d int) not (int c, d) incTwo(int a, b);

and why var v2 string not var string v2;

answer: >because compare

int (*(*fp)(int (*)(int, int), int))(int, int) and f func(func(int,int) int, int) func(int, int) int

#go #syntax #grammar #programming #programming_languages #code #notation

բնօրինակ սփիւռքում(եւ մեկնաբանութիւննե՞ր)

Ngaro is a minimalistic virtual machine emulating a dual stack computer with a simple instruction set and a few basic I/O devices.

http://retroforth.org/docs/The_Ngaro_Virtual_Machine.html

#ngaro #vm #virtual-machine #emulation

At present, there are full implementations in #Assembly (#x86), #C, #F#, #Go, #Common-Lisp, #PHP, #Python, and #Ruby, and minimal implementations in #C#, #Forth, #Lua, #JavaScript, #Java, #Perl, and #Scheme

բնօրինակ սփիւռքում(եւ մեկնաբանութիւննե՞ր)

So #go is 16th, thus it took place in top 20 #github languages.

http://adambard.com/blog/top-github-languages-for-2013-so-far/

However last year it was at 13th place. Anyway, I think that’s a great achievement for #golang. #google-go #go-lang #programming #programming-languages #փաստորեն

բնօրինակ սփիւռքում(եւ մեկնաբանութիւննե՞ր)