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

Dungeons and Dragons

Name: Anonymous 2009-10-06 17:29

Lets compare D&D classes with popular programming languages.
(#1 most nerdy thread ever)

Fighter - C++
-Very versatile but more complex and not quite as effective in melee as a barbarian.

Barbarian - C
-Very simple, very powerful.

Ranger - Java
-Easy to play, very popular, vast collection of abilities that help solve problems quickly.

Wizard - Lisp/Scheme
-Most powerful caster, highest intelligence.

Sorcerer - Haskell
-Slightly less intelligent than a wizard, but makes up for it in charisma.

Rogue - Scripting Languages
-Executes behind your back.

Cleric - SQL
-Revives players when they crash.
 
Paladin - Python
-Easiest to play, but forces you to play a certain way.

Name: Anonymous 2009-10-07 23:01

>>74
Why do people care so much about recompiling? And what does recompiling have to do with language semantics anyway?

Encapsulating stuff like member variables and the vtable is certainly possible in C++. You just provide a pure virtual interface, and have factory methods that return instances of it. If you want to add virtual methods, just subclass the old interface with a new interface that adds the methods you want. That way old code still works, and new code uses the new interface (and new factory function). This is not just a hack; according to some, this is the proper way to design large, scalable applications.

The reason people don't do it though is because it entails dynamic runtime function calling for everything. All that function call indirection is very costly. This runs directly counter to *speed*, which is one of the main reasons programs are written in C++ at all rather than higher level languages. Design arguments for this paradigm are largely academic and just don't relate to the real world.

If I have to recompile my app to use a newer version of a library where a class's private variables have changed, so be it. I'll gladly trade that for the speed it needs to be fast and responsive to the user.

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