User: Password:
|
|
Subscribe / Log in / New account

C++ Game development

C++ Game development

Posted Dec 10, 2005 8:22 UTC (Sat) by mvogt (guest, #34379)
In reply to: C++ Game development by dvdeug
Parent article: The Boost C++ Libraries

Of course such languages should not be dismissed, but nor should they be espoused for tasks they're not designed for.

Ideally, C++ can be used together with a language designed for embedding (such as Lua) for game development.

That said, games are an unusual domain, where even correctness can be less important than performance or speed-to-market.


(Log in to post comments)

C++ Game development

Posted Dec 10, 2005 8:53 UTC (Sat) by dvdeug (subscriber, #10998) [Link]

Since when is correctness taking second place to performance and speed-to-market unusual? C++ itself puts correctness second to performance in relegating bounded arrays to the library. If you put correctness first, you would use the SPARK programming language, or something similar, and never release unless every possible test has been passed. But in reality, virtually every program releases with known bugs, frequently major ones. Jon Bentley mentions in one of the Programming Pearls books that given a 10x speed improvement on his typesetting system or all the bugs fixed, that he would have taken the speed up. If you (believably) made the offer on the GCC list, I suspect the list would blow up in a flame war over the issue.

C++ Game development

Posted Dec 10, 2005 22:05 UTC (Sat) by mvogt (guest, #34379) [Link]

Fair enough, there are obviously application domains where approximations are acceptable, and those where they are not. What would be the point of a 'grep' that returned most matches, or a 'find' with false positives?

C++ does not put correctness second to performance, it ensures that you needn't pay for what you don't use. (Ignoring legacy C built-in arrays,) if you can guarantee array bounds will not be violated you can use the subscript operator for unchecked access; you can use the 'at' member function to get runtime checking where desirable. 'Relegating... to the library' has been the favoured C++ evolution strategy, for right or wrong. It doesn't indicate that something is less correct or important.

I will admit that C++ puts guranateed correctness second to pragmatism. Languages that don't have not been conspicuously successful in general purpose programming.


Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds