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.
 
  • Post
  • Reply
gonadic io
Feb 16, 2011

>>=

Brain Candy posted:

ya, i don't understand why you'd do a new thing in scala. pick clojure or frege depending on how you feel about static typing

is frege production ready? last i saw it was an immature research lang

Adbot
ADBOT LOVES YOU

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder

FamDav posted:

complex mutable data is a problem in your application, but lack of type safety is a huge problem in the downstream applications consuming your code

heh well here's to hoping i continue to never have the problem of applications consuming my code

gonadic io
Feb 16, 2011

>>=

FamDav posted:

turns out that what you really wanted in the first place is java 10, in 2030 :shaggar:

coffeetable
Feb 5, 2006

TELL ME AGAIN HOW GREAT BRITAIN WOULD BE IF IT WAS RULED BY THE MERCILESS JACKBOOT OF PRINCE CHARLES

YES I DO TALK TO PLANTS ACTUALLY

Brain Candy posted:

imo, Conway's law effects how static typing works for you. if you can roll with a big monothic static typing is great but if you are gluing smaller things together it turns into busy work
just because C and java don't have type inference doesn't mean every statically typed language has to go without it

tef
May 30, 2004

-> some l-system crap ->
cheap aside: i know i'm planger scum but SQL has been one of the few environments where there's explicit typing and it works real well :v:

triple sulk
Sep 17, 2014



Bloody posted:

hi someone point me to a deece learn you a scala thing thanks in advance

scala is a giant waste of time. learn f# instead.

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder
idk how i feel about pug shaggar

triple sulk
Sep 17, 2014



scala probably has the worst tooling of any language in existence

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder
i feel like the kind of person who can look at a pugs face and say 'this is good and healthy and natural' is the kind of person who is going to find developing on windows unobjectionable

triple sulk
Sep 17, 2014



vs2015 is really cool and good and is literally the only thing that's going to keep people doing asp.net development on windows on windows

Brain Candy
May 18, 2006

gonadic io posted:

is frege production ready? last i saw it was an immature research lang

to write bits in it? how much of https://github.com/Frege/frege/wiki/Differences-between-Frege-and-Haskell makes you angry (and lack of libs!)

to write everything in? i dunno, it's still a moving target as they figure out how much it wants to be it's own thing apart from Haskell

but it's not so immature that it doesn't work with maven. there's a REPL. it just runs as another jar with a blob of generated classes inside. eclipse/intellij plugins exist

FamDav
Mar 29, 2008

triple sulk posted:

scala is a giant waste of time. learn f# instead.

MALE SHOEGAZE posted:

idk how i feel about pug shaggar

http://sulk.yospos.net

FamDav
Mar 29, 2008

Brain Candy posted:

to write bits in it? how much of https://github.com/Frege/frege/wiki/Differences-between-Frege-and-Haskell makes you angry (and lack of libs!)

to write everything in? i dunno, it's still a moving target as they figure out how much it wants to be it's own thing apart from Haskell

but it's not so immature that it doesn't work with maven. there's a REPL. it just runs as another jar with a blob of generated classes inside. eclipse/intellij plugins exist

why would you contribute to Frege when you have to assign copyright to this guy https://github.com/Frege/frege/blob/master/LICENSE.txt

Brain Candy
May 18, 2006

coffeetable posted:

just because C and java don't have type inference doesn't mean every statically typed language has to go without it

when i wrote those words i had haskell in mind so

i guess you could use tuples everywhere but i don't want to risk those messages, reminds me too much of old gcc barfing on templates

distortion park
Apr 25, 2011


FamDav posted:

complex mutable data is a problem in your application, but lack of type safety is a huge problem in the downstream applications consuming your code

cf excel interop. you never know if you're gonna get a double, an int (aka an error code), or just a good old exception back when you call some method

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder
your api integration points should obviously have well defined expectations. those integration points should really be simple enough that you don't need a compiler to verify them for you.

i mean obv this depends on your use case. if you're integrating with the linux kernel or something, types are probably a nice thing to have.

i mean they're a nice thing to have regardless,

DONT THREAD ON ME fucked around with this message at 21:23 on Dec 20, 2015

MononcQc
May 29, 2007

FamDav posted:

complex mutable data is a problem in your application, but lack of type safety is a huge problem in the downstream applications consuming your code

Unless you're embedding your programs into each other, type information is often just lost when communicating over regular channels, or carried through serialization formats or well-defined protocol that are independent from the language using them.

