Patch #1112 2006-06-08 21:22

sethjackson

Bug #7640
Download
1112-Bug_7640_.patch (486 bytes)
Category
Application::Bugfix
Status
Accepted
Close date
2006-06-09 13:45
Assigned to
 
Index: trunk/src/sdk/compiler.cpp
===================================================================
--- trunk/src/sdk/compiler.cpp    (revision 2539)
+++ trunk/src/sdk/compiler.cpp    (working copy)
@@ -125,9 +125,9 @@
     }
 
     // make sure it's not starting with a number.
-    // if it is, prepend an underscore
+    // if it is, prepend "cb"
     if (wxIsdigit(newID.GetChar(0)))
-        newID.Prepend(_T('_'));
+        newID.Prepend(_T("cb"));
 
     if (newID.IsEmpty())
     {
sethjackson 2006-06-08 21:22
sethjackson 2006-06-09 01:57

While it is technically it is ok to start an XML node with '_' C::B throws an exception, when you do so. You could fix configmanager.cpp around line 548 (the if statement above that line) to allow a node to start with '_'. Anyways IMO it is bad form to start an XML node with '_'. :)