[ros-diffs] [cfinck] 40208: Take the line number as an integer, the STRINGIZER macro didn't work as expected
cfinck at svn.reactos.org
cfinck at svn.reactos.org
Tue Mar 24 13:37:55 CET 2009
Author: cfinck
Date: Tue Mar 24 15:37:54 2009
New Revision: 40208
URL: http://svn.reactos.org/svn/reactos?rev=40208&view=rev
Log:
Take the line number as an integer, the STRINGIZER macro didn't work as expected
Modified:
trunk/rostests/rosautotest/CFatalException.cpp
trunk/rostests/rosautotest/CFatalException.h
trunk/rostests/rosautotest/precomp.h
Modified: trunk/rostests/rosautotest/CFatalException.cpp
URL: http://svn.reactos.org/svn/reactos/trunk/rostests/rosautotest/CFatalException.cpp?rev=40208&r1=40207&r2=40208&view=diff
==============================================================================
--- trunk/rostests/rosautotest/CFatalException.cpp [iso-8859-1] (original)
+++ trunk/rostests/rosautotest/CFatalException.cpp [iso-8859-1] Tue Mar 24 15:37:54 2009
@@ -15,12 +15,12 @@
* Constant pointer to a char array with the source file where the exception occured (__FILE__)
*
* @param Line
- * Constant pointer to a char array with the appropriate source line (#__LINE__)
+ * Integer value with the appropriate source line (__LINE__)
*
* @param Message
* Constant pointer to a char array containing a short message about the exception
*/
-CFatalException::CFatalException(const char* File, const char* Line, const char* Message)
+CFatalException::CFatalException(const char* File, int Line, const char* Message)
: m_File(File), m_Line(Line), m_Message(Message)
{
}
Modified: trunk/rostests/rosautotest/CFatalException.h
URL: http://svn.reactos.org/svn/reactos/trunk/rostests/rosautotest/CFatalException.h?rev=40208&r1=40207&r2=40208&view=diff
==============================================================================
--- trunk/rostests/rosautotest/CFatalException.h [iso-8859-1] (original)
+++ trunk/rostests/rosautotest/CFatalException.h [iso-8859-1] Tue Mar 24 15:37:54 2009
@@ -9,13 +9,13 @@
{
private:
string m_File;
- string m_Line;
+ int m_Line;
string m_Message;
public:
- CFatalException(const char* File, const char* Line, const char* Message);
+ CFatalException(const char* File, int Line, const char* Message);
const string& GetFile() const { return m_File; }
- const string& GetLine() const { return m_Line; }
+ int GetLine() const { return m_Line; }
const string& GetMessage() const { return m_Message; }
};
Modified: trunk/rostests/rosautotest/precomp.h
URL: http://svn.reactos.org/svn/reactos/trunk/rostests/rosautotest/precomp.h?rev=40208&r1=40207&r2=40208&view=diff
==============================================================================
--- trunk/rostests/rosautotest/precomp.h [iso-8859-1] (original)
+++ trunk/rostests/rosautotest/precomp.h [iso-8859-1] Tue Mar 24 15:37:54 2009
@@ -33,9 +33,8 @@
#include "CWineTest.h"
/* Useful macros */
-#define STRINGIZER(Value) #Value
#define EXCEPTION(Message) throw CSimpleException(Message)
-#define FATAL(Message) throw CFatalException(__FILE__, STRINGIZER(__LINE__), Message)
+#define FATAL(Message) throw CFatalException(__FILE__, __LINE__, Message)
#define SSEXCEPTION throw CSimpleException(ss.str().c_str())
/* main.c */
More information about the Ros-diffs
mailing list