Cloud Haskell is an example of where this doesn't happen, and Cloud Haskell doesn't handle upgrading some nodes of a cluster, you need to replace the entire thing for type information to work.

coffeetable
Feb 5, 2006

TELL ME AGAIN HOW GREAT BRITAIN WOULD BE IF IT WAS RULED BY THE MERCILESS JACKBOOT OF PRINCE CHARLES

YES I DO TALK TO PLANTS ACTUALLY

Brain Candy posted:

when i wrote those words i had haskell in mind so

i guess you could use tuples everywhere but i don't want to risk those messages, reminds me too much of old gcc barfing on templates

those messages are going to happen anyway, your choice is between whether they happen at compile time or runtime

Emacs Headroom
Aug 2, 2003

FamDav posted:

scala is going to persist in ML so long as spark is a thing, though with dataframes not incurring a real performance penalty in python i could see scala being an implementation detail.


pyspark and spark dataframes are the path to suicide

only make rdds of case classes.

also don't use mllib, it's mostly lovely wrappers for breeze on spark dataframes. just use breeze on the rdds.

VikingofRock
Aug 24, 2008




Brain Candy posted:

when i wrote those words i had haskell in mind so

i guess you could use tuples everywhere but i don't want to risk those messages, reminds me too much of old gcc barfing on templates

I agree this is a pain, but I don't see how removing static types helps. All it does is lead to things like having 2 < '1' be true in Python 2.

FamDav
Mar 29, 2008

MononcQc posted:

Unless you're embedding your programs into each other, type information is often just lost when communicating over regular channels, or carried through serialization formats or well-defined protocol that are independent from the language using them.

Cloud Haskell is an example of where this doesn't happen, and Cloud Haskell doesn't handle upgrading some nodes of a cluster, you need to replace the entire thing for type information to work.

for ipc/network sure, though you'll want to vend packages with models that make interacting with that service simple.

i'm thinking of libraries that are vended out to 10s/100s of other teams. if you have types in place you can understand how code in your package is being used by others and automate changes to replace/alert on deprecated APIs.

VikingofRock
Aug 24, 2008




