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
double sulk
Jul 2, 2010

here have another js framework

http://facebook.github.io/react/

Adbot
ADBOT LOVES YOU

coaxmetal
Oct 21, 2010

I flamed me own dad
As much as I don't like obj-c very much, I do like how it handles generics. Which is to say, it just has the id type, which can be any type. A Generic type (its not actually its just objects though, and not everything is an object). If you need to handle arbitrary types of objects in a static type system, its easier than dealing with java's mess.

coaxmetal
Oct 21, 2010

I flamed me own dad
speaking of java, a cool new thing that oracle added to java is a splash screen. For the language runtime. Any time anything uses java there is now an oracle splash screen. Cool modern stuff that isn't dumb and annoying.

Squinty Applebottom
Jan 1, 2013

iron man runs on oracle, are you saying you have more unique demands than tony stark?

ps tony stark is a planger.

Opinion Haver
Apr 9, 2007

is there any way to extend hindley-milner to support OO subtyping/supertyping

double sulk
Jul 2, 2010

something I realized recently which probably doesn't mean anything, but was interesting

a long while back, maybe a year and a half now, I remember going to a local python users' meetup and feeling a bit out of place because most of the developers were in or much older than their mid-to-late 30s. basically real sciencey/professional types.

the local ruby users' group probably didn't have a person over 35.

Brain Candy
May 18, 2006

PleasingFungus posted:

this legit hurts my head

I think I understand it after three reads, but it's still really a thing

wait, no, maybe I don't understand it after all

gently caress

Now that you think you understand, what does Fart<B extends Fart<B> & ButtInterface> do?
or you could read a thing : http://www.angelikalanger.com/GenericsFAQ/JavaGenericsFAQ.html (only click if you are stuck in the java ghetto like me)

b0lt
Apr 29, 2005

Ronald Raiden posted:

As much as I don't like obj-c very much, I do like how it handles generics. Which is to say, it just has the id type, which can be any type. A Generic type (its not actually its just objects though, and not everything is an object). If you need to handle arbitrary types of objects in a static type system, its easier than dealing with java's mess.

yeah it's great especially when you have two classes share a selector and have different return types, and everything blows up because one of them gets compiled into objc_msgSend_stret and the other one doesn't, and the compiler just picks the version for the class that's alphabetically first or somethin

Slurps Mad Rips
Jan 25, 2009

Bwaltow!

yaoi prophet posted:

is there any way to extend hindley-milner to support OO subtyping/supertyping

F# does but thats because its got .net specific features attached to it like the base keyword and implicit inheritance from Object but even then they recommend object expressions or discriminate unions over inheritance for small stuff. doesnt stop u from using the type match operator :? in pattern matching, the only requirement is that the types have a common parent and since everything inherits from object it just works. until u try it on integers then the compiler errors.

i like F# but i havent used it since 2010 when the compiler took upwrds of 5 minutes to build a 7 file project with no more than 100 lines of code each on windows, and then it would just dump out some bullshit about how it couldnt infer the type of the expression 'a -> 'a when i would call printf or something. i dunno if its faster now.

i kinda hope they go ahead with the .net-less runtime based on llvm because then maybe more people would try about it/hear about it.

PleasingFungus
Oct 10, 2012
idiot asshole bitch who should fuck off

Brain Candy posted:

Now that you think you understand, what does Fart<B extends Fart<B> & ButtInterface> do?
or you could read a thing : http://www.angelikalanger.com/GenericsFAQ/JavaGenericsFAQ.html (only click if you are stuck in the java ghetto like me)

quote:

How do I decrypt "Enum<E extends Enum<E>>"?
As a type that can only be instantiation for its subtypes, and those subtypes will inherit some useful methods, some of which take subtype arguments (or otherwise depend on the subtype).

That literally isn't even English.

get me outta this wack-rear end java template factory !!!

JawnV6
Jul 4, 2004

So hot ...
just take the bits you get and shove them where they need to be

tef
May 30, 2004

-> some l-system crap ->

Mr Dog posted:

i mean it's that or use some lovely rear end functional language, and i'm lazy so i'll just re-use a zing i made over a year ago

in future just say 'i don't understand functional programming zing'

tef
May 30, 2004

-> some l-system crap ->
edit: eh i can't be arsed

tef fucked around with this message at 01:47 on May 30, 2013

tef
May 30, 2004

-> some l-system crap ->

PleasingFungus posted:

this legit hurts my head

I think I understand it after three reads, but it's still really a thing

wait, no, maybe I don't understand it after all

gently caress

yeah it's the trick to allow a generic type to bind to the subtype. the problem is you can't extend it afterwards without crying.

I want some enum specialised on F, that is a subtype of enum. Then you do

class Foo implements Enum<Foo> {
Foo somemethod(...)
}

