Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Locked thread
pram
Jun 10, 2001
why isnt go more like erlang :qq:

Adbot
ADBOT LOVES YOU

rjmccall
Sep 7, 2007

no worries friend
Fun Shoe

pram posted:

its a real language developed by talented people

oh i thought it was developed by rob pike

pram
Jun 10, 2001
r->c->p

pram posted:

actually rob pike is way. way smarter than you and probably has a bigger dick. ya mad?

Subjunctive
Sep 12, 2006

✨sparkle and shine✨


boy, I'm glad that I didn't accidentally destroy JS when I added map/filter/reduce/etc to Arrays; I had no idea they were such dangerous concepts to encounter

pram
Jun 10, 2001
why do procedural languages need more functional garbage

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

pram posted:

why do procedural languages need more functional garbage

because, uh, manipulation of sequences of data is a very common undertaking in programs written in any style. it's not like go is some triumph of minimalism in the first place.

why do you think rob pike is a good language designer? your support for go seems very tied up in that opinion of him, but I'm not sure what of his pre-go language work has left you so enamoured.

comedyblissoption
Mar 15, 2006

pram posted:

why do procedural languages need more functional garbage
eventually you may tire of janitoring for loops

pram
Jun 10, 2001
the majority of criticism here is that it doesnt work exactly the way (whatever) works. i'd say it IS pretty minimalist and it's extremely easy to learn and use and remember. its not a functional language. it has loops. for loops are not complicated to janitor

MononcQc
May 29, 2007

What go has going for it is good compiling speed, okay performance (faster than some, slower than some), good toolchain, good documentation, a cool corporation backing it, and the ability to ship standalone binaries with no dependencies.

The criticism is that there is prior art in language design in stuff that has happened in the last 30 years and it is a bit sad to see new languages position themselves in an occupied space while providing none of the modern niceties any other languages in that space already provide and have done so for years, whether they're generics, collections, better concurrency patterns, error handling, type systems, and so on.

People used to these things being supported see themselves having to rewrite poo poo they've taken for granted forever and can't see themselves rebuilding or working around that poo poo.

comedyblissoption
Mar 15, 2006

benefits of higher order functions over manually written for loops:
  • composable
  • easier to read
  • easier to write
  • less bugs and mistakes
  • reveal intent
  • less repetition
  • can be more performant than quickly thrown together for loops when using lazy evaluation
  • can provide generalized ways to process generic traversable data structures

comedyblissoption
Mar 15, 2006

contrived C# code that i havent checked for compilation providing an example:

code:
int getSumOfFirstTenOddIntegersGreaterThanHundred(IEnumerable<int> ints) {
  return ints
    .Where(x => x > 100)
    .Where(IsOdd)
    .Take(10)
    .Sum();
}
this works on any ienumerable which is a generalized interface for enumerating over a data structure

unfortunately C# sucks on generalizing over all primitive numbers, but there are other languages that can do that

Brain Candy
May 18, 2006

go is that 'wacky' muffin shop that opens at 9:30

it is a vanity project for a bored trophy spouse. time and money went into it, but it's not about producing something that other people need

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

pram posted:

the majority of criticism here is that it doesnt work exactly the way (whatever) works. i'd say it IS pretty minimalist and it's extremely easy to learn and use and remember. its not a functional language. it has loops. for loops are not complicated to janitor

I was asking why you were Team Rob Pike, not why you didn't like people criticizing go.

given go's emphasis on parallelism, that they forwent the opportunity to have a parallelMap and similar seems a bit odd. I suppose that channel dispatch and gathering of results aren't complicated to janitor either?

(go error handling with convention-of-multiple-return and defer and panic/recover really feels like someone wanted to build "errno the sequel", rather than being simple and clear, but I haven't built anything big with it. having to squeeze things through interface{} to reuse collections is pretty painful to janitor.)

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Brain Candy posted:

go is that 'wacky' muffin shop that opens at 9:30

it is a vanity project for a bored trophy spouse. time and money went into it, but it's not about producing something that other people need

see also Dart; Google uses language creation as compensation for name-brand engineers at times.

comedyblissoption
Mar 15, 2006

equivalent janitored for loop that i havent compiled because im bored:
code:
int getSumOfFirstTenOddIntegersGreaterThanHundred(IEnumerable<int> ints) {
  var sum = 0;
  var count = 0;
  foreach (var x in ints) {
    if (x > 100 && IsOdd(x)) {
      sum += x;
      count++;
      if (count == 10) {
        break;
      }
    }
  }

  return sum;
}
even for a ridiculously contrived simple example, it's much harder to detect if there may be an error in the program when writing and reading it

edit: lol i forgot the sum part of it because janitoring for loops is dumb

comedyblissoption fucked around with this message at 03:59 on May 23, 2015

pram
Jun 10, 2001
im not reading this gay dog pile but the point is go is a procedural language that is probably intended to compete with php and python and node. lol. and its way better than these things. lots of companies like docker and dropbox and cloudflare use it. its good. haskell is used in nothing. no one cares about functional poo poo except a small coterie of virgins. hth hand

comedyblissoption
Mar 15, 2006

java, javascript, c#, and python all have this "functional poo poo" and are as mainstream as it gets

idk if php supports it

pram
Jun 10, 2001
yes, they are added. and thank god rob pike was smart enough to prevent third parties from polluting the runtime with that poo poo

comedyblissoption
Mar 15, 2006

for loops are minimalist

but i would argue that branch jump is more minimalist and therefore should be more preferred

jony neuemonic
Nov 13, 2009

comedyblissoption posted:

java, javascript, c#, and python all have this "functional poo poo" and are as mainstream as it gets

idk if php supports it

yes, php has higher order functions. they have terrible syntax and are a pain to use, but it has them.

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

pram posted:

yes, they are added. and thank god rob pike was smart enough to prevent third parties from polluting the runtime with that poo poo

what third parties? when I added them to JS they went into the standard, and the other mentioned languages have them in the core runtime as well. they're all procedural languages.

and why do you think rob pike is so smart?

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

I mean, Google is *built* on top of map-reduce, and I don't think any of their production languages are functional.

pram
Jun 10, 2001
yeah and its fine? i know map and filter are in js and python. its cool man. grats on adding something to the standard. yr really smart and impressive. but guess what: i can live without them (and really so can most people)

Brain Candy
May 18, 2006

pram posted:

...to compete with php and python and node. lol. and its way better than these things.

lol, that bar is so low it's just a line somebody drew in the dirt

pram
Jun 10, 2001
yes haha no one uses php or python :shepface: stfu idiot

leftist heap
Feb 28, 2013

Fun Shoe

MononcQc posted:

What go has going for it is good compiling speed, okay performance (faster than some, slower than some), good toolchain, good documentation, a cool corporation backing it, and the ability to ship standalone binaries with no dependencies.

The criticism is that there is prior art in language design in stuff that has happened in the last 30 years and it is a bit sad to see new languages position themselves in an occupied space while providing none of the modern niceties any other languages in that space already provide and have done so for years, whether they're generics, collections, better concurrency patterns, error handling, type systems, and so on.

People used to these things being supported see themselves having to rewrite poo poo they've taken for granted forever and can't see themselves rebuilding or working around that poo poo.

lol, source your quotes

pram
Jun 10, 2001
also dart is good too. and typescript

comedyblissoption
Mar 15, 2006

my goal here is mainly to educate the benefits of using alternatives to for loops

i'm mostly tired of having to reverse engineer intent from looking at the code instead of an alternative of the code declaratively telling me its intent

pram
Jun 10, 2001
for loops were good enough for the fathers of unix, ritchie and thompson

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

sure, but the standard for language inclusion isn't necessity. else you wouldn't have defer or channels or even for-range, however cute they look in your rob pike tiger beat poster.

a language should have the facilities that let programmers produce programs that are clear and correct expressions of their intent. that most people don't need panic or recover doesn't mean they don't belong in the language.

the real failing of go here isn't that it is missing simple things like map and fold, but that you can't implement them well in library code because of the "novel type system" making you suck on son-of-void * if you try.

pram
Jun 10, 2001
i think thats intentional

jony neuemonic
Nov 13, 2009

pram is tori-ing all of you.

i mean, it's that or he actually likes go. lol.

pram
Jun 10, 2001
i think subjunctive is jealous about rob pike lol

comedyblissoption
Mar 15, 2006

at the very least we can warn the innocent away from go

pram
Jun 10, 2001
but then again who wouldnt be. more legend than man

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

pram posted:

i think thats intentional

well, they say that they want to find a way to add generics, so I'm not sure that's the case.

it may be somewhat dissonant for you if they do, I appreciate, but we'll be here for you

pram
Jun 10, 2001

Subjunctive posted:

well, they say that they want to find a way to add generics, so I'm not sure that's the case.

it may be somewhat dissonant for you if they do, I appreciate, but we'll be here for you

dude idgaf if they add generics or map reduce. this is not an ideological thing. i really dont care.

pram
Jun 10, 2001
im just saying their missing presence isnt some giant crippling handicap you all seem to think it is

Bloody
Mar 3, 2013

go is a terrible language and you must be literally retarded to think otherwise

Adbot
ADBOT LOVES YOU

Bloody
Mar 3, 2013

like if you want a crufty minimalist language with no modern anything you could just use c

  • Locked thread