Also {-# LANGUAGE OverloadedStrings #-} 4 lyf

FamDav
Mar 29, 2008
i really enjoy wired's reporting on anything

"Google has 25,000 engineers making 45,000* commits a day!"

* 80% of which are automated changes, mostly config.

VikingofRock
Aug 24, 2008




So I looked into the Python 2 comparing thing a little more, because I couldn't remember what the rationale was for having ints always be less than strings.

"Python 2.7 docs posted:

Note that comparing objects of different types is legal. The outcome is deterministic but arbitrary: the types are ordered by their name. Thus, a list is always smaller than a string, a string is always smaller than a tuple, etc. [1] Mixed numeric types are compared according to their numeric value, so 0 equals 0.0, etc.

:pusheen:

Cybernetic Vermin
Apr 18, 2005

having everything comparable seems perfectly reasonable, getting a canonical ordering of arbitrary things can be very useful (e.g. making a binary tree of arbitrary objects), so getting it in on the language level may be desirable

the 0.0=0 bit is a mistake though

Ralith
Jan 12, 2011

I see a ship in the harbor
I can and shall obey
But if it wasn't for your misfortune
I'd be a heavenly person today

Brain Candy posted:

but every nanosecond spent translating my Butt type to your Butt type is a nanosecond wasted.
But you have to do this with dynamic typing too, you're just vastly more likely to forget it somewhere and have your code explode in production :confused:

Types exist regardless, the only question is how much the compiler knows about them in advance.

It sounds like you're just complaining about bad API design regardless of paradigm.

Brain Candy
May 18, 2006

coffeetable posted:

those messages are going to happen anyway, your choice is between whether they happen at compile time or runtime

no, i could write idiomatic haskell and give names to my data types. then ghc could actually give me meaningful messages because i've already described my intent in a language i understand

i'll try to describe why this costs differently depending on circumstances a little later

VikingofRock posted:

I agree this is a pain, but I don't see how removing static types helps. All it does is lead to things like having 2 < '1' be true in Python 2.

this is still a thing with falsiness and 0==0.0 but it's got nothing to do with dynamic typing

dynamic typing != implicit conversion. you don't have to look at python for kind of crap, C does it

---

what i'm saiyan w.r.t. static v. dynamic and structure:

in a unified codebase, static typing is wonderful. when you make changes visible to the type system, like adding a new field to some datatype, the compiler helps you with design. you can see all the effects of your changes and you are forced to address them.

to me, this is the largest benefit. sure, you also are inured from certain typographic level mistakes, but the main benefit is immediate feedback on how your proposed changes effect the rest of the system.

OTOH, with a more modular (this isn't a value judgement!) system, you don't have this omniscent view. and now there are costs you didn't have before. a simple example:

imagine you've got two modules, A, B with a shared type Butt. now in module B, you realize your Butt needs a Maybe FartVolume. if A created even one Butt, A is desynced with module B and incompatible. you've forced somebody to release a new version of, A.

over a thing that doesn't need to be present

if Butt wasn't a type with a fixed arity, but instead a map, adding optional data does not force A to update. A does not depend on that data and doesn't care about what you add to your bag

this is something we know when shuffling bits between processes. ex: protobuf docs tell you to never make fields not optional. this is partly to give you room to deprecate, but it's also because non-optional fields preclude backwards compat

craisins
May 17, 2004

A DRIIIIIIIIIIIIVE!

FamDav posted:

i really enjoy wired's reporting on anything

"Google has 25,000 engineers making 45,000* commits a day!"

* 80% of which are automated changes, mostly config.
less than 2 commits a day doesn't even sound too far fetched. poo poo when i'm in bug fixing mode i can fix anywhere between like 2 and 10 bugs a day, each with their own commit

Sweeper
Nov 29, 2007
The Joe Buck of Posting
Dinosaur Gum

craisins posted:

less than 2 commits a day doesn't even sound too far fetched. poo poo when i'm in bug fixing mode i can fix anywhere between like 2 and 10 bugs a day, each with their own commit

I can easily do 20 in a day if you consider different packages (repository I guess?) different commits

FamDav
Mar 29, 2008
do y'all jump on code reviews quickly? I find that to be the biggest bottleneck.

VikingofRock
Aug 24, 2008




Cybernetic Vermin posted:

having everything comparable seems perfectly reasonable, getting a canonical ordering of arbitrary things can be very useful (e.g. making a binary tree of arbitrary objects), so getting it in on the language level may be desirable

the 0.0=0 bit is a mistake though

Alright I've thought about this a bit, and I can see where you (and I suppose guido) are coming from and how that could be useful. I started to write up something about how much I dislike the idea of having a binary tree of arbitrary things, but in reality I just dislike dynamic typing, and if python didn't have that it wouldn't really be python anymore so I guess it makes sense to go whole hog and define how to compare floats and dictionaries. :pusheen: withdrawn.

craisins
May 17, 2004

A DRIIIIIIIIIIIIVE!

FamDav posted:

do y'all jump on code reviews quickly? I find that to be the biggest bottleneck.
i usually have people review code before making the commit, catches things early before i commit something that wouldn't make sense. but i've also worked at places where i commit to a branch and then someone will review and merge into trunk

edit: when someone needs a review i usually drop what im doing and review, unless i'm in the middle of a thought/chunk of code

Sweeper
Nov 29, 2007
The Joe Buck of Posting
Dinosaur Gum

FamDav posted:

do y'all jump on code reviews quickly? I find that to be the biggest bottleneck.

I always do reviews asap so that people will do mine quickly, seems to work out

qntm
Jun 17, 2009
Our code reviews are part of the system, you can't commit without one.

Bloody
Mar 3, 2013

I'm not looking for language suggestions I'm looking for resources for one particular thing if any exist

Emacs Headroom
Aug 2, 2003

qntm posted:

Our code reviews are part of the system, you can't commit without one.

are the review pre-commit people on Gerrit? i like Gerrit OK, but github (and sometimes phabricator) seems more popular with it's review pre-merge

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer

Brain Candy posted:

translating my Butt type to your Butt type

text me

Soricidus
Oct 21, 2010
freedom-hating statist shill
butt typing

qntm
Jun 17, 2009

Emacs Headroom posted:

are the review pre-commit people on Gerrit? i like Gerrit OK, but github (and sometimes phabricator) seems more popular with it's review pre-merge

We use IBM Rational Team Concert and possibly I used the wrong word there. Yes, the mandatory buddy check is after committing to your private workspace and prior to delivering your changes into the main stream.

Adbot
ADBOT LOVES YOU

Bloody
Mar 3, 2013

lol scala is a crazy lang

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply