Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

NULL, NULL, 0, NULL, NULL

Name: Anonymous 2010-06-14 23:01

We may make fun of Microsoft's BEST ENTERPRISE SOFTWARE PRACTICES, but seriously, what were they smoking* when they came up with the NULL, NULL, NULL nonsense?

* No, not their anuses, before anyone suggests that.

Name: Anonymous 2010-06-14 23:10

I can't tell if you're serious or not and that is sad.

Name: Anonymous 2010-06-14 23:18

They wanted to provide functions that were very flexible but had sensible defaults for the common case.

Name: Anonymous 2010-06-14 23:39

Did someone suddenly forget what functioning overloading was?

Name: Anonymous 2010-06-14 23:48

Couldn't they have supplied both  foo() and foo(long argument list) functions though?

Name: Anonymous 2010-06-14 23:49

>>4
Are you referring to >>1 or Microsoft? Because if you're referring to Microsoft, you should maybe look at how C works.

Name: Anonymous 2010-06-14 23:49

>>5
You should maybe look at how C works.

Name: Anonymous 2010-06-14 23:55

>>7
You should maybe look at SICP.
Fixed that for ya.

Name: Anonymous 2010-06-15 0:00

>>3
Most of POSIX uses attr structs for this.

Name: Anonymous 2010-06-15 0:10

>>9
Which are hideous, to be fair.

Name: Anonymous 2010-06-15 0:11

>>10
More hideous than NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL?

Name: Anonymous 2010-06-15 0:16

>>11
At least it's consistent.

Name: Anonymous 2010-06-15 0:18

>>5
C++, C#, or Java developer detected!

Name: Anonymous 2010-06-15 4:38

They could have atleast provided macros for common used functions.
Shame M$, shame.

Name: Anonymous 2010-06-15 4:49

bar(x)=foo(x,NULL,NULL,NULL)
call->bar(7)=foo(7,NULL,NULL,NULL)
Problem solved

Name: Anonymous 2010-06-15 4:53

>>15
It's a problem that Microsoft should have fixed themselves.

Name: Anonymous 2010-06-15 10:12

>>16
Not like >>15 they shouldn't have. The Windows API is bloated enough as it is without having to duplicate every function ten times with a different number of arguments.

Name: Anonymous 2010-06-15 11:36

>>15
bar x = foo x NULL NULL NULL in Haskell. Proof that C sucks.

Name: Anonymous 2010-06-15 23:13

I already wrote an explanation to how this could be solved with keyword/optional/rest arguments that CL has, but since C is not CL, one will have to either redesign the API or just deal with the NULL's for options which are not present.

Name: ​​​​​​​​​​ 2010-09-09 21:27

Name: ​​​​​​​​​​ 2010-10-24 17:20

Name: Anonymous 2011-01-31 18:58

check 'em

Name: Anonymous 2011-01-31 19:19

>>22
oh boy here we go! dubs thread!

Don't change these.
Name: Email:
Entire Thread Thread List