and the compiler is happy

coaxmetal
Oct 21, 2010

I flamed me own dad

tef posted:

in future just say 'i don't understand functional programming zing'

this is a bitter zing than the other one anyway, which was really bad

Police Academy III
Nov 4, 2011
i'm pretty stupid but this blew my mind a bit: http://en.wikipedia.org/wiki/Covariance_and_contravariance_%28computer_science%29

PleasingFungus
Oct 10, 2012
idiot asshole bitch who should fuck off

huh, so covariance is "X or a subclass" (e.g. generics), and contravariance is "X or a parent class" (e.g. ?)

that's not too bad, but wiki does its best to avoid actually explaining it

typical

Police Academy III
Nov 4, 2011

PleasingFungus posted:

huh, so covariance is "X or a subclass" (e.g. generics), and contravariance is "X or a parent class" (e.g. ?)

that's not too bad, but wiki does its best to avoid actually explaining it

typical

the thing that got me was how that to maintain liskov substitutability, return types of re-implemented methods must be covariant, while argument types must be contravariant

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer

Ronald Raiden posted:

speaking of java, a cool new thing that oracle added to java is a splash screen. For the language runtime. Any time anything uses java there is now an oracle splash screen. Cool modern stuff that isn't dumb and annoying.

you know, i was really missing the nineties

raminasi
Jan 25, 2005

a last drink with no ice

SAHChandler posted:

i like F# but i havent used it since 2010 when the compiler took upwrds of 5 minutes to build a 7 file project with no more than 100 lines of code each on windows, and then it would just dump out some bullshit about how it couldnt infer the type of the expression 'a -> 'a when i would call printf or something. i dunno if its faster now.

i kinda hope they go ahead with the .net-less runtime based on llvm because then maybe more people would try about it/hear about it.

i don't have compilation time complaints about f#. my complaints are more along the lines of "why the gently caress do i need to put mutally-recursively-defined types in the same source file" and "if intellisense can infer this type why the hell can't the compiler"

Slurps Mad Rips
Jan 25, 2009

Bwaltow!

GrumpyDoctor posted:

i don't have compilation time complaints about f#. my complaints are more along the lines of "why the gently caress do i need to put mutally-recursively-defined types in the same source file" and "if intellisense can infer this type why the hell can't the compiler"

i totally forgot about that. i would get around it by making a base inheritable class or using dynamic lookup (operator ?), which was a horrible hack but at least i could get around it that way.
also i forgot about the order the files are shown in visual studio being important, but all those problems come from ocaml.

Nomnom Cookie
Aug 30, 2009



GrumpyDoctor posted:

i don't have compilation time complaints about f#. my complaints are more along the lines of "why the gently caress do i need to put mutally-recursively-defined types in the same source file" and "if intellisense can infer this type why the hell can't the compiler"

the smarter a compiler is the harder it is to avoid violating the principle of least astonishment. but that does sound kinda whack, the ide should flag it as an error if the compiler will

thats another nice thing about java. acceptable programs are precisely defined and just going off the spec you can decide whether a program will compile without ever invoking the compiler

Slurps Mad Rips
Jan 25, 2009

Bwaltow!

Nomnom Cookie posted:

the smarter a compiler is the harder it is to avoid violating the principle of least astonishment. but that does sound kinda whack, the ide should flag it as an error if the compiler will

thats another nice thing about java. acceptable programs are precisely defined and just going off the spec you can decide whether a program will compile without ever invoking the compiler

f# has two kinds of generics. it has the .net generics, because its .net but it also has compile time generics and these have a whole different set of behavior that makes it really nice to work with, or a total pita depending on ur opinion of how u interact with it.

on the .net side of generics u have implicit generics like

code:
let butt (x:'a) (y:'a) = x + y
which generates a function of 'a -> 'a -> 'a + 'a. but u also have explicit generic functions like

code:
let butt2<'T> x y = x + y
and this lets u have wildcards as well

code:
let butt3 (alist : seq<_>) = Seq.iter (fun elem -> printfn "%s" (elem.ToString())) alist
and then u can use f# constraints which are basically what c++ concepts were supposed to be that are resolved at compile time with class interfaces (but dont enforce anything runtime based)

code:
let x ('a : when 'a :> System.Exception) = ( )
then u have "statically resolve parameter types" which is to say, c++ style templates but without the branching, bcuz its provided by compile and runtime pattern matching within the type system

tef
May 30, 2004

-> some l-system crap ->
https://jira.mongodb.org/browse/PYTHON-532

prefect
Sep 11, 2001

No one, Woodhouse.
No one.




Dead Man’s Band

"plebbery"? is that one of those words that they teach people in those fancy english schools?

Nomnom Cookie
Aug 30, 2009



