From the draft of the next C++ standard, n2798, 1.9 [intro.execution]/16:
If a side effect on a scalar object is unsequenced relative to either another side effect on the same scalar object or a value computation using the value of the same scalar object, the behavior is undefined.
Since the built-in == operator doesn't have a sequence point between its argument, the side effect of c++ is unsequenced relative to the value computation of c on the left hand side of the ==, and thus the behaviour is undefined.
Also you find in the latest public draft of the 1998 C++ standard, CD2, 5 [expr]/4:
Between the previous and next sequence point a scalar object shall have its stored value modified at most once by the evaluation of an expression. Furthermore, the prior value shall be accessed only to determine the value to be stored.
Note that in c == c++, on the LHS the prior value of c is accessed not in order to determine the new value, but only to compare it with the result of the right hand side. Therefore it was undefined in C++ even back then. I don't have access to any version (draft or otherwise) of the C standard, but I think it's undefined in C, too (although the exact wording probably is different again).
Historically speaking, there haven't been any useful Microsoft technologies that were or are completely interoperable, stable, relatively bugfree, and secure.
C isn't the slightest bit more performant than C++. Everything you can do in C, you can do in C++ with exactly the same performance (often even by using exactly the same code). However, in C++ you can restrict that low-level stuff to those tiny parts of your application where ultimate performance matters, and use higher level stuff everywhere else. Not that always higher-level stuff is less performant anyway; unless you have a very good optimizer for C, I'd bet that an optimal C++ std::sort implementation consistently beats an optimal C qsort implementation, despite being higher level (no messing with void*).
Both C++ inheritance and C++ templates allow that, too (with both methods having different trade-offs). But static typing will still check that you file-like object indeed supports everything needed, even if it is used only by some deeply nested function under extremely obscure circumstances which you happen to never hit with your test suite.
Assuming you have written a streambuf class (say it's named httpbuf) for accessing web pages (or found a pre-written one), you can just use a normal filebuf for testing (or you can even test on program-internal data by using a stringbuf), and using httpbuf for the actual code. The only point Python might have here is that it might already come with the class needed to read web pages, while C++ doesn't provide that out of the box. But that's of course completely orthogonal to the question of static typing.
I guess most anti-static typing people think of static typing as it was in original Pascal. But developmment didn't stop there (and even Pascal implementations provided more than that more than ten years ago).
If you are going to plug in an external mouse anyway, then why use a crippled two-button one instead of a reasonable three-button or even scroll-wheel mouse?
It's not on the list, because part of what is nethack also comes from subtle and not-so-subtle references to hacker culture (e.g. "a scroll named HACKEM MUCHE"). Also, will an automatic program ever get the idea to include features like recieving your (real) mail from inside the game (as a "scroll of mail")? I strongly doubt so. Even the idea that you can find your own grave from an earlier unsuccessful playing in a later game session is something very unlikely to be invented by a program.
The point is, much of the fun is in such details which cannot be created by a simple optimization process, but have to be invented through creativity and cultural knowledge.
Moreover, even if you concentrate just on the game mechanics, a computer couldn't create anything like nethack without providing extensive information. That's because the various numbers mean something. Simply making arbitrary rules simply will not give a consistent experience. A shop keeper will never give you money if you buy something. You cannot find a negative amount of money. A monster hitting you will never increase your hit points. Such rules are obvious when you know the meaning of the points, but how would a computer figure this out? The result of making those rules arbitrary would just result in rules which seem as arbitrary as they are, and therefore much reduced fun.
... will he eventually reach nethack? After all, it's also basically things moving around (you, your pet, monsters, etc.), and actions on getting together (fighting with monsters, picking up things,...). Ok, it has a third dimension (stair up/down) and a few other degrees of freedom (e.g. additional actions like casting spells or putting on/removing rings) and a few more parameters than just one score, but I'm sure you can generalize the description enough to be able to describe nethack.
But somehow I doubt that he'll create a new nethack this way.
But how do you read Slashdot without a computer?:-)
Re:I'm not a copyright lawyer
on
Qt Becomes LGPL
·
· Score: 1
If you have a piece of GPL code in your program, all of the program must be GPL. LGPL only applies to the LGPL code and any changes you make to it (your original code can be under any license)
Not any license. For example, if the license specifically says that the code may not be linked with LGPLed code, you certainly cannot link it (legally) with LGPLed code. More likely, if the license is a GPL-like "you must license the whole code under this", but contains any clause incompatible with the LGPL, then you cannot link to LGPLed code, because then both licenses would conflict.
If a bank trusts a spreadsheet based on a bad formula that is provided by the bank itself, is it the spreadsheet's fault?
Of course. A good spreadsheet would have invoked its mind reading module to find out what the formula is supposed to do, then consulted its extensive database of everything known to man to find out the rules, then the logic thinking module to check the formula, and finally the psychology module to determine how to successfully tell the writer of that formula that he f*cked it up.
First, write a specification for the perl 5 language.
Simple: A program is well-formed Perl 5, if the Perl v5.10.0 interpreter doesn't give you any error for it. The semantics of a Perl 5 program is defined by the behaviour exhibited when run on the Perl v5.10.0 interpreter.:-)
Won't anyone please think of the child processes?
... speaking words of wisdom: Let it crash ...
From the draft of the next C++ standard, n2798, 1.9 [intro.execution]/16:
Since the built-in == operator doesn't have a sequence point between its argument, the side effect of c++ is unsequenced relative to the value computation of c on the left hand side of the ==, and thus the behaviour is undefined.
Also you find in the latest public draft of the 1998 C++ standard, CD2, 5 [expr]/4:
Note that in c == c++, on the LHS the prior value of c is accessed not in order to determine the new value, but only to compare it with the result of the right hand side. Therefore it was undefined in C++ even back then. I don't have access to any version (draft or otherwise) of the C standard, but I think it's undefined in C, too (although the exact wording probably is different again).
Historically speaking, there haven't been any useful Microsoft technologies that were or are completely interoperable, stable, relatively bugfree, and secure.
Hey stupid, ever heard of the INTERNET?!
The internet is secure?
C isn't the slightest bit more performant than C++. Everything you can do in C, you can do in C++ with exactly the same performance (often even by using exactly the same code). However, in C++ you can restrict that low-level stuff to those tiny parts of your application where ultimate performance matters, and use higher level stuff everywhere else. Not that always higher-level stuff is less performant anyway; unless you have a very good optimizer for C, I'd bet that an optimal C++ std::sort implementation consistently beats an optimal C qsort implementation, despite being higher level (no messing with void*).
Yes ... but will it arrive before Hurd 1.0?
Of course you can write Facebook in ASM. It's just a lot of work (and you'll be bound to the platform you've chosen forever).
Both C++ inheritance and C++ templates allow that, too (with both methods having different trade-offs). But static typing will still check that you file-like object indeed supports everything needed, even if it is used only by some deeply nested function under extremely obscure circumstances which you happen to never hit with your test suite.
Assuming you have written a streambuf class (say it's named httpbuf) for accessing web pages (or found a pre-written one), you can just use a normal filebuf for testing (or you can even test on program-internal data by using a stringbuf), and using httpbuf for the actual code. The only point Python might have here is that it might already come with the class needed to read web pages, while C++ doesn't provide that out of the box. But that's of course completely orthogonal to the question of static typing.
I guess most anti-static typing people think of static typing as it was in original Pascal. But developmment didn't stop there (and even Pascal implementations provided more than that more than ten years ago).
Which it shouldn't, as C, C# and C++ seem pretty distinct.
And what about Objective-C?
And what about Objective C++? And C++/CLI?
BTW, when will we get Objective-C++/CLI? :-)
Can you also do things like middle-drag?
If you are going to plug in an external mouse anyway, then why use a crippled two-button one instead of a reasonable three-button or even scroll-wheel mouse?
It's not on the list, because part of what is nethack also comes from subtle and not-so-subtle references to hacker culture (e.g. "a scroll named HACKEM MUCHE"). Also, will an automatic program ever get the idea to include features like recieving your (real) mail from inside the game (as a "scroll of mail")? I strongly doubt so. Even the idea that you can find your own grave from an earlier unsuccessful playing in a later game session is something very unlikely to be invented by a program.
The point is, much of the fun is in such details which cannot be created by a simple optimization process, but have to be invented through creativity and cultural knowledge.
Moreover, even if you concentrate just on the game mechanics, a computer couldn't create anything like nethack without providing extensive information. That's because the various numbers mean something. Simply making arbitrary rules simply will not give a consistent experience. A shop keeper will never give you money if you buy something. You cannot find a negative amount of money. A monster hitting you will never increase your hit points. Such rules are obvious when you know the meaning of the points, but how would a computer figure this out? The result of making those rules arbitrary would just result in rules which seem as arbitrary as they are, and therefore much reduced fun.
Novell is one or two nerds in a basement together?
Nethack.
... will he eventually reach nethack? After all, it's also basically things moving around (you, your pet, monsters, etc.), and actions on getting together (fighting with monsters, picking up things, ...). Ok, it has a third dimension (stair up/down) and a few other degrees of freedom (e.g. additional actions like casting spells or putting on/removing rings) and a few more parameters than just one score, but I'm sure you can generalize the description enough to be able to describe nethack.
But somehow I doubt that he'll create a new nethack this way.
But how do you read Slashdot without a computer? :-)
Not any license. For example, if the license specifically says that the code may not be linked with LGPLed code, you certainly cannot link it (legally) with LGPLed code. More likely, if the license is a GPL-like "you must license the whole code under this", but contains any clause incompatible with the LGPL, then you cannot link to LGPLed code, because then both licenses would conflict.
Of course. A good spreadsheet would have invoked its mind reading module to find out what the formula is supposed to do, then consulted its extensive database of everything known to man to find out the rules, then the logic thinking module to check the formula, and finally the psychology module to determine how to successfully tell the writer of that formula that he f*cked it up.
Sorry, your program hard-coded the path of perl. That disqualified it. I'm going to get the $500 instead with the following masterpiece:
SCNR
No, you'll see, Duke Nukem Forever will be written in Perl 6, at least the Hurd version.
4 is the smallest composite number.
BTW, are you a numeric co-processor? :-)
Simple: A program is well-formed Perl 5, if the Perl v5.10.0 interpreter doesn't give you any error for it. The semantics of a Perl 5 program is defined by the behaviour exhibited when run on the Perl v5.10.0 interpreter. :-)
If the world wide economy has been destroyed, that capital will be worth exacly nothing.
So maybe Dell thought that if there are so many Poles working in their Irish factory, they can as well relocate that to Poland anyway ...
I didn't know George W. was reading Douglas Adams.