C++ string literals may be simple arrays of characters, but the Standard Library provides a lot of support on top of that. From a
string class to regular expressions, we have a full set of tools to deal with strings in a wide variety of ways.
Posts Tagged regular expression
I was reminded about the flash.sampler API by Grant Skinner’s recent post about it. While only available in the debug player, it can still tell us some valuable information about what goes on in the release player. Today I’m using the getSize function to find out how much memory overhead various classes impose, even when they are empty.
Lately I’ve been seeing a lot of AS3 code that uses regular expressions where the normal methods of the String class would seem to suffice. It seems common among programmers of all languages to catch on to new trends even when they do not particularly apply to the task at hand. For example, a new C++ or Java programmer may use templates or generics even for classes where only one data type will likely ever be used. I don’t know why programmers do this and I won’t attempt to tackle such a topic. Instead, I’ll do a test to show why this is a bad idea from a performance perspective.