i liked the one where mongodb would just fail to insert documents and not notice that it had just lost data

prefect
Sep 11, 2001

No one, Woodhouse.
No one.




Dead Man’s Band
Steps to fix:

1. MIKE WAS BORN A TECH WRITER. REVOKE COMMIT PRIVS TODAY




aw, i used to be a tech writer :smith:

Nomnom Cookie
Aug 30, 2009



prefect posted:

Steps to fix:

1. MIKE WAS BORN A TECH WRITER. REVOKE COMMIT PRIVS TODAY




aw, i used to be a tech writer :smith:

ask yourself whether you really should have commit access to your company's repos. i think that deep inside you know the answer

prefect
Sep 11, 2001

No one, Woodhouse.
No one.




Dead Man’s Band

Nomnom Cookie posted:

ask yourself whether you really should have commit access to your company's repos. i think that deep inside you know the answer

i do have such access, because i maintain source control (among other things)

MrMoo
Sep 14, 2000

prefect posted:

"plebbery"? is that one of those words that they teach people in those fancy english schools?

Silver spoon toffs, http://www.guardian.co.uk/politics/2012/oct/19/andrew-mitchell-resigns-police-pleb

GameCube
Nov 21, 2006

this is old as gently caress but i don't remember anybody discussing jeff atwood's reasoning for going with ruby for discourse. includes such gems as this

quote:

Getting up and running with a Microsoft stack is just plain too hard for a developer in, say, Argentina, or Nepal, or Bulgaria.

so guess what all the comments are about

quote:

I live and work in Bulgaria, and you are wrong. My impression is that most Bulgarian programmers use .NET. I am not sure if you imply people are poor and don't have the money to buy the tooling, but this is not the case. Most programmers start out working for a company and most companies in Bulgaria pay for Microsoft tools. Once you have the skill, even after you move on and start contributing to open source projects, you don't give up on .NET. I think that Bulgaria is no different that the US in how developers decide what tools to use.

quote:

For some strange reason .NET is disproportionally stronger in Bulgaria compared to the rest in the world. Maybe it's the fact that Telerik are a Bulgarian company. I can't explain it but the Bulgarian .NET community is stronger than any other dev community here (I judge this by the number and quality of events and conferences, courses, etc.)

quote:

Also, there are start-ups that use Microsoft technologies. We are doing quite interesting things, and we are in Bulgaria, too :) Come on, I thought you were a pragmatic programmer!

quote:

How is that even remotely true?

I live in Argentina and I'm perfectly capable of working with the Micorosft stack (and have been doing so for years).

quote:

It's not just Telerik, .NET and Microsoft are strongly represented in the Bulgarian government too, they recently spent millions on MS licenses (both server and desktop OSs, among other things). We're in a dire situation here...

quote:

I live in Bulgaria. Getting a full Microsoft stack is very easy for Bulgarian programmers because piracy and hacking has very strong traditions here and is ingrained in the culture.

quote:

That statement it's just plain wrong(at least for Argentina). Almost everything it is built on .NET and run on Windows machines.
And there is a lot of of open source projects in the .NET sphere to, nhibernate, moq, funq, etc....(all run by argentinian guys)
Just saying.

but hey, at least no nepalese programmers checked in

Workaday Wizard
Oct 23, 2009

by Pragmatica

Werthog 95 posted:

this is old as gently caress but i don't remember anybody discussing jeff atwood's reasoning for going with ruby for discourse. includes such gems as this


so guess what all the comments are about








but hey, at least no nepalese programmers checked in

i cant leave my bubble man there are... things... out there

MononcQc
May 29, 2007


Came here to post this. Was already there. The guy who reported this bug would be welcome in this thread I think.

Plastic Snake
Mar 2, 2005
For Halloween or scaring people.

Nomnom Cookie posted:

i liked the one where mongodb would just fail to insert documents and not notice that it had just lost data

it's a ~*feature*~

Meiwaku
Jan 10, 2011

Fun for the whole family!

MononcQc posted:

Came here to post this. Was already there. The guy who reported this bug would be welcome in this thread I think.

Python and Java driver in the same week no less. Truly web scale!

Blotto Skorzany
Nov 7, 2008

He's a PSoC, loose and runnin'
came the whisper from each lip
And he's here to do some business with
the bad ADC on his chip
bad ADC on his chiiiiip
webbu sceiru ~uguu~

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer

:ughh:

double sulk
Jul 2, 2010

http://joearms.github.io/2013/05/31/a-week-with-elixir.html

:D

jooky
Jan 15, 2003


cool another hn link from sulk that he probably didnt read / doesnt understand

Adbot
ADBOT LOVES YOU

double sulk
Jul 2, 2010

jooky posted:

cool another hn link from sulk that he probably didnt read / doesnt understand

yw

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