0ad/source/ps
Yves 1a66f510d0 Use const T& for parameters of some types in script-exposed native functions
Using references matches the C++ coding style better and should improve
performance a bit in theory. It avoids 2 copies of T in case of the
functions registered with RegisterFunction (mainy used in the GUI). It
should also avoid one or two copies in case of
DEFINE_INTERFACE_METHOD_X, which is used in the simulation, but I
haven't bothered to count it there exactly.
It is now predefined which types have to be passed by const reference
and which are passed by value. Note that references can't be used as
out-parameters (to return multiple values to JS). This hasn't worked
before either and probably never will.

This was SVN commit r17696.
2016-01-23 15:17:56 +00:00
..
GameSetup Use const T& for parameters of some types in script-exposed native functions 2016-01-23 15:17:56 +00:00
scripting Use const T& for parameters of some types in script-exposed native functions 2016-01-23 15:17:56 +00:00
tests Fixes memory leak in TestPreprocessor. When using CPreprocessor::Parse "you must free() the result string only if the returned address is not inside the source text" 2016-01-23 03:48:00 +00:00
XML Revert emplace for associative containers. Fixes #3366. 2015-08-19 03:32:47 +00:00
ArchiveBuilder.cpp Convert debug_printf to take UTF-8 strings instead of wchar_t. 2015-02-14 01:45:13 +00:00
ArchiveBuilder.h Handle mods specified on the command line when using the archive builder. 2014-06-15 16:43:08 +00:00
CacheLoader.cpp add file notification to Mac ticket 514, also change name of class FileInfo to CFileInfo to ease Mac development 2013-09-10 14:17:04 +00:00
CacheLoader.h Improves CColladaManager caching behavior: skeletons.xml changes now invalidate cached .pmd/psa files, CCacheLoader is used for consistency, adds support for archived files. Fixes #1167. 2012-02-19 03:30:59 +00:00
CConsole.cpp Improve indentation of 'case' statements updated after SDL1 removal (thanks leper). 2015-12-16 15:36:56 +00:00
CConsole.h Clean up some unused variables and assignments. 2015-05-26 15:40:07 +00:00
CLogger.cpp Some range-based for loops and some style cleanup. 2015-07-29 01:07:23 +00:00
CLogger.h CLogger: Use cppformat instead of sys_vswprintf. 2015-01-22 20:30:05 +00:00
Compress.cpp More build fixes for FreeBSD. 2012-01-31 00:06:56 +00:00
Compress.h More FreeBSD build fixes. 2012-01-30 06:21:11 +00:00
ConfigDB.cpp Rework the logics of options loading to allow more flexibility (i.e. adding a min or max value for number inputs) 2016-01-13 22:01:36 +00:00
ConfigDB.h Some range-based for loops and some style cleanup. 2015-07-29 01:07:23 +00:00
CStr.cpp Remove duplicated layers of unescaping which required multiple escapes in some places. 2014-12-13 01:08:29 +00:00
CStr.h Remove duplicated layers of unescaping which required multiple escapes in some places. 2014-12-13 01:08:29 +00:00
CStrIntern.cpp Revert emplace for associative containers. Fixes #3366. 2015-08-19 03:32:47 +00:00
CStrIntern.h Set svn:eol-style=native, fix some inconsistent line endings 2013-12-06 00:42:50 +00:00
CStrInternStatic.h Allow multiple special sprites, to facilitate cases where we want to add an overlay to a sprite. 2015-12-13 16:03:17 +00:00
DllLoader.cpp Automatically replace %hs/%ls with %s in CLogger format strings. 2015-01-22 20:36:24 +00:00
DllLoader.h Add the ability to specify a log level when using dlopen and change it to normal for Atlas. 2014-06-05 17:07:04 +00:00
Errors.cpp # Rewrite of the game's simulation system 2010-01-09 19:20:14 +00:00
Errors.h Catch exceptions by reference (by convention), based on patch from Markus, refs #1852 2013-05-22 22:27:53 +00:00
FileIo.cpp Automatically replace %hs/%ls with %s in CLogger format strings. 2015-01-22 20:36:24 +00:00
FileIo.h Simplify the overly-complex CppDoc-breaking file headers 2009-04-18 17:51:05 +00:00
Filesystem.cpp Use in-place construction. 2015-07-29 23:44:17 +00:00
Filesystem.h Move GUI schemas to the mod mod. Fix some validation related errors in the mod mod. 2015-06-15 16:00:26 +00:00
Game.cpp Fix #3566 by fixing an off-by-one error in the final replay turn logic. Patch by elexis. 2015-11-04 20:33:34 +00:00
Game.h Mark some const functions as such. 2015-09-13 20:59:10 +00:00
Globals.cpp Remove disabled by default SDL1 support. 2015-12-14 10:52:21 +00:00
Globals.h Fixes no PCH build. Fixes #1113. 2012-01-15 21:48:41 +00:00
GUID.cpp Multiplayer lobby based on the XmPP protocol. Special thanks to Philip, alpha123, scythetwirler, and anyone else who has helped build, debug or test the lobby. 2013-11-07 20:07:24 +00:00
GUID.h Multiplayer lobby based on the XmPP protocol. Special thanks to Philip, alpha123, scythetwirler, and anyone else who has helped build, debug or test the lobby. 2013-11-07 20:07:24 +00:00
Hotkey.cpp Cleanup after SDL1 removal. 2015-12-15 08:53:24 +00:00
Hotkey.h Unload hotkeys on shutdown. 2014-09-15 01:27:06 +00:00
Joystick.cpp Remove disabled by default SDL1 support. 2015-12-14 10:52:21 +00:00
Joystick.h Renames our sdl.h to libsdl.h, to avoid case sensitivity errors when it includes SDL.h. 2012-01-12 23:32:27 +00:00
KeyName.cpp Remove disabled by default SDL1 support. 2015-12-14 10:52:21 +00:00
KeyName.h Cleanup after SDL1 removal. 2015-12-15 08:53:24 +00:00
Loader.cpp Convert debug_printf to take UTF-8 strings instead of wchar_t. 2015-02-14 01:45:13 +00:00
Loader.h cleanup (requires update-workspaces) 2011-05-03 12:38:42 +00:00
LoaderThunks.h warning fixes: mostly size_t vs. specialized API type and other type conversion. 2010-09-05 09:38:30 +00:00
Mod.cpp Add engine support to load mods from config and restart into mods. 2014-08-25 16:02:40 +00:00
Mod.h Add engine support to load mods from config and restart into mods. 2014-08-25 16:02:40 +00:00
Preprocessor.cpp Preprocessor: Avoid using "%.*hs" in log format string, since cppformat doesn't support it. 2015-01-22 20:38:16 +00:00
Preprocessor.h Fix CPreprocessor uninitialised data causing error messages on "#endif" followed by EOF with no newline. Warn about unrecognised "#elif". 2012-04-02 16:12:46 +00:00
PreprocessorWrapper.cpp Automatically replace %hs/%ls with %s in CLogger format strings. 2015-01-22 20:36:24 +00:00
PreprocessorWrapper.h Set svn:eol-style=native, fix some inconsistent line endings 2013-12-06 00:42:50 +00:00
Profile.cpp Works around infinite recursion problem. 2014-03-28 11:33:37 +00:00
Profile.h SpiderMonkey 31 upgrade 2015-01-24 14:46:52 +00:00
Profiler2.cpp Automatically replace %hs/%ls with %s in CLogger format strings. 2015-01-22 20:36:24 +00:00
Profiler2.h Some tweaks to profiler2: 2014-09-09 18:17:08 +00:00
Profiler2GPU.cpp Remove useless parameter from CFG_GET_VALUE. 2014-11-17 23:29:49 +00:00
Profiler2GPU.h Fix line endings 2011-11-29 21:04:38 +00:00
ProfileViewer.cpp Some range-based for loops and some style cleanup. 2015-07-29 01:07:23 +00:00
ProfileViewer.h SpiderMonkey 31 upgrade 2015-01-24 14:46:52 +00:00
Pyrogenesis.cpp Update version numbers. Switch lobby room. 2015-11-28 08:27:33 +00:00
Pyrogenesis.h Move engine version to common file. Patch by elexis. Fixes #3359. 2015-08-01 23:03:13 +00:00
Replay.cpp Don't create replays without commands in case of running non-visual replay or an atlas simulation. 2016-01-23 01:02:57 +00:00
Replay.h An awesome Visual Replay menu, made by elexis. Fixes #3258. 2015-09-21 17:00:21 +00:00
SavedGame.cpp Move engine version to common file. Patch by elexis. Fixes #3359. 2015-08-01 23:03:13 +00:00
SavedGame.h SpiderMonkey 31 upgrade 2015-01-24 14:46:52 +00:00
Shapes.cpp Rename ps/Overlay(.h|.cpp) to ps/Shapes(.h|.cpp), fixes a TODO located in graphics/Overlay.h. 2015-03-15 18:06:32 +00:00
Shapes.h Rename ps/Overlay(.h|.cpp) to ps/Shapes(.h|.cpp), fixes a TODO located in graphics/Overlay.h. 2015-03-15 18:06:32 +00:00
Singleton.h split debug_assert into ENSURE and ASSERT as discussed in a previous meeting. 2011-04-30 13:01:45 +00:00
TemplateLoader.cpp Don't comment out code. Refs #3486. 2015-12-07 12:27:52 +00:00
TemplateLoader.h Some const refs and one const function. 2015-07-27 01:08:25 +00:00
ThreadUtil.cpp Add a list of statically-constructed CStrIntern strings 2013-09-29 13:19:52 +00:00
ThreadUtil.h Add initial code annotations for the new profiling tool 2011-11-04 01:35:50 +00:00
TouchInput.cpp Remove disabled by default SDL1 support. 2015-12-14 10:52:21 +00:00
TouchInput.h Set svn:eol-style=native, fix some inconsistent line endings 2013-12-06 00:42:50 +00:00
UniDoubler.h per discussion with Philip, remove STL_HASH_MAP etc. because they're ugly, rarely used and superseded by boost::unordered* 2011-03-23 16:56:27 +00:00
UserReport.cpp Convert debug_printf to take UTF-8 strings instead of wchar_t. 2015-02-14 01:45:13 +00:00
UserReport.h # Add opt-in automatic feedback system. 2011-02-16 20:40:15 +00:00
utf16string.h Fix -Wconversion warnings in simulation code. 2011-08-16 11:18:32 +00:00
Util.cpp Automatically replace %hs/%ls with %s in CLogger format strings. 2015-01-22 20:36:24 +00:00
Util.h cleanup (requires update-workspaces) 2011-05-03 12:38:42 +00:00
VideoMode.cpp Remove disabled by default SDL1 support. 2015-12-14 10:52:21 +00:00
VideoMode.h Fixes some issues when toggling fullscreen mode with SDL2, refs #2041: 2014-09-28 22:10:09 +00:00
VisualReplay.cpp Fix wrong errormessage in case of encountering a broken replay. 2015-12-29 14:00:30 +00:00
VisualReplay.h Replay menu cleanups. Fixes #3440. 2015-12-02 13:53:44 +00:00
World.cpp SpiderMonkey 31 upgrade 2015-01-24 14:46:52 +00:00
World.h SpiderMonkey 31 upgrade 2015-01-24 14:46:52 +00:00