فهرست منبع

remove tab characters

David Rose 24 سال پیش
والد
کامیت
fcb24f02ef
100فایلهای تغییر یافته به همراه1710 افزوده شده و 1710 حذف شده
  1. 7 7
      direct/src/dcparser/dcAtomicField.cxx
  2. 1 1
      direct/src/dcparser/dcAtomicField.h
  3. 1 1
      direct/src/dcparser/dcClass.h
  4. 1 1
      direct/src/dcparser/dcField.h
  5. 1 1
      direct/src/dcparser/dcFile.h
  6. 1 1
      direct/src/dcparser/dcLexer.lxx
  7. 1 1
      direct/src/dcparser/dcMolecularField.h
  8. 90 90
      direct/src/dcparser/dcParser.yxx
  9. 1 1
      direct/src/dcparser/dcSubatomicType.h
  10. 1 1
      direct/src/dcparser/hashGenerator.h
  11. 2 2
      direct/src/dcparser/primeNumberGenerator.cxx
  12. 1 1
      direct/src/dcparser/primeNumberGenerator.h
  13. 3 3
      direct/src/deadrec/correction.cxx
  14. 7 7
      direct/src/showbase/showBase.cxx
  15. 4 4
      direct/src/showbase/showBase.h
  16. 4 4
      dtool/src/cppparser/cppArrayType.cxx
  17. 8 8
      dtool/src/cppparser/cppArrayType.h
  18. 219 219
      dtool/src/cppparser/cppBison.yxx
  19. 4 4
      dtool/src/cppparser/cppBisonDefs.h
  20. 3 3
      dtool/src/cppparser/cppClassTemplateParameter.h
  21. 1 1
      dtool/src/cppparser/cppCommentBlock.h
  22. 4 4
      dtool/src/cppparser/cppConstType.cxx
  23. 8 8
      dtool/src/cppparser/cppConstType.h
  24. 2 2
      dtool/src/cppparser/cppDeclaration.cxx
  25. 6 6
      dtool/src/cppparser/cppDeclaration.h
  26. 4 4
      dtool/src/cppparser/cppEnumType.cxx
  27. 6 6
      dtool/src/cppparser/cppEnumType.h
  28. 95 95
      dtool/src/cppparser/cppExpression.cxx
  29. 5 5
      dtool/src/cppparser/cppExpression.h
  30. 1 1
      dtool/src/cppparser/cppExpressionParser.h
  31. 3 3
      dtool/src/cppparser/cppExtensionType.cxx
  32. 5 5
      dtool/src/cppparser/cppExtensionType.h
  33. 4 4
      dtool/src/cppparser/cppFile.cxx
  34. 3 3
      dtool/src/cppparser/cppFile.h
  35. 1 1
      dtool/src/cppparser/cppFunctionGroup.cxx
  36. 2 2
      dtool/src/cppparser/cppFunctionGroup.h
  37. 8 8
      dtool/src/cppparser/cppFunctionType.cxx
  38. 14 14
      dtool/src/cppparser/cppFunctionType.h
  39. 46 46
      dtool/src/cppparser/cppIdentifier.cxx
  40. 16 16
      dtool/src/cppparser/cppIdentifier.h
  41. 19 19
      dtool/src/cppparser/cppInstance.cxx
  42. 10 10
      dtool/src/cppparser/cppInstance.h
  43. 8 8
      dtool/src/cppparser/cppInstanceIdentifier.cxx
  44. 2 2
      dtool/src/cppparser/cppInstanceIdentifier.h
  45. 16 16
      dtool/src/cppparser/cppManifest.cxx
  46. 3 3
      dtool/src/cppparser/cppManifest.h
  47. 3 3
      dtool/src/cppparser/cppNamespace.h
  48. 7 7
      dtool/src/cppparser/cppParameterList.cxx
  49. 5 5
      dtool/src/cppparser/cppParameterList.h
  50. 1 1
      dtool/src/cppparser/cppParser.h
  51. 4 4
      dtool/src/cppparser/cppPointerType.cxx
  52. 8 8
      dtool/src/cppparser/cppPointerType.h
  53. 246 246
      dtool/src/cppparser/cppPreprocessor.cxx
  54. 15 15
      dtool/src/cppparser/cppPreprocessor.h
  55. 4 4
      dtool/src/cppparser/cppReferenceType.cxx
  56. 8 8
      dtool/src/cppparser/cppReferenceType.h
  57. 93 93
      dtool/src/cppparser/cppScope.cxx
  58. 18 18
      dtool/src/cppparser/cppScope.h
  59. 2 2
      dtool/src/cppparser/cppSimpleType.h
  60. 60 60
      dtool/src/cppparser/cppStructType.cxx
  61. 9 9
      dtool/src/cppparser/cppStructType.h
  62. 1 1
      dtool/src/cppparser/cppTBDType.cxx
  63. 5 5
      dtool/src/cppparser/cppTBDType.h
  64. 20 20
      dtool/src/cppparser/cppTemplateParameterList.cxx
  65. 6 6
      dtool/src/cppparser/cppTemplateParameterList.h
  66. 3 3
      dtool/src/cppparser/cppTemplateScope.cxx
  67. 4 4
      dtool/src/cppparser/cppTemplateScope.h
  68. 2 2
      dtool/src/cppparser/cppToken.cxx
  69. 4 4
      dtool/src/cppparser/cppToken.h
  70. 2 2
      dtool/src/cppparser/cppType.cxx
  71. 6 6
      dtool/src/cppparser/cppType.h
  72. 1 1
      dtool/src/cppparser/cppTypeDeclaration.cxx
  73. 4 4
      dtool/src/cppparser/cppTypeDeclaration.h
  74. 1 1
      dtool/src/cppparser/cppTypeParser.h
  75. 3 3
      dtool/src/cppparser/cppTypeProxy.cxx
  76. 6 6
      dtool/src/cppparser/cppTypeProxy.h
  77. 1 1
      dtool/src/cppparser/cppTypedef.cxx
  78. 4 4
      dtool/src/cppparser/cppTypedef.h
  79. 2 2
      dtool/src/cppparser/cppUsing.h
  80. 268 268
      dtool/src/dconfig/configTable.cxx
  81. 1 1
      dtool/src/dconfig/configTable.h
  82. 37 37
      dtool/src/dconfig/dconfig.h
  83. 14 14
      dtool/src/dconfig/notify.cxx
  84. 5 5
      dtool/src/dconfig/notify.h
  85. 12 12
      dtool/src/dconfig/notifyCategory.cxx
  86. 2 2
      dtool/src/dconfig/notifyCategory.h
  87. 1 1
      dtool/src/dconfig/notifyCategoryProxy.h
  88. 73 73
      dtool/src/dconfig/serialization.h
  89. 3 3
      dtool/src/dconfig/symbolEnt.h
  90. 1 1
      dtool/src/dconfig/test_pfstream.cxx
  91. 2 2
      dtool/src/dconfig/test_serialization.cxx
  92. 10 10
      dtool/src/dtoolbase/version.h
  93. 1 1
      dtool/src/dtoolutil/dSearchPath.I
  94. 2 2
      dtool/src/dtoolutil/dSearchPath.cxx
  95. 3 3
      dtool/src/dtoolutil/dSearchPath.h
  96. 13 13
      dtool/src/dtoolutil/executionEnvironment.cxx
  97. 1 1
      dtool/src/dtoolutil/executionEnvironment.h
  98. 29 29
      dtool/src/dtoolutil/filename.cxx
  99. 6 6
      dtool/src/dtoolutil/filename.h
  100. 16 16
      dtool/src/dtoolutil/gnu_getopt.h

+ 7 - 7
direct/src/dcparser/dcAtomicField.cxx

@@ -158,9 +158,9 @@ end_array() {
       // prepend the array length.
       // prepend the array length.
       int length = _default_value.length();
       int length = _default_value.length();
       _default_value = 
       _default_value = 
-	string(1, (char)(length & 0xff)) +
-	string(1, (char)((length >> 8) & 0xff)) +
-	_default_value;
+        string(1, (char)(length & 0xff)) +
+        string(1, (char)((length >> 8) & 0xff)) +
+        _default_value;
     }
     }
     return true;
     return true;
     
     
@@ -242,7 +242,7 @@ format_default_value(double num, string &formatted) const {
 
 
       int length = str.length();
       int length = str.length();
       for (size_t i = 0; i < 8; i++) {
       for (size_t i = 0; i < 8; i++) {
-	str += formatted[length - 1 - i];
+        str += formatted[length - 1 - i];
       }
       }
       formatted = str;
       formatted = str;
     }
     }
@@ -277,9 +277,9 @@ format_default_value(const string &str, string &formatted) const {
     {
     {
       int length = str.length();
       int length = str.length();
       formatted = 
       formatted = 
-	string(1, (char)(length & 0xff)) +
-	string(1, (char)((length >> 8) & 0xff)) +
-	str;
+        string(1, (char)(length & 0xff)) +
+        string(1, (char)((length >> 8) & 0xff)) +
+        str;
     }
     }
     break;
     break;
 
 

+ 1 - 1
direct/src/dcparser/dcAtomicField.h

@@ -13,7 +13,7 @@
 #include <vector>
 #include <vector>
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : DCAtomicField
+//       Class : DCAtomicField
 // Description : A single atomic field of a Distributed Class, as read
 // Description : A single atomic field of a Distributed Class, as read
 //               from a .dc file.  This defines an interface to the
 //               from a .dc file.  This defines an interface to the
 //               Distributed Class, and is always implemented as a
 //               Distributed Class, and is always implemented as a

+ 1 - 1
direct/src/dcparser/dcClass.h

@@ -15,7 +15,7 @@
 class HashGenerator;
 class HashGenerator;
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : DCClass
+//       Class : DCClass
 // Description : Defines a particular DistributedClass as read from an
 // Description : Defines a particular DistributedClass as read from an
 //               input .dc file.
 //               input .dc file.
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 1 - 1
direct/src/dcparser/dcField.h

@@ -13,7 +13,7 @@ class DCMolecularField;
 class HashGenerator;
 class HashGenerator;
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : DCField
+//       Class : DCField
 // Description : A single field of a Distributed Class, either atomic
 // Description : A single field of a Distributed Class, either atomic
 //               or molecular.
 //               or molecular.
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 1 - 1
direct/src/dcparser/dcFile.h

@@ -15,7 +15,7 @@
 class HashGenerator;
 class HashGenerator;
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : DCFile
+//       Class : DCFile
 // Description : Represents the complete list of Distributed Class
 // Description : Represents the complete list of Distributed Class
 //               descriptions as read from a .dc file.
 //               descriptions as read from a .dc file.
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 1 - 1
direct/src/dcparser/dcLexer.lxx

@@ -126,7 +126,7 @@ input_chars(char *buffer, int &result, int max_size) {
       // Truncate it at the newline.
       // Truncate it at the newline.
       char *end = strchr(current_line, '\n');
       char *end = strchr(current_line, '\n');
       if (end != NULL) {
       if (end != NULL) {
-	*end = '\0';
+        *end = '\0';
       }
       }
     }
     }
 
 

+ 1 - 1
direct/src/dcparser/dcMolecularField.h

@@ -14,7 +14,7 @@
 class DCAtomicField;
 class DCAtomicField;
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : DCMolecularField
+//       Class : DCMolecularField
 // Description : A single molecular field of a Distributed Class, as
 // Description : A single molecular field of a Distributed Class, as
 //               read from a .dc file.  This represents a combination
 //               read from a .dc file.  This represents a combination
 //               of two or more related atomic fields, that will often
 //               of two or more related atomic fields, that will often

+ 90 - 90
direct/src/dcparser/dcParser.yxx

@@ -82,13 +82,13 @@ dc_cleanup_parser() {
 %%
 %%
 
 
 dc:
 dc:
-	empty
-	| dc ';'
-	| dc dclass
-	;
+        empty
+        | dc ';'
+        | dc dclass
+        ;
 
 
 dclass:
 dclass:
-	KW_DCLASS IDENTIFIER 
+        KW_DCLASS IDENTIFIER 
 {
 {
   current_class = new DCClass;
   current_class = new DCClass;
   current_class->_name = $2;
   current_class->_name = $2;
@@ -96,11 +96,11 @@ dclass:
     yyerror("Duplicate class name: " + current_class->_name);
     yyerror("Duplicate class name: " + current_class->_name);
   }
   }
 }
 }
-	dclass_derivation '{' dclass_fields '}'
-	;
+        dclass_derivation '{' dclass_fields '}'
+        ;
 
 
 dclass_name:
 dclass_name:
-	IDENTIFIER
+        IDENTIFIER
 {
 {
   DCFile::ClassesByName::const_iterator ni;
   DCFile::ClassesByName::const_iterator ni;
   ni = dc_file->_classes_by_name.find($1);
   ni = dc_file->_classes_by_name.find($1);
@@ -113,34 +113,34 @@ dclass_name:
 }
 }
 
 
 dclass_derivation:
 dclass_derivation:
-	empty
-	| ':' base_list
-	;
+        empty
+        | ':' base_list
+        ;
 
 
 base_list:
 base_list:
-	dclass_name
+        dclass_name
 {
 {
   if ($1 != (DCClass *)NULL) {
   if ($1 != (DCClass *)NULL) {
     current_class->_parents.push_back($1);
     current_class->_parents.push_back($1);
   }
   }
 }
 }
-	| base_list ',' dclass_name
+        | base_list ',' dclass_name
 {
 {
   if ($3 != (DCClass *)NULL) {
   if ($3 != (DCClass *)NULL) {
     current_class->_parents.push_back($3);
     current_class->_parents.push_back($3);
   }
   }
 }
 }
-	;
+        ;
 
 
 dclass_fields:
 dclass_fields:
-	empty
-	| dclass_fields ';'
-	| dclass_fields atomic_field
-	| dclass_fields molecular_field
-	;
+        empty
+        | dclass_fields ';'
+        | dclass_fields atomic_field
+        | dclass_fields molecular_field
+        ;
 
 
 atomic_field:
 atomic_field:
-	IDENTIFIER '('
+        IDENTIFIER '('
 {
 {
   current_atomic = new DCAtomicField;
   current_atomic = new DCAtomicField;
   current_atomic->_name = $1;
   current_atomic->_name = $1;
@@ -148,11 +148,11 @@ atomic_field:
     yyerror("Duplicate field name: " + current_atomic->_name);
     yyerror("Duplicate field name: " + current_atomic->_name);
   }
   }
 }
 }
-	parameter_list ')' atomic_flags
-	;
+        parameter_list ')' atomic_flags
+        ;
 
 
 atomic_name:
 atomic_name:
-	IDENTIFIER
+        IDENTIFIER
 {
 {
   DCField *field = current_class->get_field_by_name($1);
   DCField *field = current_class->get_field_by_name($1);
   $$ = (DCAtomicField *)NULL;
   $$ = (DCAtomicField *)NULL;
@@ -167,60 +167,60 @@ atomic_name:
 }
 }
 
 
 parameter_list:
 parameter_list:
-	empty
-	| nonempty_parameter_list
-	;
+        empty
+        | nonempty_parameter_list
+        ;
 
 
 nonempty_parameter_list:
 nonempty_parameter_list:
-	atomic_element
-	| nonempty_parameter_list ',' atomic_element
-	;
+        atomic_element
+        | nonempty_parameter_list ',' atomic_element
+        ;
 
 
 atomic_element:
 atomic_element:
-	type_token 
+        type_token 
 {
 {
   atomic_element = DCAtomicField::ElementType();
   atomic_element = DCAtomicField::ElementType();
   atomic_element._type = $1;
   atomic_element._type = $1;
 }
 }
-	atomic_element_definition
+        atomic_element_definition
 {
 {
   current_atomic->_elements.push_back(atomic_element)
   current_atomic->_elements.push_back(atomic_element)
 }
 }
-	;
+        ;
 
 
 atomic_element_definition:
 atomic_element_definition:
-	empty
-	| atomic_element_definition '/' INTEGER
+        empty
+        | atomic_element_definition '/' INTEGER
 {
 {
   atomic_element._divisor = $3;
   atomic_element._divisor = $3;
 }
 }
-	| atomic_element_definition IDENTIFIER
+        | atomic_element_definition IDENTIFIER
 {
 {
   atomic_element._name = $2;
   atomic_element._name = $2;
 }
 }
-	| atomic_element_definition '=' INTEGER
+        | atomic_element_definition '=' INTEGER
 {
 {
   if (!atomic_element.set_default_value($3)) {
   if (!atomic_element.set_default_value($3)) {
     yyerror("Invalid default value: " + $<str>3);
     yyerror("Invalid default value: " + $<str>3);
   }
   }
 }
 }
-	| atomic_element_definition '=' REAL
+        | atomic_element_definition '=' REAL
 {
 {
   if (!atomic_element.set_default_value($3)) {
   if (!atomic_element.set_default_value($3)) {
     yyerror("Invalid default value: " + $<str>3);
     yyerror("Invalid default value: " + $<str>3);
   }
   }
 }
 }
-	| atomic_element_definition '=' STRING
+        | atomic_element_definition '=' STRING
 {
 {
   if (!atomic_element.set_default_value($3)) {
   if (!atomic_element.set_default_value($3)) {
     yyerror("Invalid default value: \"" + $3 + "\"");
     yyerror("Invalid default value: \"" + $3 + "\"");
   }
   }
 }
 }
-	| atomic_element_definition '=' HEX_STRING
+        | atomic_element_definition '=' HEX_STRING
 {
 {
   atomic_element.set_default_value($3);
   atomic_element.set_default_value($3);
 }
 }
-	| atomic_element_definition '=' '{' default_array '}'
+        | atomic_element_definition '=' '{' default_array '}'
 {
 {
   if (!atomic_element.end_array()) {
   if (!atomic_element.end_array()) {
     yyerror("Array default value inappropriate");
     yyerror("Array default value inappropriate");
@@ -228,37 +228,37 @@ atomic_element_definition:
     atomic_element._has_default_value = true;
     atomic_element._has_default_value = true;
   }
   }
 }
 }
-	;
+        ;
 
 
 default_array:
 default_array:
-	empty
-	| default_array_def maybe_comma
-	;
+        empty
+        | default_array_def maybe_comma
+        ;
 
 
 maybe_comma:
 maybe_comma:
-	empty
-	| ','
-	;
+        empty
+        | ','
+        ;
 
 
 default_array_def:
 default_array_def:
-	default_array_element
-	| default_array_def ',' default_array_element
-	;
+        default_array_element
+        | default_array_def ',' default_array_element
+        ;
 
 
 default_array_element:
 default_array_element:
-	INTEGER
+        INTEGER
 {
 {
   if (!atomic_element.add_default_value($1)) {
   if (!atomic_element.add_default_value($1)) {
     yyerror("Invalid default value: " + $<str>1);
     yyerror("Invalid default value: " + $<str>1);
   }
   }
 }
 }
-	| REAL
+        | REAL
 {
 {
   if (!atomic_element.add_default_value($1)) {
   if (!atomic_element.add_default_value($1)) {
     yyerror("Invalid default value: " + $<str>1);
     yyerror("Invalid default value: " + $<str>1);
   }
   }
 }
 }
-	| INTEGER '*' INTEGER
+        | INTEGER '*' INTEGER
 {
 {
   for (int i = 0; i < $3; i++) {
   for (int i = 0; i < $3; i++) {
     if (!atomic_element.add_default_value($1)) {
     if (!atomic_element.add_default_value($1)) {
@@ -267,7 +267,7 @@ default_array_element:
     }
     }
   }
   }
 }
 }
-	| REAL '*' INTEGER
+        | REAL '*' INTEGER
 {
 {
   for (int i = 0; i < $3; i++) {
   for (int i = 0; i < $3; i++) {
     if (!atomic_element.add_default_value($1)) {
     if (!atomic_element.add_default_value($1)) {
@@ -276,109 +276,109 @@ default_array_element:
     }
     }
   }
   }
 }
 }
-	;  
+        ;  
 
 
 type_token:
 type_token:
-	KW_INT8
+        KW_INT8
 {
 {
   $$ = ST_int8;
   $$ = ST_int8;
 }
 }
-	| KW_INT16
+        | KW_INT16
 {
 {
   $$ = ST_int16;
   $$ = ST_int16;
 }
 }
-	| KW_INT32
+        | KW_INT32
 {
 {
   $$ = ST_int32;
   $$ = ST_int32;
 }
 }
-	| KW_INT64
+        | KW_INT64
 {
 {
   $$ = ST_int64;
   $$ = ST_int64;
 }
 }
-	| KW_UINT8
+        | KW_UINT8
 {
 {
   $$ = ST_uint8;
   $$ = ST_uint8;
 }
 }
-	| KW_UINT16
+        | KW_UINT16
 {
 {
   $$ = ST_uint16;
   $$ = ST_uint16;
 }
 }
-	| KW_UINT32
+        | KW_UINT32
 {
 {
   $$ = ST_uint32;
   $$ = ST_uint32;
 }
 }
-	| KW_UINT64
+        | KW_UINT64
 {
 {
   $$ = ST_uint64;
   $$ = ST_uint64;
 }
 }
-	| KW_FLOAT64
+        | KW_FLOAT64
 {
 {
   $$ = ST_float64;
   $$ = ST_float64;
 }
 }
-	| KW_STRING
+        | KW_STRING
 {
 {
   $$ = ST_string;
   $$ = ST_string;
 }
 }
-	| KW_BLOB
+        | KW_BLOB
 {
 {
   $$ = ST_blob;
   $$ = ST_blob;
 }
 }
-	| KW_INT16ARRAY
+        | KW_INT16ARRAY
 {
 {
   $$ = ST_int16array;
   $$ = ST_int16array;
 }
 }
-	| KW_INT32ARRAY
+        | KW_INT32ARRAY
 {
 {
   $$ = ST_int32array;
   $$ = ST_int32array;
 }
 }
-	| KW_UINT16ARRAY
+        | KW_UINT16ARRAY
 {
 {
   $$ = ST_uint16array;
   $$ = ST_uint16array;
 }
 }
-	| KW_UINT32ARRAY
+        | KW_UINT32ARRAY
 {
 {
   $$ = ST_uint32array;
   $$ = ST_uint32array;
 }
 }
-	;
+        ;
 
 
 atomic_flags:
 atomic_flags:
-	empty
-	| atomic_flags KW_REQUIRED
+        empty
+        | atomic_flags KW_REQUIRED
 {
 {
   current_atomic->_flags |= DCAtomicField::F_required;
   current_atomic->_flags |= DCAtomicField::F_required;
 }
 }
-	| atomic_flags KW_BROADCAST
+        | atomic_flags KW_BROADCAST
 {
 {
   current_atomic->_flags |= DCAtomicField::F_broadcast;
   current_atomic->_flags |= DCAtomicField::F_broadcast;
 }
 }
-	| atomic_flags KW_P2P
+        | atomic_flags KW_P2P
 {
 {
   current_atomic->_flags |= DCAtomicField::F_p2p;
   current_atomic->_flags |= DCAtomicField::F_p2p;
 }
 }
-	| atomic_flags KW_RAM
+        | atomic_flags KW_RAM
 {
 {
   current_atomic->_flags |= DCAtomicField::F_ram;
   current_atomic->_flags |= DCAtomicField::F_ram;
 }
 }
-	| atomic_flags KW_DB
+        | atomic_flags KW_DB
 {
 {
   current_atomic->_flags |= DCAtomicField::F_db;
   current_atomic->_flags |= DCAtomicField::F_db;
 }
 }
-	| atomic_flags KW_CLSEND
+        | atomic_flags KW_CLSEND
 {
 {
   current_atomic->_flags |= DCAtomicField::F_clsend;
   current_atomic->_flags |= DCAtomicField::F_clsend;
 }
 }
-	| atomic_flags KW_CLRECV
+        | atomic_flags KW_CLRECV
 {
 {
   current_atomic->_flags |= DCAtomicField::F_clrecv;
   current_atomic->_flags |= DCAtomicField::F_clrecv;
 }
 }
-	| atomic_flags KW_OWNSEND
+        | atomic_flags KW_OWNSEND
 {
 {
   current_atomic->_flags |= DCAtomicField::F_ownsend;
   current_atomic->_flags |= DCAtomicField::F_ownsend;
 }
 }
-	;
+        ;
 
 
 molecular_field:
 molecular_field:
-	IDENTIFIER ':'
+        IDENTIFIER ':'
 {
 {
   current_molecular = new DCMolecularField;
   current_molecular = new DCMolecularField;
   current_molecular->_name = $1;
   current_molecular->_name = $1;
@@ -386,28 +386,28 @@ molecular_field:
     yyerror("Duplicate field name: " + current_molecular->_name);
     yyerror("Duplicate field name: " + current_molecular->_name);
   }
   }
 }
 }
-	molecular_atom_list
-	;
+        molecular_atom_list
+        ;
 
 
 molecular_atom_list:
 molecular_atom_list:
-	atomic_name
+        atomic_name
 {
 {
   if ($1 != (DCAtomicField *)NULL) {
   if ($1 != (DCAtomicField *)NULL) {
     current_molecular->_fields.push_back($1);
     current_molecular->_fields.push_back($1);
   }
   }
 }
 }
-	| molecular_atom_list ',' atomic_name
+        | molecular_atom_list ',' atomic_name
 {
 {
   if ($3 != (DCAtomicField *)NULL) {
   if ($3 != (DCAtomicField *)NULL) {
     current_molecular->_fields.push_back($3);
     current_molecular->_fields.push_back($3);
     if (current_molecular->_fields[0]->_flags != $3->_flags) {
     if (current_molecular->_fields[0]->_flags != $3->_flags) {
       yyerror("Mismatched flags in molecule between " + 
       yyerror("Mismatched flags in molecule between " + 
-	      current_molecular->_fields[0]->_name + " and " +
-	      $3->_name);
+              current_molecular->_fields[0]->_name + " and " +
+              $3->_name);
     }
     }
   }
   }
 }
 }
-	;
+        ;
 
 
 empty:
 empty:
-	;
+        ;

+ 1 - 1
direct/src/dcparser/dcSubatomicType.h

@@ -10,7 +10,7 @@
 
 
 BEGIN_PUBLISH
 BEGIN_PUBLISH
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	  Enum : DCSubatomicType
+//        Enum : DCSubatomicType
 // Description : This defines the numeric type of each element of a
 // Description : This defines the numeric type of each element of a
 //               DCAtomicField; that is, the particular values that
 //               DCAtomicField; that is, the particular values that
 //               will get added to the message when the atomic field
 //               will get added to the message when the atomic field

+ 1 - 1
direct/src/dcparser/hashGenerator.h

@@ -10,7 +10,7 @@
 #include "primeNumberGenerator.h"
 #include "primeNumberGenerator.h"
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : HashGenerator
+//       Class : HashGenerator
 // Description : This class generates an arbitrary hash number from a
 // Description : This class generates an arbitrary hash number from a
 //               sequence of ints.
 //               sequence of ints.
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 2 - 2
direct/src/dcparser/primeNumberGenerator.cxx

@@ -38,8 +38,8 @@ operator [] (int n) {
     int j = 0;
     int j = 0;
     while (maybe_prime && _primes[j] * _primes[j] <= candidate) {
     while (maybe_prime && _primes[j] * _primes[j] <= candidate) {
       if ((_primes[j] * (candidate / _primes[j])) == candidate) {
       if ((_primes[j] * (candidate / _primes[j])) == candidate) {
-	// This one is not prime.
-	maybe_prime = false;
+        // This one is not prime.
+        maybe_prime = false;
       }
       }
       j++;
       j++;
       nassertr(j < (int)_primes.size(), 0);
       nassertr(j < (int)_primes.size(), 0);

+ 1 - 1
direct/src/dcparser/primeNumberGenerator.h

@@ -9,7 +9,7 @@
 #include "dcbase.h"
 #include "dcbase.h"
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : PrimeNumberGenerator
+//       Class : PrimeNumberGenerator
 // Description : This class generates a table of prime numbers, up to
 // Description : This class generates a table of prime numbers, up to
 //               the limit of an int.  For a given integer n, it will
 //               the limit of an int.  For a given integer n, it will
 //               return the nth prime number.  This will involve a
 //               return the nth prime number.  This will involve a

+ 3 - 3
direct/src/deadrec/correction.cxx

@@ -11,9 +11,9 @@ NotifyCategoryDeclNoExport(correction);
 NotifyCategoryDef(correction, "");
 NotifyCategoryDef(correction, "");
 
 
 Correction::Correction(LPoint3f& start, LVector3f& s_vel) : _curr_p(start),
 Correction::Correction(LPoint3f& start, LVector3f& s_vel) : _curr_p(start),
-							    _curr_v(s_vel) {
+                                                            _curr_v(s_vel) {
   correction_cat->debug() << "construction with:" << endl << "start = "
   correction_cat->debug() << "construction with:" << endl << "start = "
-			  << start << endl << "vel = " << s_vel << endl;
+                          << start << endl << "vel = " << s_vel << endl;
 }
 }
 
 
 Correction::~Correction(void) {
 Correction::~Correction(void) {
@@ -131,7 +131,7 @@ void SplineCorrection::step(void) {
       correction_cat->spam() << "time >= dur, holding at current pos" << endl;
       correction_cat->spam() << "time >= dur, holding at current pos" << endl;
   } else
   } else
     correction_cat->spam() << "have_both is false, no point calculated"
     correction_cat->spam() << "have_both is false, no point calculated"
-			   << endl;
+                           << endl;
 }
 }
 
 
 void SplineCorrection::new_target(LPoint3f& target, LVector3f& v_target) {
 void SplineCorrection::new_target(LPoint3f& target, LVector3f& v_target) {

+ 7 - 7
direct/src/showbase/showBase.cxx

@@ -53,7 +53,7 @@ std::string chan_config = "single";
 std::string window_title = "Panda3D";
 std::string window_title = "Panda3D";
 
 
 void render_frame(GraphicsPipe *pipe,
 void render_frame(GraphicsPipe *pipe,
-		  NodeAttributes &initial_state) {
+                  NodeAttributes &initial_state) {
   int num_windows = pipe->get_num_windows();
   int num_windows = pipe->get_num_windows();
   for (int w = 0; w < num_windows; w++) {
   for (int w = 0; w < num_windows; w++) {
     GraphicsWindow *win = pipe->get_window(w);
     GraphicsWindow *win = pipe->get_window(w);
@@ -66,7 +66,7 @@ void render_frame(GraphicsPipe *pipe,
 class WindowCallback : public GraphicsWindow::Callback {
 class WindowCallback : public GraphicsWindow::Callback {
 public:
 public:
   WindowCallback(GraphicsPipe *pipe, Node *render,
   WindowCallback(GraphicsPipe *pipe, Node *render,
-		 NodeAttributes *initial_state) :
+                 NodeAttributes *initial_state) :
     _pipe(pipe),
     _pipe(pipe),
     _render(render),
     _render(render),
     _initial_state(initial_state),
     _initial_state(initial_state),
@@ -112,9 +112,9 @@ PT(GraphicsPipe) make_graphics_pipe() {
 }
 }
 
 
 PT(GraphicsWindow) make_graphics_window(GraphicsPipe *pipe, 
 PT(GraphicsWindow) make_graphics_window(GraphicsPipe *pipe, 
-					NamedNode *render,
-					NamedNode *camera,
-					NodeAttributes &initial_state) {
+                                        NamedNode *render,
+                                        NamedNode *camera,
+                                        NodeAttributes &initial_state) {
   PT(GraphicsWindow) main_win;
   PT(GraphicsWindow) main_win;
   ChanCfgOverrides override;
   ChanCfgOverrides override;
 
 
@@ -128,7 +128,7 @@ PT(GraphicsWindow) make_graphics_window(GraphicsPipe *pipe,
   initial_state.set_attribute(DepthWriteTransition::get_class_type(), dwa);
   initial_state.set_attribute(DepthWriteTransition::get_class_type(), dwa);
 
 
   override.setField(ChanCfgOverrides::Mask,
   override.setField(ChanCfgOverrides::Mask,
-		    ((unsigned int)(W_DOUBLE|W_DEPTH|W_MULTISAMPLE)));
+                    ((unsigned int)(W_DOUBLE|W_DEPTH|W_MULTISAMPLE)));
 
 
   std::string title = config_showbase.GetString("window-title", window_title);
   std::string title = config_showbase.GetString("window-title", window_title);
   override.setField(ChanCfgOverrides::Title, title);
   override.setField(ChanCfgOverrides::Title, title);
@@ -278,7 +278,7 @@ void take_snapshot(GraphicsWindow *win, const string &name) {
   int height = dr->get_pixel_height();
   int height = dr->get_pixel_height();
   
   
   PixelBuffer p(width, height, 3, 1, PixelBuffer::T_unsigned_byte, 
   PixelBuffer p(width, height, 3, 1, PixelBuffer::T_unsigned_byte, 
-		PixelBuffer::F_rgb);
+                PixelBuffer::F_rgb);
 
 
   p.copy(gsg, dr, rb);
   p.copy(gsg, dr, rb);
   p.write(name);
   p.write(name);

+ 4 - 4
direct/src/showbase/showBase.h

@@ -31,13 +31,13 @@ EXPCL_DIRECT DSearchPath &get_particle_path();
 EXPCL_DIRECT PT(GraphicsPipe) make_graphics_pipe();
 EXPCL_DIRECT PT(GraphicsPipe) make_graphics_pipe();
 EXPCL_DIRECT PT(GraphicsWindow) 
 EXPCL_DIRECT PT(GraphicsWindow) 
   make_graphics_window(GraphicsPipe *pipe, 
   make_graphics_window(GraphicsPipe *pipe, 
-		       NamedNode *render,
-		       NamedNode *camera,
-		       NodeAttributes &initial_state);	
+                       NamedNode *render,
+                       NamedNode *camera,
+                       NodeAttributes &initial_state);
 
 
 EXPCL_DIRECT NodePath setup_panda_2d(GraphicsWindow *win, const string &name);
 EXPCL_DIRECT NodePath setup_panda_2d(GraphicsWindow *win, const string &name);
 EXPCL_DIRECT void add_render_layer(GraphicsWindow *win, Node *render_top,
 EXPCL_DIRECT void add_render_layer(GraphicsWindow *win, Node *render_top,
-				   Camera *camera);
+                                   Camera *camera);
 
 
 EXPCL_DIRECT void toggle_wireframe(NodeAttributes &initial_state);
 EXPCL_DIRECT void toggle_wireframe(NodeAttributes &initial_state);
 EXPCL_DIRECT void toggle_texture(NodeAttributes &initial_state);
 EXPCL_DIRECT void toggle_texture(NodeAttributes &initial_state);

+ 4 - 4
dtool/src/cppparser/cppArrayType.cxx

@@ -93,7 +93,7 @@ is_equivalent(const CPPType &other) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPArrayType::
 CPPDeclaration *CPPArrayType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;
@@ -145,8 +145,8 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPArrayType::
 void CPPArrayType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   ostringstream brackets;
   ostringstream brackets;
   brackets << "[";
   brackets << "[";
   if (_bounds != NULL) {
   if (_bounds != NULL) {
@@ -156,7 +156,7 @@ output_instance(ostream &out, int indent_level, CPPScope *scope,
   string bracketsstr = brackets.str();
   string bracketsstr = brackets.str();
 
 
   _element_type->output_instance(out, indent_level, scope, complete, 
   _element_type->output_instance(out, indent_level, scope, complete, 
-				 prename, name + bracketsstr);
+                                 prename, name + bracketsstr);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 8 - 8
dtool/src/cppparser/cppArrayType.h

@@ -13,7 +13,7 @@
 class CPPExpression;
 class CPPExpression;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPArrayType
+//       Class : CPPArrayType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPArrayType : public CPPType {
 class CPPArrayType : public CPPType {
@@ -25,20 +25,20 @@ public:
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
   virtual bool is_equivalent(const CPPType &other) const;
   virtual bool is_equivalent(const CPPType &other) const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
 
 
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 

تفاوت فایلی نمایش داده نمی شود زیرا این فایل بسیار بزرگ است
+ 219 - 219
dtool/src/cppparser/cppBison.yxx


+ 4 - 4
dtool/src/cppparser/cppBisonDefs.h

@@ -37,11 +37,11 @@ class CPPIdentifier;
 
 
 void parse_cpp(CPPParser *cp);
 void parse_cpp(CPPParser *cp);
 CPPExpression *parse_const_expr(CPPPreprocessor *pp,
 CPPExpression *parse_const_expr(CPPPreprocessor *pp,
-				CPPScope *new_current_scope,
-				CPPScope *new_global_scope);
+                                CPPScope *new_current_scope,
+                                CPPScope *new_global_scope);
 CPPType *parse_type(CPPPreprocessor *pp,
 CPPType *parse_type(CPPPreprocessor *pp,
-		    CPPScope *new_current_scope,
-		    CPPScope *new_global_scope);
+                    CPPScope *new_current_scope,
+                    CPPScope *new_global_scope);
 
 
 extern CPPScope *current_scope;
 extern CPPScope *current_scope;
 extern CPPScope *global_scope;
 extern CPPScope *global_scope;

+ 3 - 3
dtool/src/cppparser/cppClassTemplateParameter.h

@@ -13,17 +13,17 @@
 class CPPIdentifier;
 class CPPIdentifier;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPClassTemplateParameter
+//       Class : CPPClassTemplateParameter
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPClassTemplateParameter : public CPPType {
 class CPPClassTemplateParameter : public CPPType {
 public:
 public:
   CPPClassTemplateParameter(CPPIdentifier *ident,
   CPPClassTemplateParameter(CPPIdentifier *ident,
-			    CPPType *default_type = NULL);
+                            CPPType *default_type = NULL);
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPClassTemplateParameter *as_class_template_parameter();
   virtual CPPClassTemplateParameter *as_class_template_parameter();

+ 1 - 1
dtool/src/cppparser/cppCommentBlock.h

@@ -13,7 +13,7 @@
 #include <list>
 #include <list>
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPCommentBlock
+//       Class : CPPCommentBlock
 // Description : This represents a comment appearing in the source
 // Description : This represents a comment appearing in the source
 //               code.  The CPPPreprocessor collects these, and saves
 //               code.  The CPPPreprocessor collects these, and saves
 //               the complete list of comments encountered; it also
 //               the complete list of comments encountered; it also

+ 4 - 4
dtool/src/cppparser/cppConstType.cxx

@@ -39,7 +39,7 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPConstType::
 CPPDeclaration *CPPConstType::
 substitute_decl(CPPDeclaration::SubstDecl &subst, 
 substitute_decl(CPPDeclaration::SubstDecl &subst, 
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;
@@ -132,10 +132,10 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPConstType::
 void CPPConstType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   _wrapped_around->output_instance(out, indent_level, scope, complete, 
   _wrapped_around->output_instance(out, indent_level, scope, complete, 
-				   "const " + prename, name);
+                                   "const " + prename, name);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 8 - 8
dtool/src/cppparser/cppConstType.h

@@ -11,7 +11,7 @@
 #include "cppType.h"
 #include "cppType.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPConstType
+//       Class : CPPConstType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPConstType : public CPPType {
 class CPPConstType : public CPPType {
@@ -22,21 +22,21 @@ public:
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
   virtual bool is_equivalent(const CPPType &other) const;
   virtual bool is_equivalent(const CPPType &other) const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
 
 
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 

+ 2 - 2
dtool/src/cppparser/cppDeclaration.cxx

@@ -125,8 +125,8 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPDeclaration::
 CPPDeclaration *CPPDeclaration::
 instantiate(const CPPTemplateParameterList *, 
 instantiate(const CPPTemplateParameterList *, 
-	    CPPScope *, CPPScope *,
-	    CPPPreprocessor *error_sink) const {
+            CPPScope *, CPPScope *,
+            CPPPreprocessor *error_sink) const {
   if (error_sink != NULL) {
   if (error_sink != NULL) {
     error_sink->warning("Ignoring template parameters");
     error_sink->warning("Ignoring template parameters");
   }
   }

+ 6 - 6
dtool/src/cppparser/cppDeclaration.h

@@ -45,7 +45,7 @@ class CPPTemplateScope;
 class CPPPreprocessor;
 class CPPPreprocessor;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPDeclaration
+//       Class : CPPDeclaration
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPDeclaration {
 class CPPDeclaration {
@@ -89,19 +89,19 @@ public:
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *
   virtual CPPDeclaration *
   instantiate(const CPPTemplateParameterList *actual_params,
   instantiate(const CPPTemplateParameterList *actual_params,
-	      CPPScope *current_scope, CPPScope *global_scope,
-	      CPPPreprocessor *error_sink = NULL) const;
+              CPPScope *current_scope, CPPScope *global_scope,
+              CPPPreprocessor *error_sink = NULL) const;
 
 
   typedef map<CPPDeclaration *, CPPDeclaration *> SubstDecl;
   typedef map<CPPDeclaration *, CPPDeclaration *> SubstDecl;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   typedef set<CPPDeclaration *> Instantiations;
   typedef set<CPPDeclaration *> Instantiations;
   Instantiations _instantiations;
   Instantiations _instantiations;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const=0;
+                      bool complete) const=0;
 
 
   virtual SubType get_subtype() const=0;
   virtual SubType get_subtype() const=0;
 
 

+ 4 - 4
dtool/src/cppparser/cppEnumType.cxx

@@ -19,7 +19,7 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPEnumType::
 CPPEnumType::
 CPPEnumType(CPPIdentifier *ident, CPPScope *current_scope,
 CPPEnumType(CPPIdentifier *ident, CPPScope *current_scope,
-	    const CPPFile &file) :
+            const CPPFile &file) :
   CPPExtensionType(T_enum, ident, current_scope, file)
   CPPExtensionType(T_enum, ident, current_scope, file)
 {
 {
 }
 }
@@ -33,7 +33,7 @@ void CPPEnumType::
 add_element(const string &name, CPPScope *scope, CPPExpression *value) {
 add_element(const string &name, CPPScope *scope, CPPExpression *value) {
   CPPType *type = 
   CPPType *type = 
     CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
     CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_int,
-					CPPSimpleType::F_unsigned));
+                                        CPPSimpleType::F_unsigned));
   CPPIdentifier *ident = new CPPIdentifier(name);
   CPPIdentifier *ident = new CPPIdentifier(name);
   CPPInstance *inst = new CPPInstance(type, ident);
   CPPInstance *inst = new CPPInstance(type, ident);
   inst->_initializer = value;
   inst->_initializer = value;
@@ -59,7 +59,7 @@ is_incomplete() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPEnumType::
 CPPDeclaration *CPPEnumType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;
@@ -110,7 +110,7 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete) const {
     for (ei = _elements.begin(); ei != _elements.end(); ++ei) {
     for (ei = _elements.begin(); ei != _elements.end(); ++ei) {
       indent(out, indent_level + 2) << (*ei)->get_local_name();
       indent(out, indent_level + 2) << (*ei)->get_local_name();
       if ((*ei)->_initializer != NULL) {
       if ((*ei)->_initializer != NULL) {
-	out << " = " << *(*ei)->_initializer;
+        out << " = " << *(*ei)->_initializer;
       }
       }
       out << ",\n";
       out << ",\n";
     }
     }

+ 6 - 6
dtool/src/cppparser/cppEnumType.h

@@ -18,25 +18,25 @@ class CPPScope;
 
 
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPEnumType
+//       Class : CPPEnumType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPEnumType : public CPPExtensionType {
 class CPPEnumType : public CPPExtensionType {
 public:
 public:
   CPPEnumType(CPPIdentifier *ident, CPPScope *current_scope,
   CPPEnumType(CPPIdentifier *ident, CPPScope *current_scope,
-	      const CPPFile &file);
+              const CPPFile &file);
 
 
   void add_element(const string &name, CPPScope *scope,
   void add_element(const string &name, CPPScope *scope,
-		   CPPExpression *value = (CPPExpression *)NULL);
+                   CPPExpression *value = (CPPExpression *)NULL);
 
 
   virtual bool is_incomplete() const;
   virtual bool is_incomplete() const;
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPEnumType *as_enum_type();
   virtual CPPEnumType *as_enum_type();

+ 95 - 95
dtool/src/cppparser/cppExpression.cxx

@@ -211,7 +211,7 @@ CPPExpression(const string &value) :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPExpression::
 CPPExpression::
 CPPExpression(CPPIdentifier *ident, CPPScope *current_scope, 
 CPPExpression(CPPIdentifier *ident, CPPScope *current_scope, 
-	      CPPScope *global_scope, CPPPreprocessor *error_sink) :
+              CPPScope *global_scope, CPPPreprocessor *error_sink) :
   CPPDeclaration(CPPFile()) 
   CPPDeclaration(CPPFile()) 
 {
 {
   CPPDeclaration *decl = 
   CPPDeclaration *decl = 
@@ -275,7 +275,7 @@ CPPExpression(int binary_operator, CPPExpression *op1, CPPExpression *op2) :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPExpression::
 CPPExpression::
 CPPExpression(int trinary_operator, CPPExpression *op1, CPPExpression *op2, 
 CPPExpression(int trinary_operator, CPPExpression *op1, CPPExpression *op2, 
-	      CPPExpression *op3) :
+              CPPExpression *op3) :
   CPPDeclaration(CPPFile()) 
   CPPDeclaration(CPPFile()) 
 {
 {
   _type = T_trinary_operation;
   _type = T_trinary_operation;
@@ -401,15 +401,15 @@ evaluate() const {
     if (r1._type != RT_error) {
     if (r1._type != RT_error) {
       CPPSimpleType *stype = _u._typecast._to->as_simple_type();
       CPPSimpleType *stype = _u._typecast._to->as_simple_type();
       if (stype != NULL) {
       if (stype != NULL) {
-	if (stype->_type == CPPSimpleType::T_int) {
-	  return Result(r1.as_integer());
-	} else if (stype->_type == CPPSimpleType::T_float ||
-		   stype->_type == CPPSimpleType::T_double) {
-	  return Result(r1.as_real());
-	}
+        if (stype->_type == CPPSimpleType::T_int) {
+          return Result(r1.as_integer());
+        } else if (stype->_type == CPPSimpleType::T_float ||
+                   stype->_type == CPPSimpleType::T_double) {
+          return Result(r1.as_real());
+        }
       }
       }
       if (_u._typecast._to->as_pointer_type()) {
       if (_u._typecast._to->as_pointer_type()) {
-	return Result(r1.as_pointer());
+        return Result(r1.as_pointer());
       }
       }
     }
     }
     return Result();
     return Result();
@@ -433,7 +433,7 @@ evaluate() const {
     // In all other cases, both operands must be valid in order for
     // In all other cases, both operands must be valid in order for
     // the operation to be valid.
     // the operation to be valid.
     if (r2._type == RT_error && 
     if (r2._type == RT_error && 
-	(_u._op._operator != OROR && _u._op._operator != ANDAND)) {
+        (_u._op._operator != OROR && _u._op._operator != ANDAND)) {
       return r2;
       return r2;
     }
     }
     // Fall through
     // Fall through
@@ -469,16 +469,16 @@ evaluate() const {
 
 
     case '*':
     case '*':
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() * r2.as_real());
+        return Result(r1.as_real() * r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() * r2.as_integer());
+        return Result(r1.as_integer() * r2.as_integer());
       }
       }
 
 
     case '/':
     case '/':
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() / r2.as_real());
+        return Result(r1.as_real() / r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() / r2.as_integer());
+        return Result(r1.as_integer() / r2.as_integer());
       }
       }
 
 
     case '%':
     case '%':
@@ -486,16 +486,16 @@ evaluate() const {
 
 
     case '+':
     case '+':
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() + r2.as_real());
+        return Result(r1.as_real() + r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() + r2.as_integer());
+        return Result(r1.as_integer() + r2.as_integer());
       }
       }
 
 
     case '-':
     case '-':
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() - r2.as_real());
+        return Result(r1.as_real() - r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() - r2.as_integer());
+        return Result(r1.as_integer() - r2.as_integer());
       }
       }
 
 
     case '|':
     case '|':
@@ -506,58 +506,58 @@ evaluate() const {
 
 
     case OROR:
     case OROR:
       if (r1.as_integer()) {
       if (r1.as_integer()) {
-	return r1;
+        return r1;
       } else {
       } else {
-	return r2;
+        return r2;
       }
       }
 
 
     case ANDAND:
     case ANDAND:
       if (r1.as_integer()) {
       if (r1.as_integer()) {
-	return r2;
+        return r2;
       } else {
       } else {
-	return r1;
+        return r1;
       }
       }
 
 
     case EQCOMPARE:
     case EQCOMPARE:
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() == r2.as_real());
+        return Result(r1.as_real() == r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() == r2.as_integer());
+        return Result(r1.as_integer() == r2.as_integer());
       }
       }
 
 
     case NECOMPARE:
     case NECOMPARE:
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() != r2.as_real());
+        return Result(r1.as_real() != r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() != r2.as_integer());
+        return Result(r1.as_integer() != r2.as_integer());
       }
       }
 
 
     case LECOMPARE:
     case LECOMPARE:
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() <= r2.as_real());
+        return Result(r1.as_real() <= r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() <= r2.as_integer());
+        return Result(r1.as_integer() <= r2.as_integer());
       }
       }
 
 
     case GECOMPARE:
     case GECOMPARE:
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() >= r2.as_real());
+        return Result(r1.as_real() >= r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() >= r2.as_integer());
+        return Result(r1.as_integer() >= r2.as_integer());
       }
       }
 
 
     case '<':
     case '<':
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() < r2.as_real());
+        return Result(r1.as_real() < r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() < r2.as_integer());
+        return Result(r1.as_integer() < r2.as_integer());
       }
       }
 
 
     case '>':
     case '>':
       if (r1._type == RT_real || r2._type == RT_real) {
       if (r1._type == RT_real || r2._type == RT_real) {
-	return Result(r1.as_real() > r2.as_real());
+        return Result(r1.as_real() > r2.as_real());
       } else {
       } else {
-	return Result(r1.as_integer() > r2.as_integer());
+        return Result(r1.as_integer() > r2.as_integer());
       }
       }
 
 
     case LSHIFT:
     case LSHIFT:
@@ -568,7 +568,7 @@ evaluate() const {
 
 
     case '?':
     case '?':
       return r1.as_integer() ? 
       return r1.as_integer() ? 
-	_u._op._op2->evaluate() : _u._op._op3->evaluate();
+        _u._op._op2->evaluate() : _u._op._op3->evaluate();
 
 
     case '.':
     case '.':
     case POINTSAT:
     case POINTSAT:
@@ -633,10 +633,10 @@ determine_type() const {
 
 
   case T_string:
   case T_string:
     return char_star_type;
     return char_star_type;
-			
+
   case T_variable:
   case T_variable:
     return _u._variable->_type;
     return _u._variable->_type;
-			
+
   case T_function:
   case T_function:
     if (_u._fgroup->get_return_type() == (CPPType *)NULL) {
     if (_u._fgroup->get_return_type() == (CPPType *)NULL) {
       // There are multiple functions by this name that have different
       // There are multiple functions by this name that have different
@@ -685,12 +685,12 @@ determine_type() const {
     case UNARY_STAR:
     case UNARY_STAR:
     case '[': // Array element reference
     case '[': // Array element reference
       if (t1 != NULL) {
       if (t1 != NULL) {
-	if (t1->as_pointer_type()) {
-	  return t1->as_pointer_type()->_pointing_at;
-	}
-	if (t1->as_array_type()) {
-	  return t1->as_array_type()->_element_type;
-	}
+        if (t1->as_pointer_type()) {
+          return t1->as_pointer_type()->_pointing_at;
+        }
+        if (t1->as_array_type()) {
+          return t1->as_array_type()->_element_type;
+        }
       }
       }
       return NULL;
       return NULL;
 
 
@@ -702,14 +702,14 @@ determine_type() const {
     case '+':
     case '+':
     case '-':
     case '-':
       if (t1 == NULL) {
       if (t1 == NULL) {
-	return t2;
+        return t2;
       } else if (t2 == NULL) {
       } else if (t2 == NULL) {
-	return t1;
+        return t1;
       } else if (t1->as_pointer_type()) {
       } else if (t1->as_pointer_type()) {
-	if (t2->as_pointer_type()) {
-	  return int_type;
-	}
-	return t1;
+        if (t2->as_pointer_type()) {
+          return int_type;
+        }
+        return t1;
       }
       }
       return elevate_type(t1, t2);
       return elevate_type(t1, t2);
 
 
@@ -739,10 +739,10 @@ determine_type() const {
 
 
     case 'f': // Function evaluation
     case 'f': // Function evaluation
       if (t1 != NULL) {
       if (t1 != NULL) {
-	CPPFunctionType *ftype = t1->as_function_type();
-	if (ftype != (CPPFunctionType *)NULL) {
-	  return ftype->_return_type;
-	}
+        CPPFunctionType *ftype = t1->as_function_type();
+        if (ftype != (CPPFunctionType *)NULL) {
+          return ftype->_return_type;
+        }
       }
       }
       return NULL;
       return NULL;
 
 
@@ -769,7 +769,7 @@ determine_type() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPExpression::
 CPPDeclaration *CPPExpression::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPDeclaration *top = 
   CPPDeclaration *top = 
     CPPDeclaration::substitute_decl(subst, current_scope, global_scope);
     CPPDeclaration::substitute_decl(subst, current_scope, global_scope);
   if (top != this) {
   if (top != this) {
@@ -785,14 +785,14 @@ substitute_decl(CPPDeclaration::SubstDecl &subst,
     decl = _u._variable->substitute_decl(subst, current_scope, global_scope);
     decl = _u._variable->substitute_decl(subst, current_scope, global_scope);
     if (decl != rep->_u._variable) {
     if (decl != rep->_u._variable) {
       if (decl->as_instance()) {
       if (decl->as_instance()) {
-	// Replacing the variable reference with another variable reference.
-	rep->_u._variable = decl->as_instance();
-	any_changed = true;
+        // Replacing the variable reference with another variable reference.
+        rep->_u._variable = decl->as_instance();
+        any_changed = true;
       } else if (decl->as_expression()) {
       } else if (decl->as_expression()) {
-	// Replacing the variable reference with an expression.
-	delete rep;
-	rep = decl->as_expression();
-	any_changed = true;
+        // Replacing the variable reference with an expression.
+        delete rep;
+        rep = decl->as_expression();
+        any_changed = true;
       }
       }
     }
     }
     break;
     break;
@@ -914,35 +914,35 @@ output(ostream &out, int indent_level, CPPScope *scope, bool) const {
     {
     {
       string::const_iterator si;
       string::const_iterator si;
       for (si = _str.begin(); si != _str.end(); ++si) {
       for (si = _str.begin(); si != _str.end(); ++si) {
-	switch (*si) {
-	case '\n':
-	  out << "\\n";
-	  break;
-	  
-	case '\t':
-	  out << "\\t";
-	  break;
-	  
-	case '\r':
-	  out << "\\r";
-	  break;
-	  
-	case '\a':
-	  out << "\\a";
-	  break;
-	  
-	case '"':
-	  out << "\\\"";
-	  break;
-
-	default:
-	  if (isprint(*si)) {
-	    out << *si;
-	  } else {
-	    out << '\\' << oct << setw(3) << setfill('0') << (int)(*si)
-		<< dec << setw(0);
-	  }
-	}
+        switch (*si) {
+        case '\n':
+          out << "\\n";
+          break;
+
+        case '\t':
+          out << "\\t";
+          break;
+
+        case '\r':
+          out << "\\r";
+          break;
+
+        case '\a':
+          out << "\\a";
+          break;
+
+        case '"':
+          out << "\\\"";
+          break;
+
+        default:
+          if (isprint(*si)) {
+            out << *si;
+          } else {
+            out << '\\' << oct << setw(3) << setfill('0') << (int)(*si)
+                << dec << setw(0);
+          }
+        }
       }
       }
     }
     }
     out << '"';
     out << '"';
@@ -968,7 +968,7 @@ output(ostream &out, int indent_level, CPPScope *scope, bool) const {
 
 
   case T_construct:
   case T_construct:
     out << "(" << _u._typecast._to->get_typedef_name(scope) 
     out << "(" << _u._typecast._to->get_typedef_name(scope) 
-	<< "(" << *_u._typecast._op1 << "))";
+        << "(" << *_u._typecast._op1 << "))";
     break;
     break;
 
 
   case T_default_construct:
   case T_default_construct:
@@ -977,7 +977,7 @@ output(ostream &out, int indent_level, CPPScope *scope, bool) const {
 
 
   case T_new:
   case T_new:
     out << "(new " << *_u._typecast._to
     out << "(new " << *_u._typecast._to
-	<< "(" << *_u._typecast._op1 << "))";
+        << "(" << *_u._typecast._op1 << "))";
     break;
     break;
 
 
   case T_default_new:
   case T_default_new:
@@ -1078,13 +1078,13 @@ output(ostream &out, int indent_level, CPPScope *scope, bool) const {
       
       
     default:
     default:
       out << "(" << *_u._op._op1 << " " << (char)_u._op._operator
       out << "(" << *_u._op._op1 << " " << (char)_u._op._operator
-	  << " " << *_u._op._op2 << ")";
+          << " " << *_u._op._op2 << ")";
     }
     }
     break;
     break;
 
 
   case T_trinary_operation:
   case T_trinary_operation:
     out << "(" << *_u._op._op1 << " ? " << *_u._op._op2
     out << "(" << *_u._op._op1 << " ? " << *_u._op._op2
-	<< " : " << *_u._op._op3 << ")";
+        << " : " << *_u._op._op3 << ")";
     break;
     break;
 
 
   default:
   default:
@@ -1151,7 +1151,7 @@ elevate_type(CPPType *t1, CPPType *t2) {
       st1->_type == CPPSimpleType::T_double) {
       st1->_type == CPPSimpleType::T_double) {
     return st1;
     return st1;
   } else if (st2->_type == CPPSimpleType::T_float ||
   } else if (st2->_type == CPPSimpleType::T_float ||
-	     st2->_type == CPPSimpleType::T_double) {
+             st2->_type == CPPSimpleType::T_double) {
     return st2;
     return st2;
   } else if (st1->_type == CPPSimpleType::T_int) {
   } else if (st1->_type == CPPSimpleType::T_int) {
     return st1;
     return st1;

+ 5 - 5
dtool/src/cppparser/cppExpression.h

@@ -16,7 +16,7 @@ class CPPPreprocessor;
 class CPPFunctionGroup;
 class CPPFunctionGroup;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPExpression
+//       Class : CPPExpression
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPExpression : public CPPDeclaration {
 class CPPExpression : public CPPDeclaration {
@@ -25,7 +25,7 @@ public:
   CPPExpression(const string &value);
   CPPExpression(const string &value);
   CPPExpression(double value);
   CPPExpression(double value);
   CPPExpression(CPPIdentifier *ident, CPPScope *current_scope,
   CPPExpression(CPPIdentifier *ident, CPPScope *current_scope,
-		CPPScope *global_scope, CPPPreprocessor *error_sink = NULL);
+                CPPScope *global_scope, CPPPreprocessor *error_sink = NULL);
   CPPExpression(int unary_operator, CPPExpression *op1);
   CPPExpression(int unary_operator, CPPExpression *op1);
   CPPExpression(int binary_operator, CPPExpression *op1, CPPExpression *op2);
   CPPExpression(int binary_operator, CPPExpression *op1, CPPExpression *op2);
   CPPExpression(int trinary_operator, CPPExpression *op1, CPPExpression *op2, CPPExpression *op3);
   CPPExpression(int trinary_operator, CPPExpression *op1, CPPExpression *op2, CPPExpression *op3);
@@ -70,11 +70,11 @@ public:
   bool is_tbd() const;
   bool is_tbd() const;
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPExpression *as_expression();
   virtual CPPExpression *as_expression();

+ 1 - 1
dtool/src/cppparser/cppExpressionParser.h

@@ -14,7 +14,7 @@ class CPPExpression;
 class CPPScope;
 class CPPScope;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPExpressionParser
+//       Class : CPPExpressionParser
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPExpressionParser : public CPPPreprocessor {
 class CPPExpressionParser : public CPPPreprocessor {

+ 3 - 3
dtool/src/cppparser/cppExtensionType.cxx

@@ -17,8 +17,8 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPExtensionType::
 CPPExtensionType::
 CPPExtensionType(CPPExtensionType::Type type, 
 CPPExtensionType(CPPExtensionType::Type type, 
-		 CPPIdentifier *ident, CPPScope *current_scope,
-		 const CPPFile &file) :
+                 CPPIdentifier *ident, CPPScope *current_scope,
+                 const CPPFile &file) :
   CPPType(file),
   CPPType(file),
   _type(type), _ident(ident)
   _type(type), _ident(ident)
 {
 {
@@ -100,7 +100,7 @@ is_tbd() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPExtensionType::
 CPPDeclaration *CPPExtensionType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;

+ 5 - 5
dtool/src/cppparser/cppExtensionType.h

@@ -15,7 +15,7 @@ class CPPScope;
 class CPPIdentifier;
 class CPPIdentifier;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPExtensionType
+//       Class : CPPExtensionType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPExtensionType : public CPPType {
 class CPPExtensionType : public CPPType {
@@ -28,7 +28,7 @@ public:
   };
   };
 
 
   CPPExtensionType(Type type, CPPIdentifier *ident, CPPScope *current_scope,
   CPPExtensionType(Type type, CPPIdentifier *ident, CPPScope *current_scope,
-		   const CPPFile &file);
+                   const CPPFile &file);
 
 
   virtual string get_simple_name() const;
   virtual string get_simple_name() const;
   virtual string get_local_name(CPPScope *scope = NULL) const;
   virtual string get_local_name(CPPScope *scope = NULL) const;
@@ -38,14 +38,14 @@ public:
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual bool is_equivalent(const CPPType &other) const;
   virtual bool is_equivalent(const CPPType &other) const;
 
 
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPExtensionType *as_extension_type();
   virtual CPPExtensionType *as_extension_type();

+ 4 - 4
dtool/src/cppparser/cppFile.cxx

@@ -15,7 +15,7 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPFile::
 CPPFile::
 CPPFile(const Filename &filename, const Filename &filename_as_referenced,
 CPPFile(const Filename &filename, const Filename &filename_as_referenced,
-	Source source) :
+        Source source) :
   _filename(filename), _filename_as_referenced(filename_as_referenced),
   _filename(filename), _filename_as_referenced(filename_as_referenced),
   _source(source)
   _source(source)
 {
 {
@@ -90,8 +90,8 @@ is_c_or_i_file(const Filename &filename) {
   }
   }
     
     
   return (extension == "c" || extension == "cc" || 
   return (extension == "c" || extension == "cc" || 
-	  extension == "cpp" || extension == "c++" || extension == "cxx" ||
-	  extension == "i" || extension == "t");
+          extension == "cpp" || extension == "c++" || extension == "cxx" ||
+          extension == "i" || extension == "t");
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
@@ -126,7 +126,7 @@ is_c_file(const Filename &filename) {
   }
   }
     
     
   return (extension == "c" || extension == "cc" || 
   return (extension == "c" || extension == "cc" || 
-	  extension == "cpp" || extension == "c++" || extension == "cxx");
+          extension == "cpp" || extension == "c++" || extension == "cxx");
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 3 - 3
dtool/src/cppparser/cppFile.h

@@ -10,7 +10,7 @@
 #include <filename.h>
 #include <filename.h>
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPFile
+//       Class : CPPFile
 // Description : This defines a source file (typically a C++ header
 // Description : This defines a source file (typically a C++ header
 //               file) that is parsed by the CPPParser.  Each
 //               file) that is parsed by the CPPParser.  Each
 //               declaration indicates the source file where it
 //               declaration indicates the source file where it
@@ -26,8 +26,8 @@ public:
   };
   };
 
 
   CPPFile(const Filename &filename = "", 
   CPPFile(const Filename &filename = "", 
-	  const Filename &filename_as_referenced = "", 
-	  Source source = S_none);
+          const Filename &filename_as_referenced = "", 
+          Source source = S_none);
   CPPFile(const CPPFile &copy);
   CPPFile(const CPPFile &copy);
   void operator = (const CPPFile &copy);
   void operator = (const CPPFile &copy);
   ~CPPFile();
   ~CPPFile();

+ 1 - 1
dtool/src/cppparser/cppFunctionGroup.cxx

@@ -48,7 +48,7 @@ get_return_type() const {
     ++ii;
     ++ii;
     while (ii != _instances.end()) {
     while (ii != _instances.end()) {
       if ((*ii)->_type->as_function_type()->_return_type != return_type) {
       if ((*ii)->_type->as_function_type()->_return_type != return_type) {
-	return (CPPType *)NULL;
+        return (CPPType *)NULL;
       }
       }
       ++ii;
       ++ii;
     }
     }

+ 2 - 2
dtool/src/cppparser/cppFunctionGroup.h

@@ -13,7 +13,7 @@
 class CPPInstance;
 class CPPInstance;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPFunctionGroup
+//       Class : CPPFunctionGroup
 // Description : This class is simply a container for one or more
 // Description : This class is simply a container for one or more
 //               CPPInstances for functions of the same name.  It's
 //               CPPInstances for functions of the same name.  It's
 //               handy for storing in the CPPScope, so that
 //               handy for storing in the CPPScope, so that
@@ -29,7 +29,7 @@ public:
   CPPType *get_return_type() const;
   CPPType *get_return_type() const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPFunctionGroup *as_function_group();
   virtual CPPFunctionGroup *as_function_group();

+ 8 - 8
dtool/src/cppparser/cppFunctionType.cxx

@@ -16,7 +16,7 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPFunctionType::
 CPPFunctionType::
 CPPFunctionType(CPPType *return_type, CPPParameterList *parameters,
 CPPFunctionType(CPPType *return_type, CPPParameterList *parameters,
-		int flags) :
+                int flags) :
   CPPType(CPPFile()),
   CPPType(CPPFile()),
   _return_type(return_type), 
   _return_type(return_type), 
   _parameters(parameters),
   _parameters(parameters),
@@ -86,7 +86,7 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPFunctionType::
 CPPDeclaration *CPPFunctionType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;
@@ -192,8 +192,8 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPFunctionType::
 void CPPFunctionType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   output_instance(out, indent_level, scope, complete, prename, name, -1);
   output_instance(out, indent_level, scope, complete, prename, name, -1);
 }
 }
 
 
@@ -209,8 +209,8 @@ output_instance(ostream &out, int indent_level, CPPScope *scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPFunctionType::
 void CPPFunctionType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name, int num_default_parameters) const {
+                bool complete, const string &prename,
+                const string &name, int num_default_parameters) const {
   ostringstream parm_string;
   ostringstream parm_string;
   parm_string << "(";
   parm_string << "(";
   _parameters->output(parm_string, scope, true, num_default_parameters);
   _parameters->output(parm_string, scope, true, num_default_parameters);
@@ -224,10 +224,10 @@ output_instance(ostream &out, int indent_level, CPPScope *scope,
   } else {
   } else {
     if (prename.empty()) {
     if (prename.empty()) {
       _return_type->output_instance(out, indent_level, scope, complete, 
       _return_type->output_instance(out, indent_level, scope, complete, 
-				    "", prename + name + str);
+                                    "", prename + name + str);
     } else {
     } else {
       _return_type->output_instance(out, indent_level, scope, complete, 
       _return_type->output_instance(out, indent_level, scope, complete, 
-				    "", "(" + prename + name + ")" + str);
+                                    "", "(" + prename + name + ")" + str);
     }
     }
   }
   }
 
 

+ 14 - 14
dtool/src/cppparser/cppFunctionType.h

@@ -14,7 +14,7 @@ class CPPParameterList;
 class CPPIdentifier;
 class CPPIdentifier;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPFunctionType
+//       Class : CPPFunctionType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPFunctionType : public CPPType {
 class CPPFunctionType : public CPPType {
@@ -28,7 +28,7 @@ public:
   };
   };
 
 
   CPPFunctionType(CPPType *return_type, CPPParameterList *parameters,
   CPPFunctionType(CPPType *return_type, CPPParameterList *parameters,
-		  int flags);
+                  int flags);
   CPPFunctionType(const CPPFunctionType &copy);
   CPPFunctionType(const CPPFunctionType &copy);
   void operator = (const CPPFunctionType &copy);
   void operator = (const CPPFunctionType &copy);
 
 
@@ -38,27 +38,27 @@ public:
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   void output(ostream &out, int indent_level, CPPScope *scope,
   void output(ostream &out, int indent_level, CPPScope *scope,
-	      bool complete, int num_default_parameters) const;
+              bool complete, int num_default_parameters) const;
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
   void output_instance(ostream &out, int indent_level,
   void output_instance(ostream &out, int indent_level,
-		       CPPScope *scope,
-		       bool complete, const string &prename,
-		       const string &name,
-		       int num_default_parameters) const;
+                       CPPScope *scope,
+                       bool complete, const string &prename,
+                       const string &name,
+                       int num_default_parameters) const;
   int get_num_default_parameters() const;
   int get_num_default_parameters() const;
 
 
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;

+ 46 - 46
dtool/src/cppparser/cppIdentifier.cxx

@@ -151,7 +151,7 @@ get_local_name(CPPScope *scope) const {
     } else {
     } else {
       result = my_scope->get_local_name(scope);
       result = my_scope->get_local_name(scope);
       if (!result.empty()) {
       if (!result.empty()) {
-	result += "::";
+        result += "::";
       }
       }
       result += _names.back().get_name_with_templ(scope);
       result += _names.back().get_name_with_templ(scope);
     }
     }
@@ -223,7 +223,7 @@ is_tbd() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPIdentifier::
 CPPScope *CPPIdentifier::
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
-	  CPPPreprocessor *error_sink) const {
+          CPPPreprocessor *error_sink) const {
   assert(!_names.empty());
   assert(!_names.empty());
 
 
   CPPScope *scope = _native_scope;
   CPPScope *scope = _native_scope;
@@ -243,15 +243,15 @@ get_scope(CPPScope *current_scope, CPPScope *global_scope,
     CPPScope *next_scope = scope->find_scope(_names[i].get_name());
     CPPScope *next_scope = scope->find_scope(_names[i].get_name());
     if (next_scope == (CPPScope *)NULL) {
     if (next_scope == (CPPScope *)NULL) {
       if (error_sink != NULL) {
       if (error_sink != NULL) {
-	error_sink->error("Symbol " + _names[i].get_name() +
-			  " is not a known scope in " +
-			  scope->get_fully_scoped_name());
+        error_sink->error("Symbol " + _names[i].get_name() +
+                          " is not a known scope in " +
+                          scope->get_fully_scoped_name());
       }
       }
       return (CPPScope *)NULL;
       return (CPPScope *)NULL;
     }
     }
     if (_names[i].has_templ()) {
     if (_names[i].has_templ()) {
       next_scope = next_scope->instantiate(_names[i].get_templ(),
       next_scope = next_scope->instantiate(_names[i].get_templ(),
-					   current_scope, global_scope);
+                                           current_scope, global_scope);
     }
     }
     scope = next_scope;
     scope = next_scope;
     i++;
     i++;
@@ -267,8 +267,8 @@ get_scope(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPIdentifier::
 CPPScope *CPPIdentifier::
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
-	  CPPDeclaration::SubstDecl &subst,
-	  CPPPreprocessor *error_sink) const {
+          CPPDeclaration::SubstDecl &subst,
+          CPPPreprocessor *error_sink) const {
   assert(!_names.empty());
   assert(!_names.empty());
 
 
   CPPScope *scope = _native_scope;
   CPPScope *scope = _native_scope;
@@ -286,18 +286,18 @@ get_scope(CPPScope *current_scope, CPPScope *global_scope,
 
 
   while (i + 1 < (int)_names.size() && scope != NULL) {
   while (i + 1 < (int)_names.size() && scope != NULL) {
     CPPScope *next_scope = scope->find_scope(_names[i].get_name(), subst,
     CPPScope *next_scope = scope->find_scope(_names[i].get_name(), subst,
-					     global_scope);
+                                             global_scope);
     if (next_scope == (CPPScope *)NULL) {
     if (next_scope == (CPPScope *)NULL) {
       if (error_sink != NULL) {
       if (error_sink != NULL) {
-	error_sink->error("Symbol " + _names[i].get_name() +
-			  " is not a known scope in " +
-			  scope->get_fully_scoped_name());
+        error_sink->error("Symbol " + _names[i].get_name() +
+                          " is not a known scope in " +
+                          scope->get_fully_scoped_name());
       }
       }
       return (CPPScope *)NULL;
       return (CPPScope *)NULL;
     }
     }
     if (_names[i].has_templ()) {
     if (_names[i].has_templ()) {
       next_scope = next_scope->instantiate(_names[i].get_templ(),
       next_scope = next_scope->instantiate(_names[i].get_templ(),
-					   current_scope, global_scope);
+                                           current_scope, global_scope);
     }
     }
     scope = next_scope;
     scope = next_scope;
     i++;
     i++;
@@ -321,8 +321,8 @@ get_scope(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPType *CPPIdentifier::
 CPPType *CPPIdentifier::
 find_type(CPPScope *current_scope, CPPScope *global_scope,
 find_type(CPPScope *current_scope, CPPScope *global_scope,
-	  bool force_instantiate,
-	  CPPPreprocessor *error_sink) const {
+          bool force_instantiate,
+          CPPPreprocessor *error_sink) const {
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   if (scope == NULL) {
   if (scope == NULL) {
     return NULL;
     return NULL;
@@ -338,18 +338,18 @@ find_type(CPPScope *current_scope, CPPScope *global_scope,
     /*
     /*
     if (type != NULL) {
     if (type != NULL) {
       if (!type->is_incomplete() || force_instantiate) {
       if (!type->is_incomplete() || force_instantiate) {
-	type = type->instantiate(_names.back().get_templ(),
-				 current_scope, global_scope, 
-				 error_sink)->as_type();
-	
-	// If we ended up with another template, instantiate later.
-	if (type->is_template() && !force_instantiate) {
-	  type = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
-	}
-	
+        type = type->instantiate(_names.back().get_templ(),
+                                 current_scope, global_scope, 
+                                 error_sink)->as_type();
+
+        // If we ended up with another template, instantiate later.
+        if (type->is_template() && !force_instantiate) {
+          type = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
+        }
+
       } else {
       } else {
-	// Otherwise, we'll have to instantiate the type later.
-	type = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
+        // Otherwise, we'll have to instantiate the type later.
+        type = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
       }
       }
       //    type->_file.replace_nearer(_file);
       //    type->_file.replace_nearer(_file);
     }
     }
@@ -367,8 +367,8 @@ find_type(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPType *CPPIdentifier::
 CPPType *CPPIdentifier::
 find_type(CPPScope *current_scope, CPPScope *global_scope,
 find_type(CPPScope *current_scope, CPPScope *global_scope,
-	  CPPDeclaration::SubstDecl &subst,
-	  CPPPreprocessor *error_sink) const {
+          CPPDeclaration::SubstDecl &subst,
+          CPPPreprocessor *error_sink) const {
   CPPScope *scope = get_scope(current_scope, global_scope, subst, error_sink);
   CPPScope *scope = get_scope(current_scope, global_scope, subst, error_sink);
   if (scope == NULL) {
   if (scope == NULL) {
     return NULL;
     return NULL;
@@ -381,17 +381,17 @@ find_type(CPPScope *current_scope, CPPScope *global_scope,
       // If our identifier fully specifies the instantiation, then
       // If our identifier fully specifies the instantiation, then
       // apply it.
       // apply it.
       CPPDeclaration *decl = 
       CPPDeclaration *decl = 
-	type->instantiate(_names.back().get_templ(),
-			  current_scope, global_scope, 
-			  error_sink);
+        type->instantiate(_names.back().get_templ(),
+                          current_scope, global_scope, 
+                          error_sink);
       assert(decl != NULL);
       assert(decl != NULL);
       CPPType *new_type = decl->as_type();
       CPPType *new_type = decl->as_type();
       assert(new_type != NULL);
       assert(new_type != NULL);
-      if (new_type == type) {	
-	type = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
-	//	type = new_type;
+      if (new_type == type) {
+        type = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
+        //      type = new_type;
       } else {
       } else {
-	type = new_type;
+        type = new_type;
       }
       }
     } else {
     } else {
       // Otherwise, we'll have to instantiate the type later.
       // Otherwise, we'll have to instantiate the type later.
@@ -410,7 +410,7 @@ find_type(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPIdentifier::
 CPPDeclaration *CPPIdentifier::
 find_symbol(CPPScope *current_scope, CPPScope *global_scope,
 find_symbol(CPPScope *current_scope, CPPScope *global_scope,
-	    CPPPreprocessor *error_sink) const {
+            CPPPreprocessor *error_sink) const {
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   if (scope == NULL) {
   if (scope == NULL) {
     return NULL;
     return NULL;
@@ -424,12 +424,12 @@ find_symbol(CPPScope *current_scope, CPPScope *global_scope,
     if (sym != NULL) {
     if (sym != NULL) {
       CPPType *type = sym->as_type();
       CPPType *type = sym->as_type();
       if (type != NULL && type->is_incomplete()) {
       if (type != NULL && type->is_incomplete()) {
-	// We can't instantiate an incomplete type.
-	sym = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
+        // We can't instantiate an incomplete type.
+        sym = CPPType::new_type(new CPPTBDType((CPPIdentifier *)this));
       } else {
       } else {
-	// Instantiate the symbol.
-	sym = sym->instantiate(_names.back().get_templ(), current_scope, 
-			       global_scope, error_sink);
+        // Instantiate the symbol.
+        sym = sym->instantiate(_names.back().get_templ(), current_scope, 
+                               global_scope, error_sink);
       }
       }
     }
     }
   }
   }
@@ -444,7 +444,7 @@ find_symbol(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPIdentifier::
 CPPDeclaration *CPPIdentifier::
 find_template(CPPScope *current_scope, CPPScope *global_scope,
 find_template(CPPScope *current_scope, CPPScope *global_scope,
-	      CPPPreprocessor *error_sink) const {
+              CPPPreprocessor *error_sink) const {
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   if (scope == NULL) {
   if (scope == NULL) {
     return NULL;
     return NULL;
@@ -459,7 +459,7 @@ find_template(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPIdentifier::
 CPPScope *CPPIdentifier::
 find_scope(CPPScope *current_scope, CPPScope *global_scope,
 find_scope(CPPScope *current_scope, CPPScope *global_scope,
-	   CPPPreprocessor *error_sink) const {
+           CPPPreprocessor *error_sink) const {
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   CPPScope *scope = get_scope(current_scope, global_scope, error_sink);
   if (scope == NULL) {
   if (scope == NULL) {
     return NULL;
     return NULL;
@@ -475,16 +475,16 @@ find_scope(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPIdentifier *CPPIdentifier::
 CPPIdentifier *CPPIdentifier::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPIdentifier *rep = new CPPIdentifier(*this);
   CPPIdentifier *rep = new CPPIdentifier(*this);
 
 
   bool anything_changed = false;
   bool anything_changed = false;
   for (int i = 0; i < (int)rep->_names.size(); i++) {
   for (int i = 0; i < (int)rep->_names.size(); i++) {
     if (_names[i].has_templ()) {
     if (_names[i].has_templ()) {
       rep->_names[i].set_templ
       rep->_names[i].set_templ
-	(_names[i].get_templ()->substitute_decl(subst, current_scope, global_scope));
+        (_names[i].get_templ()->substitute_decl(subst, current_scope, global_scope));
       if (rep->_names[i].get_templ() != _names[i].get_templ()) {
       if (rep->_names[i].get_templ() != _names[i].get_templ()) {
-	anything_changed = true;
+        anything_changed = true;
       }
       }
     }
     }
   }
   }

+ 16 - 16
dtool/src/cppparser/cppIdentifier.h

@@ -21,7 +21,7 @@ class CPPPreprocessor;
 class CPPTemplateParameterList;
 class CPPTemplateParameterList;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPIdentifier
+//       Class : CPPIdentifier
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPIdentifier {
 class CPPIdentifier {
@@ -46,30 +46,30 @@ public:
 
 
 
 
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
-		      CPPPreprocessor *error_sink = NULL) const;
+                      CPPPreprocessor *error_sink = NULL) const;
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
-		      CPPDeclaration::SubstDecl &subst,
-		      CPPPreprocessor *error_sink = NULL) const;
+                      CPPDeclaration::SubstDecl &subst,
+                      CPPPreprocessor *error_sink = NULL) const;
 
 
   CPPType *find_type(CPPScope *current_scope, CPPScope *global_scope,
   CPPType *find_type(CPPScope *current_scope, CPPScope *global_scope,
-		     bool force_instantiate = false,
-		     CPPPreprocessor *error_sink = NULL) const;
+                     bool force_instantiate = false,
+                     CPPPreprocessor *error_sink = NULL) const;
   CPPType *find_type(CPPScope *current_scope, CPPScope *global_scope,
   CPPType *find_type(CPPScope *current_scope, CPPScope *global_scope,
-		     CPPDeclaration::SubstDecl &subst,
-		     CPPPreprocessor *error_sink = NULL) const;
+                     CPPDeclaration::SubstDecl &subst,
+                     CPPPreprocessor *error_sink = NULL) const;
   CPPDeclaration *find_symbol(CPPScope *current_scope,
   CPPDeclaration *find_symbol(CPPScope *current_scope,
-			      CPPScope *global_scope,
-			      CPPPreprocessor *error_sink = NULL) const;
+                              CPPScope *global_scope,
+                              CPPPreprocessor *error_sink = NULL) const;
   CPPDeclaration *find_template(CPPScope *current_scope,
   CPPDeclaration *find_template(CPPScope *current_scope,
-				CPPScope *global_scope,
-				CPPPreprocessor *error_sink = NULL) const;
+                                CPPScope *global_scope,
+                                CPPPreprocessor *error_sink = NULL) const;
   CPPScope *find_scope(CPPScope *current_scope,
   CPPScope *find_scope(CPPScope *current_scope,
-		       CPPScope *global_scope,
-		       CPPPreprocessor *error_sink = NULL) const;
+                       CPPScope *global_scope,
+                       CPPPreprocessor *error_sink = NULL) const;
 
 
   CPPIdentifier *substitute_decl(CPPDeclaration::SubstDecl &subst,
   CPPIdentifier *substitute_decl(CPPDeclaration::SubstDecl &subst,
-				 CPPScope *current_scope,
-				 CPPScope *global_scope);
+                                 CPPScope *current_scope,
+                                 CPPScope *global_scope);
 
 
   void output(ostream &out, CPPScope *scope) const;
   void output(ostream &out, CPPScope *scope) const;
   void output_local_name(ostream &out, CPPScope *scope) const;
   void output_local_name(ostream &out, CPPScope *scope) const;

+ 19 - 19
dtool/src/cppparser/cppInstance.cxx

@@ -59,7 +59,7 @@ CPPInstance(CPPType *type, CPPIdentifier *ident, int storage_class) :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPInstance::
 CPPInstance::
 CPPInstance(CPPType *type, CPPInstanceIdentifier *ii, int storage_class,
 CPPInstance(CPPType *type, CPPInstanceIdentifier *ii, int storage_class,
-	    const CPPFile &file) :
+            const CPPFile &file) :
   CPPDeclaration(file)
   CPPDeclaration(file)
 {
 {
   _type = ii->unroll_type(type);
   _type = ii->unroll_type(type);
@@ -107,7 +107,7 @@ CPPInstance::
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPInstance *CPPInstance::
 CPPInstance *CPPInstance::
 make_typecast_function(CPPInstance *inst, CPPIdentifier *ident,
 make_typecast_function(CPPInstance *inst, CPPIdentifier *ident,
-		       CPPParameterList *parameters, int function_flags) {
+                       CPPParameterList *parameters, int function_flags) {
   CPPType *type = CPPType::new_type(inst->_type);
   CPPType *type = CPPType::new_type(inst->_type);
   delete inst;
   delete inst;
       
       
@@ -252,7 +252,7 @@ is_scoped() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPInstance::
 CPPScope *CPPInstance::
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
-	  CPPPreprocessor *error_sink) const {
+          CPPPreprocessor *error_sink) const {
   if (_ident == NULL) {
   if (_ident == NULL) {
     return current_scope;
     return current_scope;
   } else {
   } else {
@@ -323,20 +323,20 @@ check_for_constructor(CPPScope *current_scope, CPPScope *global_scope) {
 
 
     if (!method_name.empty() && !class_name.empty()) {
     if (!method_name.empty() && !class_name.empty()) {
       if (method_name == class_name) {
       if (method_name == class_name) {
-	CPPType *void_type = CPPType::new_type
-	  (new CPPSimpleType(CPPSimpleType::T_void));
+        CPPType *void_type = CPPType::new_type
+          (new CPPSimpleType(CPPSimpleType::T_void));
 
 
-	_type = CPPType::new_type
-	  (new CPPFunctionType(void_type, func->_parameters, 
-			       func->_flags | CPPFunctionType::F_constructor));
+        _type = CPPType::new_type
+          (new CPPFunctionType(void_type, func->_parameters, 
+                               func->_flags | CPPFunctionType::F_constructor));
 
 
       } else if (method_name == "~" + class_name) {
       } else if (method_name == "~" + class_name) {
-	CPPType *void_type = CPPType::new_type
-	  (new CPPSimpleType(CPPSimpleType::T_void));
+        CPPType *void_type = CPPType::new_type
+          (new CPPSimpleType(CPPSimpleType::T_void));
 
 
-	_type = CPPType::new_type
-	  (new CPPFunctionType(void_type, func->_parameters, 
-			       func->_flags | CPPFunctionType::F_destructor));
+        _type = CPPType::new_type
+          (new CPPFunctionType(void_type, func->_parameters, 
+                               func->_flags | CPPFunctionType::F_destructor));
       }
       }
     }
     }
   }
   }
@@ -349,12 +349,12 @@ check_for_constructor(CPPScope *current_scope, CPPScope *global_scope) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPInstance::
 CPPDeclaration *CPPInstance::
 instantiate(const CPPTemplateParameterList *actual_params,
 instantiate(const CPPTemplateParameterList *actual_params,
-	    CPPScope *current_scope, CPPScope *global_scope,
-	    CPPPreprocessor *error_sink) const {
+            CPPScope *current_scope, CPPScope *global_scope,
+            CPPPreprocessor *error_sink) const {
   if (!is_template()) {
   if (!is_template()) {
     if (error_sink != NULL) {
     if (error_sink != NULL) {
       error_sink->warning("Ignoring template parameters for instance " + 
       error_sink->warning("Ignoring template parameters for instance " + 
-			  _ident->get_local_name());
+                          _ident->get_local_name());
     }
     }
     return (CPPInstance *)this;
     return (CPPInstance *)this;
   }
   }
@@ -372,7 +372,7 @@ instantiate(const CPPTemplateParameterList *actual_params,
 
 
   CPPDeclaration::SubstDecl subst;
   CPPDeclaration::SubstDecl subst;
   actual_params->build_subst_decl(tscope->_parameters, subst,
   actual_params->build_subst_decl(tscope->_parameters, subst,
-				  current_scope, global_scope);
+                                  current_scope, global_scope);
 
 
   CPPInstance *inst = 
   CPPInstance *inst = 
     ((CPPInstance *)this)->substitute_decl(subst, current_scope, global_scope)
     ((CPPInstance *)this)->substitute_decl(subst, current_scope, global_scope)
@@ -423,7 +423,7 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPInstance::
 CPPDeclaration *CPPInstance::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPDeclaration *top = 
   CPPDeclaration *top = 
     CPPDeclaration::substitute_decl(subst, current_scope, global_scope);
     CPPDeclaration::substitute_decl(subst, current_scope, global_scope);
   if (top != this) {
   if (top != this) {
@@ -517,7 +517,7 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete,
   if (_type->as_function_type()) {
   if (_type->as_function_type()) {
     _type->as_function_type()->
     _type->as_function_type()->
       output_instance(out, indent_level, scope, complete, "", name,
       output_instance(out, indent_level, scope, complete, "", name,
-		      num_default_parameters);
+                      num_default_parameters);
   } else {
   } else {
     _type->output_instance(out, indent_level, scope, complete, "", name);
     _type->output_instance(out, indent_level, scope, complete, "", name);
   }
   }

+ 10 - 10
dtool/src/cppparser/cppInstance.h

@@ -20,7 +20,7 @@ class CPPScope;
 class CPPExpression;
 class CPPExpression;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPInstance
+//       Class : CPPInstance
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPInstance : public CPPDeclaration {
 class CPPInstance : public CPPDeclaration {
@@ -46,13 +46,13 @@ public:
   CPPInstance(CPPType *type, const string &name, int storage_class = 0);
   CPPInstance(CPPType *type, const string &name, int storage_class = 0);
   CPPInstance(CPPType *type, CPPIdentifier *ident, int storage_class = 0);
   CPPInstance(CPPType *type, CPPIdentifier *ident, int storage_class = 0);
   CPPInstance(CPPType *type, CPPInstanceIdentifier *ii,
   CPPInstance(CPPType *type, CPPInstanceIdentifier *ii,
-	      int storage_class, const CPPFile &file);
+              int storage_class, const CPPFile &file);
   CPPInstance(const CPPInstance &copy);
   CPPInstance(const CPPInstance &copy);
   ~CPPInstance();
   ~CPPInstance();
 
 
   static CPPInstance *
   static CPPInstance *
   make_typecast_function(CPPInstance *inst, CPPIdentifier *ident,
   make_typecast_function(CPPInstance *inst, CPPIdentifier *ident,
-			 CPPParameterList *parameters, int function_flags);
+                         CPPParameterList *parameters, int function_flags);
 
 
   bool operator == (const CPPInstance &other) const;
   bool operator == (const CPPInstance &other) const;
   bool operator != (const CPPInstance &other) const;
   bool operator != (const CPPInstance &other) const;
@@ -62,7 +62,7 @@ public:
 
 
   bool is_scoped() const;
   bool is_scoped() const;
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
-		      CPPPreprocessor *error_sink = NULL) const;
+                      CPPPreprocessor *error_sink = NULL) const;
 
 
   string get_simple_name() const;
   string get_simple_name() const;
   string get_local_name(CPPScope *scope = NULL) const;
   string get_local_name(CPPScope *scope = NULL) const;
@@ -72,18 +72,18 @@ public:
 
 
   virtual CPPDeclaration *
   virtual CPPDeclaration *
   instantiate(const CPPTemplateParameterList *actual_params,
   instantiate(const CPPTemplateParameterList *actual_params,
-	      CPPScope *current_scope, CPPScope *global_scope,
-	      CPPPreprocessor *error_sink = NULL) const;
+              CPPScope *current_scope, CPPScope *global_scope,
+              CPPPreprocessor *error_sink = NULL) const;
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   void output(ostream &out, int indent_level, CPPScope *scope,
   void output(ostream &out, int indent_level, CPPScope *scope,
-	      bool complete, int num_default_parameters) const;
+              bool complete, int num_default_parameters) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPInstance *as_instance();
   virtual CPPInstance *as_instance();

+ 8 - 8
dtool/src/cppparser/cppInstanceIdentifier.cxx

@@ -132,7 +132,7 @@ add_array_modifier(CPPExpression *expr) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPInstanceIdentifier::
 CPPScope *CPPInstanceIdentifier::
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
 get_scope(CPPScope *current_scope, CPPScope *global_scope,
-	  CPPPreprocessor *error_sink) const {
+          CPPPreprocessor *error_sink) const {
   if (_ident == NULL) {
   if (_ident == NULL) {
     return current_scope;
     return current_scope;
   } else {
   } else {
@@ -147,7 +147,7 @@ get_scope(CPPScope *current_scope, CPPScope *global_scope,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPType *CPPInstanceIdentifier::
 CPPType *CPPInstanceIdentifier::
 r_unroll_type(CPPType *start_type,
 r_unroll_type(CPPType *start_type,
-	      CPPInstanceIdentifier::Modifiers::const_iterator mi) {
+              CPPInstanceIdentifier::Modifiers::const_iterator mi) {
   start_type = CPPType::new_type(start_type);
   start_type = CPPType::new_type(start_type);
 
 
   if (mi == _modifiers.end()) {
   if (mi == _modifiers.end()) {
@@ -173,10 +173,10 @@ r_unroll_type(CPPType *start_type,
       CPPType *type = r_unroll_type(start_type, mi);
       CPPType *type = r_unroll_type(start_type, mi);
       CPPFunctionType *ftype = type->as_function_type();
       CPPFunctionType *ftype = type->as_function_type();
       if (ftype != NULL) {
       if (ftype != NULL) {
-	ftype = new CPPFunctionType(*ftype);
-	ftype->_class_owner = mod._scoping;
-	ftype->_flags |= CPPFunctionType::F_method_pointer;
-	type = ftype;
+        ftype = new CPPFunctionType(*ftype);
+        ftype->_class_owner = mod._scoping;
+        ftype->_flags |= CPPFunctionType::F_method_pointer;
+        type = ftype;
       }
       }
       result = new CPPPointerType(type);
       result = new CPPPointerType(type);
     }
     }
@@ -184,7 +184,7 @@ r_unroll_type(CPPType *start_type,
 
 
   case IIT_array:
   case IIT_array:
     result = new CPPArrayType(r_unroll_type(start_type, mi),
     result = new CPPArrayType(r_unroll_type(start_type, mi),
-			      mod._expr);
+                              mod._expr);
     break;
     break;
 
 
   case IIT_const:
   case IIT_const:
@@ -199,7 +199,7 @@ r_unroll_type(CPPType *start_type,
     {
     {
       CPPType *return_type = r_unroll_type(start_type, mi);
       CPPType *return_type = r_unroll_type(start_type, mi);
       result = new CPPFunctionType(return_type, mod._func_params,
       result = new CPPFunctionType(return_type, mod._func_params,
-				   mod._func_flags);
+                                   mod._func_flags);
     }
     }
     break;
     break;
 
 

+ 2 - 2
dtool/src/cppparser/cppInstanceIdentifier.h

@@ -31,7 +31,7 @@ enum CPPInstanceIdentifierType {
 };
 };
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPInstanceIdentifier
+//       Class : CPPInstanceIdentifier
 // Description : This class is used in parser.y to build up a variable
 // Description : This class is used in parser.y to build up a variable
 //               instance definition.  An instance is something like
 //               instance definition.  An instance is something like
 //               'int *&a'; the InstanceIdentifier stores everything
 //               'int *&a'; the InstanceIdentifier stores everything
@@ -50,7 +50,7 @@ public:
   void add_array_modifier(CPPExpression *expr);
   void add_array_modifier(CPPExpression *expr);
 
 
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
   CPPScope *get_scope(CPPScope *current_scope, CPPScope *global_scope,
-		      CPPPreprocessor *error_sink = NULL) const;
+                      CPPPreprocessor *error_sink = NULL) const;
  
  
   CPPIdentifier *_ident;
   CPPIdentifier *_ident;
 
 

+ 16 - 16
dtool/src/cppparser/cppManifest.cxx

@@ -103,9 +103,9 @@ expand(const vector_string &args) const {
     if ((*ei)._parm_number >= 0) {
     if ((*ei)._parm_number >= 0) {
       int i = (*ei)._parm_number;
       int i = (*ei)._parm_number;
       if (i < (int)args.size()) {
       if (i < (int)args.size()) {
-	result += " " + args[i] + " ";
+        result += " " + args[i] + " ";
       } else {
       } else {
-	result += " ";
+        result += " ";
       }
       }
     }
     }
     if (!(*ei)._str.empty()) {
     if (!(*ei)._str.empty()) {
@@ -144,7 +144,7 @@ output(ostream &out) const {
     if (_num_parameters > 0) {
     if (_num_parameters > 0) {
       out << "$1";
       out << "$1";
       for (int i = 1; i < _num_parameters; i++) {
       for (int i = 1; i < _num_parameters; i++) {
-	out << ", $" << i + 1;
+        out << ", $" << i + 1;
       }
       }
     }
     }
     out << ")";
     out << ")";
@@ -172,7 +172,7 @@ output(ostream &out) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPManifest::
 void CPPManifest::
 parse_parameters(const string &args, size_t &p, 
 parse_parameters(const string &args, size_t &p, 
-		 vector_string &parameter_names) {
+                 vector_string &parameter_names) {
   assert(p < args.size());
   assert(p < args.size());
   assert(args[p] == '(');
   assert(args[p] == '(');
 
 
@@ -185,7 +185,7 @@ parse_parameters(const string &args, size_t &p,
     // Here's the beginning of a parm.
     // Here's the beginning of a parm.
     size_t q = p;
     size_t q = p;
     while (p < args.size() && !isspace(args[p]) && 
     while (p < args.size() && !isspace(args[p]) && 
-	   args[p] != ')' && args[p] != ',') {
+           args[p] != ')' && args[p] != ',') {
       p++;
       p++;
     }
     }
     parameter_names.push_back(args.substr(q, p - q));
     parameter_names.push_back(args.substr(q, p - q));
@@ -199,7 +199,7 @@ parse_parameters(const string &args, size_t &p,
       p++;
       p++;
       // Skip whitespace after a comma.
       // Skip whitespace after a comma.
       while (p < args.size() && isspace(args[p])) {
       while (p < args.size() && isspace(args[p])) {
-	p++;
+        p++;
       }
       }
     }
     }
   }
   }
@@ -228,7 +228,7 @@ save_expansion(const string &exp, const vector_string &parameter_names) {
       size_t q = p;
       size_t q = p;
       p++;
       p++;
       while (p < exp.size() && isalnum(exp[p]) || exp[p] == '_') {
       while (p < exp.size() && isalnum(exp[p]) || exp[p] == '_') {
-	p++;
+        p++;
       }
       }
 
 
       string ident = exp.substr(q, p - q);
       string ident = exp.substr(q, p - q);
@@ -236,18 +236,18 @@ save_expansion(const string &exp, const vector_string &parameter_names) {
       // Is this identifier one of our parameters?
       // Is this identifier one of our parameters?
       int pnum = -1;
       int pnum = -1;
       for (int i = 0; pnum == -1 && i < (int)parameter_names.size(); i++) {
       for (int i = 0; pnum == -1 && i < (int)parameter_names.size(); i++) {
-	if (parameter_names[i] == ident) {
-	  pnum = i;
-	}
+        if (parameter_names[i] == ident) {
+          pnum = i;
+        }
       }
       }
       
       
       if (pnum != -1) {
       if (pnum != -1) {
-	// Yep!
-	if (last != q) {
-	  _expansion.push_back(ExpansionNode(exp.substr(last, q - last)));
-	}
-	_expansion.push_back(pnum);
-	last = p;
+        // Yep!
+        if (last != q) {
+          _expansion.push_back(ExpansionNode(exp.substr(last, q - last)));
+        }
+        _expansion.push_back(pnum);
+        last = p;
       }
       }
     } else {
     } else {
       p++;
       p++;

+ 3 - 3
dtool/src/cppparser/cppManifest.h

@@ -17,7 +17,7 @@ class CPPExpression;
 class CPPType;
 class CPPType;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPManifest
+//       Class : CPPManifest
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPManifest {
 class CPPManifest {
@@ -44,9 +44,9 @@ public:
 
 
 private:
 private:
   void parse_parameters(const string &args, size_t &p,
   void parse_parameters(const string &args, size_t &p,
-			vector_string &parameter_names);
+                        vector_string &parameter_names);
   void save_expansion(const string &exp,
   void save_expansion(const string &exp,
-		      const vector_string &parameter_names);
+                      const vector_string &parameter_names);
 
 
   class ExpansionNode {
   class ExpansionNode {
   public:
   public:

+ 3 - 3
dtool/src/cppparser/cppNamespace.h

@@ -14,13 +14,13 @@ class CPPIdentifier;
 class CPPScope;
 class CPPScope;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPNamespace
+//       Class : CPPNamespace
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPNamespace : public CPPDeclaration {
 class CPPNamespace : public CPPDeclaration {
 public:
 public:
   CPPNamespace(CPPIdentifier *ident, CPPScope *scope,
   CPPNamespace(CPPIdentifier *ident, CPPScope *scope,
-	       const CPPFile &file);
+               const CPPFile &file);
 
 
   string get_simple_name() const;
   string get_simple_name() const;
   string get_local_name(CPPScope *scope = NULL) const;
   string get_local_name(CPPScope *scope = NULL) const;
@@ -28,7 +28,7 @@ public:
   CPPScope *get_scope() const;
   CPPScope *get_scope() const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPNamespace *as_namespace();
   virtual CPPNamespace *as_namespace();

+ 7 - 7
dtool/src/cppparser/cppParameterList.cxx

@@ -144,7 +144,7 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPParameterList *CPPParameterList::
 CPPParameterList *CPPParameterList::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPParameterList *rep = new CPPParameterList;
   CPPParameterList *rep = new CPPParameterList;
   bool any_changed = false;
   bool any_changed = false;
   for (int i = 0; i < (int)_parameters.size(); i++) {
   for (int i = 0; i < (int)_parameters.size(); i++) {
@@ -212,7 +212,7 @@ output(ostream &out, CPPScope *scope, bool parameter_names,
   if (!_parameters.empty()) {
   if (!_parameters.empty()) {
     for (int i = 0; i < (int)_parameters.size(); i++) {
     for (int i = 0; i < (int)_parameters.size(); i++) {
       if (i != 0) {
       if (i != 0) {
-	out << ", ";
+        out << ", ";
       }
       }
 
 
       // Save the default value expression; we might be about to
       // Save the default value expression; we might be about to
@@ -220,15 +220,15 @@ output(ostream &out, CPPScope *scope, bool parameter_names,
       CPPExpression *expr = _parameters[i]->_initializer;
       CPPExpression *expr = _parameters[i]->_initializer;
 
 
       if (num_default_parameters >= 0 &&
       if (num_default_parameters >= 0 &&
-	  i < (int)_parameters.size() - num_default_parameters) {
-	// Don't show the default value for this parameter.
-	_parameters[i]->_initializer = (CPPExpression *)NULL;
+          i < (int)_parameters.size() - num_default_parameters) {
+        // Don't show the default value for this parameter.
+        _parameters[i]->_initializer = (CPPExpression *)NULL;
       }
       }
 
 
       if (parameter_names) {
       if (parameter_names) {
-	_parameters[i]->output(out, 0, scope, false);
+        _parameters[i]->output(out, 0, scope, false);
       } else {
       } else {
-	_parameters[i]->_type->output(out, 0, scope, false);
+        _parameters[i]->_type->output(out, 0, scope, false);
       }
       }
 
 
       // Restore the default value expression.
       // Restore the default value expression.

+ 5 - 5
dtool/src/cppparser/cppParameterList.h

@@ -16,7 +16,7 @@ class CPPInstance;
 class CPPScope;
 class CPPScope;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPParameterList
+//       Class : CPPParameterList
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPParameterList {
 class CPPParameterList {
@@ -33,11 +33,11 @@ public:
 
 
   bool is_fully_specified() const;
   bool is_fully_specified() const;
   CPPParameterList *substitute_decl(CPPDeclaration::SubstDecl &subst,
   CPPParameterList *substitute_decl(CPPDeclaration::SubstDecl &subst,
-				    CPPScope *current_scope,
-				    CPPScope *global_scope);
+                                    CPPScope *current_scope,
+                                    CPPScope *global_scope);
 
 
   CPPParameterList *resolve_type(CPPScope *current_scope,
   CPPParameterList *resolve_type(CPPScope *current_scope,
-				 CPPScope *global_scope);
+                                 CPPScope *global_scope);
 
 
   // This vector contains a list of formal parameters, in order.  A
   // This vector contains a list of formal parameters, in order.  A
   // parameter may have an empty identifer name.
   // parameter may have an empty identifer name.
@@ -46,7 +46,7 @@ public:
   bool _includes_ellipsis;
   bool _includes_ellipsis;
 
 
   void output(ostream &out, CPPScope *scope, bool parameter_names,
   void output(ostream &out, CPPScope *scope, bool parameter_names,
-	      int num_default_parameters = -1) const;
+              int num_default_parameters = -1) const;
 };
 };
 
 
 inline ostream &
 inline ostream &

+ 1 - 1
dtool/src/cppparser/cppParser.h

@@ -14,7 +14,7 @@
 #include <set>
 #include <set>
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPParser
+//       Class : CPPParser
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPParser : public CPPScope, public CPPPreprocessor {
 class CPPParser : public CPPScope, public CPPPreprocessor {

+ 4 - 4
dtool/src/cppparser/cppPointerType.cxx

@@ -41,7 +41,7 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPPointerType::
 CPPDeclaration *CPPPointerType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;
@@ -142,8 +142,8 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPointerType::
 void CPPPointerType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   string star = "*";
   string star = "*";
 
 
   CPPFunctionType *ftype = _pointing_at->as_function_type();
   CPPFunctionType *ftype = _pointing_at->as_function_type();
@@ -155,7 +155,7 @@ output_instance(ostream &out, int indent_level, CPPScope *scope,
   }
   }
 
 
   _pointing_at->output_instance(out, indent_level, scope, complete, 
   _pointing_at->output_instance(out, indent_level, scope, complete, 
-				star + prename, name);
+                                star + prename, name);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 8 - 8
dtool/src/cppparser/cppPointerType.h

@@ -20,7 +20,7 @@
 #include "cppType.h"
 #include "cppType.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPPointerType
+//       Class : CPPPointerType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPPointerType : public CPPType {
 class CPPPointerType : public CPPType {
@@ -31,21 +31,21 @@ public:
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
   virtual bool is_equivalent(const CPPType &other) const;
   virtual bool is_equivalent(const CPPType &other) const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
 
 
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 

+ 246 - 246
dtool/src/cppparser/cppPreprocessor.cxx

@@ -332,75 +332,75 @@ get_next_token0() {
       // parse the template parameters.
       // parse the template parameters.
       CPPDeclaration *decl = ident->find_template(current_scope, global_scope);
       CPPDeclaration *decl = ident->find_template(current_scope, global_scope);
       if (decl != NULL) {
       if (decl != NULL) {
-	ident->_names.back().set_templ
-	  (nested_parse_template_instantiation(decl->get_template_scope()));
-	token = internal_get_next_token();
+        ident->_names.back().set_templ
+          (nested_parse_template_instantiation(decl->get_template_scope()));
+        token = internal_get_next_token();
       }
       }
     }
     }
 
 
     while (token._token == SCOPE || token._token == TOKENPASTE) {
     while (token._token == SCOPE || token._token == TOKENPASTE) {
       if (token._token == TOKENPASTE) {
       if (token._token == TOKENPASTE) {
-	// The token-pasting operator creates one continuous
-	// identifier across whitespace.
-	token = internal_get_next_token();
-	if (token._token == SIMPLE_IDENTIFIER) {
-	  name += token._lval.str;
-	  ident->_names.back().append_name(token._lval.str);
+        // The token-pasting operator creates one continuous
+        // identifier across whitespace.
+        token = internal_get_next_token();
+        if (token._token == SIMPLE_IDENTIFIER) {
+          name += token._lval.str;
+          ident->_names.back().append_name(token._lval.str);
 
 
-	  token = internal_get_next_token();
+          token = internal_get_next_token();
 
 
-	} else {
-	  // Token-paste with nothing.
-	}
+        } else {
+          // Token-paste with nothing.
+        }
 
 
       } else { // token._token == SCOPE
       } else { // token._token == SCOPE
-	name += "::";
-	token = internal_get_next_token();
-	string token_prefix;
-
-	if (token._token == '~') {
-	  // A scoping operator followed by a tilde can only be the
-	  // start of a scoped destructor name.  Make the tilde be part
-	  // of the name.
-	  name += "~";
-	  token_prefix = "~";
-	  token = internal_get_next_token();
-	}
-	
-	if (token._token != SIMPLE_IDENTIFIER) {
-	  // The last useful token was a SCOPE, thus this is a scoping
-	  // token.
-	  
-	  if (token._token == KW_OPERATOR) {
-	    // Unless the last token we came across was the "operator"
-	    // keyword.  We make a special case for this, because it's
-	    // occasionally scoped in normal use.
-	    token._lval = result;
-	    return token;
-	  }
-	  _saved_tokens.push_back(token);
-	  return CPPToken(SCOPING, first_line, first_col, first_file, 
-			  name, result);
-	}
-
-	name += token._lval.str;
-	ident->_names.push_back(token_prefix + token._lval.str);
-
-	token = internal_get_next_token();
+        name += "::";
+        token = internal_get_next_token();
+        string token_prefix;
+
+        if (token._token == '~') {
+          // A scoping operator followed by a tilde can only be the
+          // start of a scoped destructor name.  Make the tilde be part
+          // of the name.
+          name += "~";
+          token_prefix = "~";
+          token = internal_get_next_token();
+        }
+
+        if (token._token != SIMPLE_IDENTIFIER) {
+          // The last useful token was a SCOPE, thus this is a scoping
+          // token.
+
+          if (token._token == KW_OPERATOR) {
+            // Unless the last token we came across was the "operator"
+            // keyword.  We make a special case for this, because it's
+            // occasionally scoped in normal use.
+            token._lval = result;
+            return token;
+          }
+          _saved_tokens.push_back(token);
+          return CPPToken(SCOPING, first_line, first_col, first_file, 
+                          name, result);
+        }
+
+        name += token._lval.str;
+        ident->_names.push_back(token_prefix + token._lval.str);
+
+        token = internal_get_next_token();
       }
       }
 
 
       if (token._token == '<') {
       if (token._token == '<') {
-	// If the next token is an angle bracket and the current
-	// indentifier wants template instantiation, assume the angle
-	// bracket begins the instantiation and call yacc recursively to
-	// parse the template parameters.
-	CPPDeclaration *decl = 
-	  ident->find_template(current_scope, global_scope);
-	if (decl != NULL) {
-	  ident->_names.back().set_templ
-	    (nested_parse_template_instantiation(decl->get_template_scope()));
-	  token = internal_get_next_token();
-	}
+        // If the next token is an angle bracket and the current
+        // indentifier wants template instantiation, assume the angle
+        // bracket begins the instantiation and call yacc recursively to
+        // parse the template parameters.
+        CPPDeclaration *decl = 
+          ident->find_template(current_scope, global_scope);
+        if (decl != NULL) {
+          ident->_names.back().set_templ
+            (nested_parse_template_instantiation(decl->get_template_scope()));
+          token = internal_get_next_token();
+        }
       }
       }
     }
     }
     // The last useful token was a SIMPLE_IDENTIFIER, thus this is a
     // The last useful token was a SIMPLE_IDENTIFIER, thus this is a
@@ -410,12 +410,12 @@ get_next_token0() {
     int token_type = IDENTIFIER;
     int token_type = IDENTIFIER;
     CPPDeclaration *decl = ident->find_symbol(current_scope, global_scope);
     CPPDeclaration *decl = ident->find_symbol(current_scope, global_scope);
     if (decl != NULL && 
     if (decl != NULL && 
-	(decl->as_typedef() != NULL || decl->as_type() != NULL)) {
+        (decl->as_typedef() != NULL || decl->as_type() != NULL)) {
       token_type = TYPENAME_IDENTIFIER;
       token_type = TYPENAME_IDENTIFIER;
     }
     }
 
 
     return CPPToken(token_type, first_line, first_col, first_file, 
     return CPPToken(token_type, first_line, first_col, first_file, 
-		    name, result);
+                    name, result);
   }
   }
 
 
   // This is the normal case: just pass through whatever token we got.
   // This is the normal case: just pass through whatever token we got.
@@ -438,8 +438,8 @@ warning(const string &message, int line, int col, CPPFile file) {
       file = get_file();
       file = get_file();
     }
     }
     cerr << "\nWarning in " << file
     cerr << "\nWarning in " << file
-	 << " near line " << line << ", column " << col << ":\n"
-	 << message << "\n";
+         << " near line " << line << ", column " << col << ":\n"
+         << message << "\n";
   }
   }
   _warning_count++;
   _warning_count++;
 }
 }
@@ -466,8 +466,8 @@ error(const string &message, int line, int col, CPPFile file) {
       file = get_file();
       file = get_file();
     }
     }
     cerr << "\nError in " << file
     cerr << "\nError in " << file
-	 << " near line " << line << ", column " << col << ":\n"
-	 << message << "\n";
+         << " near line " << line << ", column " << col << ":\n"
+         << message << "\n";
   }
   }
   _error_count++;
   _error_count++;
 }
 }
@@ -510,16 +510,16 @@ get_comment_before(int line, CPPFile file) {
     if (comment->_file == file) {
     if (comment->_file == file) {
       wrong_file_count = 0;
       wrong_file_count = 0;
       if (comment->_last_line == line || comment->_last_line == line - 1) {
       if (comment->_last_line == line || comment->_last_line == line - 1) {
-	return comment;
+        return comment;
       }
       }
 
 
       if (comment->_last_line < line) {
       if (comment->_last_line < line) {
-	return (CPPCommentBlock *)NULL;
+        return (CPPCommentBlock *)NULL;
       }
       }
     } else {
     } else {
       wrong_file_count++;
       wrong_file_count++;
       if (wrong_file_count > 10) {
       if (wrong_file_count > 10) {
-	return (CPPCommentBlock *)NULL;
+        return (CPPCommentBlock *)NULL;
       }
       }
     }
     }
 
 
@@ -651,7 +651,7 @@ push_string(const string &input, bool lock_position) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPExpression *CPPPreprocessor::
 CPPExpression *CPPPreprocessor::
 parse_expr(const string &input_expr, CPPScope *current_scope, 
 parse_expr(const string &input_expr, CPPScope *current_scope, 
-	   CPPScope *global_scope) {
+           CPPScope *global_scope) {
   // Get a copy of the expression string we can modify.
   // Get a copy of the expression string we can modify.
   string expr = input_expr;
   string expr = input_expr;
 
 
@@ -668,28 +668,28 @@ parse_expr(const string &input_expr, CPPScope *current_scope,
     size_t p = 0;
     size_t p = 0;
     while (p < expr.size()) {
     while (p < expr.size()) {
       if (isalpha(expr[p]) || expr[p] == '_') {
       if (isalpha(expr[p]) || expr[p] == '_') {
-	size_t q = p;
-	while (p < expr.size() && (isalnum(expr[p]) || expr[p] == '_')) {
-	  p++;
-	}
-	string ident = expr.substr(q, p - q);
-	
-	// Here's an identifier.  Is it "defined"?
-	if (ident == "defined") {
-	  expand_defined_function(expr, q, p);
-	} else {
-	  // Is it a manifest?
-	  Manifests::const_iterator mi = _manifests.find(ident);
-	  if (mi != _manifests.end()) {
-	    const CPPManifest *manifest = (*mi).second;
-	    if (already_expanded.insert(manifest).second) {
-	      expand_manifest_inline(expr, q, p, (*mi).second);
-	      manifest_found = true;
-	    }
-	  }
-	}
+        size_t q = p;
+        while (p < expr.size() && (isalnum(expr[p]) || expr[p] == '_')) {
+          p++;
+        }
+        string ident = expr.substr(q, p - q);
+
+        // Here's an identifier.  Is it "defined"?
+        if (ident == "defined") {
+          expand_defined_function(expr, q, p);
+        } else {
+          // Is it a manifest?
+          Manifests::const_iterator mi = _manifests.find(ident);
+          if (mi != _manifests.end()) {
+            const CPPManifest *manifest = (*mi).second;
+            if (already_expanded.insert(manifest).second) {
+              expand_manifest_inline(expr, q, p, (*mi).second);
+              manifest_found = true;
+            }
+          }
+        }
       } else {
       } else {
-	p++;
+        p++;
       }
       }
     }
     }
 
 
@@ -869,16 +869,16 @@ internal_get_next_token() {
 
 
     case ',':
     case ',':
       if (_paren_nesting <= 0) {
       if (_paren_nesting <= 0) {
-	_state = S_end_nested;
-	return CPPToken::eof();
+        _state = S_end_nested;
+        return CPPToken::eof();
       }
       }
       break;
       break;
 
 
     case '>':
     case '>':
       if (_paren_nesting <= 0) {
       if (_paren_nesting <= 0) {
-	_angle_bracket_found = true;
-	_state = S_end_nested;
-	return CPPToken::eof();
+        _angle_bracket_found = true;
+        _state = S_end_nested;
+        return CPPToken::eof();
       }
       }
     }
     }
   }
   }
@@ -958,22 +958,22 @@ skip_c_comment(int c) {
 
 
     while (c != EOF) {
     while (c != EOF) {
       if (c == '*') {
       if (c == '*') {
-	comment->_comment += c;
-	c = get();
-	if (c == '/') {
-	  comment->_comment += c;
-	  comment->_last_line = get_line_number();
-	  return get();
-	}
+        comment->_comment += c;
+        c = get();
+        if (c == '/') {
+          comment->_comment += c;
+          comment->_last_line = get_line_number();
+          return get();
+        }
       } else {
       } else {
-	comment->_comment += c;
-	c = get();
+        comment->_comment += c;
+        c = get();
       }
       }
     }
     }
     
     
     warning("Comment is unterminated", 
     warning("Comment is unterminated", 
-	    comment->_line_number, comment->_col_number, 
-	    comment->_file);
+            comment->_line_number, comment->_col_number, 
+            comment->_file);
 
 
   } else {
   } else {
     CPPFile first_file = get_file();
     CPPFile first_file = get_file();
@@ -982,18 +982,18 @@ skip_c_comment(int c) {
     
     
     while (c != EOF) {
     while (c != EOF) {
       if (c == '*') {
       if (c == '*') {
-	c = get();
-	if (c == '/') {
-	  return get();
-	}
+        c = get();
+        if (c == '/') {
+          return get();
+        }
       } else {
       } else {
-	c = get();
+        c = get();
       }
       }
     }
     }
     
     
     warning("Comment is unterminated", 
     warning("Comment is unterminated", 
-	    first_line_number, first_col_number, 
-	    first_file);
+            first_line_number, first_col_number, 
+            first_file);
   }
   }
   
   
   return c;
   return c;
@@ -1097,7 +1097,7 @@ process_directive(int c) {
     handle_error_directive(args, first_line, first_col, first_file);
     handle_error_directive(args, first_line, first_col, first_file);
   } else {
   } else {
     warning("Ignoring unknown directive #" + command,
     warning("Ignoring unknown directive #" + command,
-	    first_line, first_col, first_file);
+            first_line, first_col, first_file);
   }
   }
 
 
   _start_of_line = true;
   _start_of_line = true;
@@ -1144,14 +1144,14 @@ get_preprocessor_args(int c, string &args) {
     if (c == '\\') {
     if (c == '\\') {
       int next_c = get();
       int next_c = get();
       if (next_c == '\n') {
       if (next_c == '\n') {
-	// Here we have an escaped newline: a continuation.
-	args += '\n';
+        // Here we have an escaped newline: a continuation.
+        args += '\n';
       } else {
       } else {
-	// Just a backslash followed by some non-backslash, keep both.
-	args += c;
-	if (next_c != EOF) {
-	  args += next_c;
-	}
+        // Just a backslash followed by some non-backslash, keep both.
+        args += c;
+        if (next_c != EOF) {
+          args += next_c;
+        }
       }
       }
     } else {
     } else {
       args += c;
       args += c;
@@ -1172,17 +1172,17 @@ get_preprocessor_args(int c, string &args) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 handle_define_directive(const string &args, int first_line, 
 handle_define_directive(const string &args, int first_line, 
-			int first_col, const CPPFile &first_file) {
+                        int first_col, const CPPFile &first_file) {
   if (args.empty()) {
   if (args.empty()) {
     warning("Ignoring empty #define directive",
     warning("Ignoring empty #define directive",
-	    first_line, first_col, first_file);
+            first_line, first_col, first_file);
   } else {
   } else {
     CPPManifest *manifest = new CPPManifest(args, first_file);
     CPPManifest *manifest = new CPPManifest(args, first_file);
     manifest->_vis = preprocessor_vis;
     manifest->_vis = preprocessor_vis;
     if (!manifest->_has_parameters) {
     if (!manifest->_has_parameters) {
       string expr_string = manifest->expand();
       string expr_string = manifest->expand();
       if (!expr_string.empty()) {
       if (!expr_string.empty()) {
-	manifest->_expr = parse_expr(expr_string, global_scope, global_scope);
+        manifest->_expr = parse_expr(expr_string, global_scope, global_scope);
       }
       }
     }
     }
     _manifests[manifest->_name] = manifest;
     _manifests[manifest->_name] = manifest;
@@ -1196,10 +1196,10 @@ handle_define_directive(const string &args, int first_line,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 handle_undef_directive(const string &args, int first_line, 
 handle_undef_directive(const string &args, int first_line, 
-		       int first_col, const CPPFile &first_file) {
+                       int first_col, const CPPFile &first_file) {
   if (args.empty()) {
   if (args.empty()) {
     warning("Ignoring empty #undef directive",
     warning("Ignoring empty #undef directive",
-	    first_line, first_col, first_file);
+            first_line, first_col, first_file);
   } else {
   } else {
     Manifests::iterator mi = _manifests.find(args);
     Manifests::iterator mi = _manifests.find(args);
     if (mi != _manifests.end()) {
     if (mi != _manifests.end()) {
@@ -1250,7 +1250,7 @@ handle_ifndef_directive(const string &args, int, int, const CPPFile &) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 handle_if_directive(const string &args, int first_line, 
 handle_if_directive(const string &args, int first_line, 
-		    int first_col, const CPPFile &first_file) {
+                    int first_col, const CPPFile &first_file) {
   CPPExpression *expr = parse_expr(args, global_scope, global_scope);
   CPPExpression *expr = parse_expr(args, global_scope, global_scope);
 
 
   int expression_result = 0;
   int expression_result = 0;
@@ -1259,13 +1259,13 @@ handle_if_directive(const string &args, int first_line,
     CPPExpression::Result result = expr->evaluate();
     CPPExpression::Result result = expr->evaluate();
     if (result._type == CPPExpression::RT_error) {
     if (result._type == CPPExpression::RT_error) {
       warning("Ignoring invalid expression " + args,
       warning("Ignoring invalid expression " + args,
-	      first_line, first_col, first_file);
+              first_line, first_col, first_file);
     } else {
     } else {
       expression_result = result.as_integer();
       expression_result = result.as_integer();
     }
     }
   } else {
   } else {
     warning("Ignoring invalid expression " + args,
     warning("Ignoring invalid expression " + args,
-	    first_line, first_col, first_file);
+            first_line, first_col, first_file);
   }
   }
 
 
   if (expression_result) {
   if (expression_result) {
@@ -1284,7 +1284,7 @@ handle_if_directive(const string &args, int first_line,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 handle_include_directive(const string &args, int first_line, 
 handle_include_directive(const string &args, int first_line, 
-			 int first_col, const CPPFile &first_file) {
+                         int first_col, const CPPFile &first_file) {
   bool okflag = false;
   bool okflag = false;
   Filename filename;
   Filename filename;
   Filename filename_as_referenced;
   Filename filename_as_referenced;
@@ -1296,10 +1296,10 @@ handle_include_directive(const string &args, int first_line,
       okflag = true;
       okflag = true;
 
 
       if (_files.size() == 1) {
       if (_files.size() == 1) {
-	// If we're currently processing a top-level file, record the
-	// include directive.  We don't need to record includes from
-	// included files.
-	_quote_includes.insert(filename);
+        // If we're currently processing a top-level file, record the
+        // include directive.  We don't need to record includes from
+        // included files.
+        _quote_includes.insert(filename);
       }
       }
     } else if (args[0] == '<' && args[args.size() - 1] == '>') {
     } else if (args[0] == '<' && args[args.size() - 1] == '>') {
       filename = args.substr(1, args.size() - 2);
       filename = args.substr(1, args.size() - 2);
@@ -1307,10 +1307,10 @@ handle_include_directive(const string &args, int first_line,
       okflag = true;
       okflag = true;
 
 
       if (_files.size() == 1) {
       if (_files.size() == 1) {
-	// If we're currently processing a top-level file, record the
-	// include directive.  We don't need to record includes from
-	// included files.
-	_angle_includes.insert(filename);
+        // If we're currently processing a top-level file, record the
+        // include directive.  We don't need to record includes from
+        // included files.
+        _angle_includes.insert(filename);
       }
       }
     }
     }
   }
   }
@@ -1342,17 +1342,17 @@ handle_include_directive(const string &args, int first_line,
     
     
     if (!found_file) {
     if (!found_file) {
       warning("Cannot find " + filename.get_fullpath(),
       warning("Cannot find " + filename.get_fullpath(),
-	      first_line, first_col, first_file);
+              first_line, first_col, first_file);
     } else {
     } else {
       _last_c = '\0';
       _last_c = '\0';
       if (!push_file(CPPFile(filename, filename_as_referenced, source))) {
       if (!push_file(CPPFile(filename, filename_as_referenced, source))) {
-	warning("Unable to read " + filename.get_fullpath(),
-		first_line, first_col, first_file);
+        warning("Unable to read " + filename.get_fullpath(),
+                first_line, first_col, first_file);
       }
       }
     }
     }
   } else {
   } else {
     warning("Ignoring invalid #include directive",
     warning("Ignoring invalid #include directive",
-	    first_line, first_col, first_file);
+            first_line, first_col, first_file);
   }
   }
 }
 }
   
   
@@ -1363,7 +1363,7 @@ handle_include_directive(const string &args, int first_line,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 handle_error_directive(const string &args, int first_line, 
 handle_error_directive(const string &args, int first_line, 
-		       int first_col, const CPPFile &first_file) {
+                       int first_col, const CPPFile &first_file) {
   error(args, first_line, first_col, first_file);
   error(args, first_line, first_col, first_file);
 }
 }
 
 
@@ -1391,30 +1391,30 @@ skip_false_if_block(bool consider_elifs) {
       string command;
       string command;
       c = get_preprocessor_command(c, command);
       c = get_preprocessor_command(c, command);
       if (command == "if" || command == "ifdef" || command == "ifndef") {
       if (command == "if" || command == "ifdef" || command == "ifndef") {
-	// Hmm, a nested if block.  Even more to skip.
-	level++;
+        // Hmm, a nested if block.  Even more to skip.
+        level++;
       } else if (command == "else") {
       } else if (command == "else") {
-	if (level == 0 && consider_elifs) {
-	  // This will do!
-	  _save_comments = true;
-	  return;
-	}
+        if (level == 0 && consider_elifs) {
+          // This will do!
+          _save_comments = true;
+          return;
+        }
       } else if (command == "elif") {
       } else if (command == "elif") {
-	if (level == 0 && consider_elifs) {
-	  // If we pass this test, we're in.
-	  _save_comments = true;
-	  string args;
-	  c = get_preprocessor_args(c, args);
-	  handle_if_directive(args, first_line, first_col, first_file);
-	  return;
-	}
+        if (level == 0 && consider_elifs) {
+          // If we pass this test, we're in.
+          _save_comments = true;
+          string args;
+          c = get_preprocessor_args(c, args);
+          handle_if_directive(args, first_line, first_col, first_file);
+          return;
+        }
       } else if (command == "endif") {
       } else if (command == "endif") {
-	if (level == 0) {
-	  // Here's the end!
-	  _save_comments = true;
-	  return;
-	}
-	level--;
+        if (level == 0) {
+          // Here's the end!
+          _save_comments = true;
+          return;
+        }
+        level--;
       }
       }
     } else {
     } else {
       c = skip_comment(get());
       c = skip_comment(get());
@@ -1506,7 +1506,7 @@ get_identifier(int c) {
   }
   }
 
 
   return CPPToken(SIMPLE_IDENTIFIER, first_line, first_col, first_file,
   return CPPToken(SIMPLE_IDENTIFIER, first_line, first_col, first_file,
-		  name);
+                  name);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
@@ -1546,7 +1546,7 @@ expand_manifest(const CPPManifest *manifest) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 extract_manifest_args(const string &name, int num_args, 
 extract_manifest_args(const string &name, int num_args, 
-		      vector_string &args) {
+                      vector_string &args) {
   CPPFile first_file = get_file();
   CPPFile first_file = get_file();
   int first_line = get_line_number();
   int first_line = get_line_number();
   int first_col = get_col_number();
   int first_col = get_col_number();
@@ -1572,27 +1572,27 @@ extract_manifest_args(const string &name, int num_args,
     string arg;
     string arg;
     while (c != EOF && c != ')') {
     while (c != EOF && c != ')') {
       if (c == ',') {
       if (c == ',') {
-	args.push_back(arg);
-	arg = "";
+        args.push_back(arg);
+        arg = "";
 
 
       } else if (c == '(') {
       } else if (c == '(') {
-	// Nested parens.
-	int paren_level = 1;
-	while (c != EOF && paren_level > 0) {
-	  arg += c;
-	  c = get();
-	  if (c == '(') {
-	    paren_level++;
-	  } else if (c == ')') {
-	    paren_level--;
-	  }
-	}
-	if (c != EOF) {
-	  arg += c;
-	}
-	  
+        // Nested parens.
+        int paren_level = 1;
+        while (c != EOF && paren_level > 0) {
+          arg += c;
+          c = get();
+          if (c == '(') {
+            paren_level++;
+          } else if (c == ')') {
+            paren_level--;
+          }
+        }
+        if (c != EOF) {
+          arg += c;
+        }
+
       } else {
       } else {
-	arg += c;
+        arg += c;
       }
       }
       c = get();
       c = get();
     }
     }
@@ -1603,7 +1603,7 @@ extract_manifest_args(const string &name, int num_args,
 
 
   if ((int)args.size() != num_args) {
   if ((int)args.size() != num_args) {
     warning("Wrong number of arguments for manifest " + name,
     warning("Wrong number of arguments for manifest " + name,
-	    first_line, first_col, first_file);
+            first_line, first_col, first_file);
   }
   }
 }
 }
 
 
@@ -1641,11 +1641,11 @@ expand_defined_function(string &expr, size_t q, size_t &p) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 expand_manifest_inline(string &expr, size_t q, size_t &p,
 expand_manifest_inline(string &expr, size_t q, size_t &p,
-		       const CPPManifest *manifest) {
+                       const CPPManifest *manifest) {
   vector_string args;
   vector_string args;
   if (manifest->_has_parameters) {
   if (manifest->_has_parameters) {
     extract_manifest_args_inline(manifest->_name, manifest->_num_parameters,
     extract_manifest_args_inline(manifest->_name, manifest->_num_parameters,
-				 args, expr, p);
+                                 args, expr, p);
   }
   }
   string result = manifest->expand(args);
   string result = manifest->expand(args);
 
 
@@ -1660,8 +1660,8 @@ expand_manifest_inline(string &expr, size_t q, size_t &p,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPPreprocessor::
 void CPPPreprocessor::
 extract_manifest_args_inline(const string &name, int num_args, 
 extract_manifest_args_inline(const string &name, int num_args, 
-			     vector_string &args,
-			     const string &expr, size_t &p) {
+                             vector_string &args,
+                             const string &expr, size_t &p) {
   // Skip whitespace till paren.
   // Skip whitespace till paren.
   while (p < expr.size() && isspace(expr[p])) {
   while (p < expr.size() && isspace(expr[p])) {
     p++;
     p++;
@@ -1679,20 +1679,20 @@ extract_manifest_args_inline(const string &name, int num_args,
     size_t q = p;
     size_t q = p;
     while (p < expr.size() && expr[p] != ')') {
     while (p < expr.size() && expr[p] != ')') {
       if (expr[p] == ',') {
       if (expr[p] == ',') {
-	args.push_back(expr.substr(q, p - q));
-	q = p+1;
+        args.push_back(expr.substr(q, p - q));
+        q = p+1;
 
 
       } else if (expr[p] == '(') {
       } else if (expr[p] == '(') {
-	// Nested parens.
-	int paren_level = 1;
-	while (p+1 < expr.size() && paren_level > 0) {
-	  p++;
-	  if (expr[p] == '(') {
-	    paren_level++;
-	  } else if (expr[p] == ')') {
-	    paren_level--;
-	  }
-	}
+        // Nested parens.
+        int paren_level = 1;
+        while (p+1 < expr.size() && paren_level > 0) {
+          p++;
+          if (expr[p] == '(') {
+            paren_level++;
+          } else if (expr[p] == ')') {
+            paren_level--;
+          }
+        }
       }
       }
       p++;
       p++;
     }
     }
@@ -1773,12 +1773,12 @@ get_number(int c, int c2) {
       num += c;
       num += c;
       c = get();
       c = get();
       if (c == '-' || c == '+') {
       if (c == '-' || c == '+') {
-	num += c;
-	c = get();
+        num += c;
+        c = get();
       }
       }
       while (c != EOF && isdigit(c)) {
       while (c != EOF && isdigit(c)) {
-	num += c;
-	c = get();
+        num += c;
+        c = get();
       }
       }
     }
     }
 
 
@@ -1901,31 +1901,31 @@ scan_quoted(int c) {
       c = get();
       c = get();
       switch (c) {
       switch (c) {
       case 'n':
       case 'n':
-	c = '\n';
-	break;
+        c = '\n';
+        break;
 
 
       case 't':
       case 't':
-	c = '\t';
-	break;
+        c = '\t';
+        break;
 
 
       case 'r':
       case 'r':
-	c = '\r';
-	break;
+        c = '\r';
+        break;
 
 
       case 'x':
       case 'x':
-	// hex character.
-	c = get();
-	if (isxdigit(c)) {
-	  int val = hex_val(c);
-	  c = get();
-	  if (isxdigit(c)) {
-	    val = (val << 4) | hex_val(c);
-	  } else {
-	    unget(c);
-	  }
-	  c = val;
-	}
-	break;
+        // hex character.
+        c = get();
+        if (isxdigit(c)) {
+          int val = hex_val(c);
+          c = get();
+          if (isxdigit(c)) {
+            val = (val << 4) | hex_val(c);
+          } else {
+            unget(c);
+          }
+          c = val;
+        }
+        break;
 
 
       case '0':
       case '0':
       case '1':
       case '1':
@@ -1935,24 +1935,24 @@ scan_quoted(int c) {
       case '5':
       case '5':
       case '6':
       case '6':
       case '7':
       case '7':
-	// Octal character.
-	{
-	  int val = (c - '0');
-	  c = get();
-	  if (c >= '0' && c <= '7') {
-	    val = (val << 3) | (c - '0');
-	    c = get();
-	    if (c >= '0' && c <= '7') {
-	      val = (val << 3) | (c - '0');
-	    } else {
-	      unget(c);
-	    }
-	  } else {
-	    unget(c);
-	  }
-	  c = val;
-	}
-	break;
+        // Octal character.
+        {
+          int val = (c - '0');
+          c = get();
+          if (c >= '0' && c <= '7') {
+            val = (val << 3) | (c - '0');
+            c = get();
+            if (c >= '0' && c <= '7') {
+              val = (val << 3) | (c - '0');
+            } else {
+              unget(c);
+            }
+          } else {
+            unget(c);
+          }
+          c = val;
+        }
+        break;
       }
       }
     }
     }
 
 
@@ -2106,18 +2106,18 @@ nested_parse_template_instantiation(CPPTemplateScope *scope) {
       _saved_tokens.push_back(CPPToken(START_TYPE));
       _saved_tokens.push_back(CPPToken(START_TYPE));
       CPPType *type = ::parse_type(this, current_scope, global_scope);
       CPPType *type = ::parse_type(this, current_scope, global_scope);
       if (type == NULL) {
       if (type == NULL) {
-	warning("Invalid type", first_line, first_col, first_file);
-	skip_to_end_nested();
-	type = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_unknown));
+        warning("Invalid type", first_line, first_col, first_file);
+        skip_to_end_nested();
+        type = CPPType::new_type(new CPPSimpleType(CPPSimpleType::T_unknown));
       }
       }
       actual_params->_parameters.push_back(type);
       actual_params->_parameters.push_back(type);
     } else {
     } else {
       _saved_tokens.push_back(CPPToken(START_CONST_EXPR));
       _saved_tokens.push_back(CPPToken(START_CONST_EXPR));
       CPPExpression *expr = parse_const_expr(this, current_scope, global_scope);
       CPPExpression *expr = parse_const_expr(this, current_scope, global_scope);
       if (expr == NULL) {
       if (expr == NULL) {
-	warning("Invalid expression", first_line, first_col, first_file);
-	skip_to_end_nested();
-	expr = new CPPExpression(0);
+        warning("Invalid expression", first_line, first_col, first_file);
+        skip_to_end_nested();
+        expr = new CPPExpression(0);
       }
       }
       actual_params->_parameters.push_back(expr);
       actual_params->_parameters.push_back(expr);
     }
     }

+ 15 - 15
dtool/src/cppparser/cppPreprocessor.h

@@ -27,7 +27,7 @@ class CPPExpression;
 //#define CPP_VERBOSE_LEX
 //#define CPP_VERBOSE_LEX
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPPreprocessor
+//       Class : CPPPreprocessor
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPPreprocessor {
 class CPPPreprocessor {
@@ -50,9 +50,9 @@ public:
 #endif
 #endif
 
 
   void warning(const string &message, int line = 0, int col = 0,
   void warning(const string &message, int line = 0, int col = 0,
-	       CPPFile file = CPPFile());
+               CPPFile file = CPPFile());
   void error(const string &message, int line = 0, int col = 0,
   void error(const string &message, int line = 0, int col = 0,
-	     CPPFile file = CPPFile());
+             CPPFile file = CPPFile());
 
 
   CPPCommentBlock *get_comment_before(int line, CPPFile file);
   CPPCommentBlock *get_comment_before(int line, CPPFile file);
 
 
@@ -95,7 +95,7 @@ protected:
   bool push_string(const string &input, bool lock_position);
   bool push_string(const string &input, bool lock_position);
 
 
   CPPExpression *parse_expr(const string &expr, CPPScope *current_scope,
   CPPExpression *parse_expr(const string &expr, CPPScope *current_scope,
-			    CPPScope *global_scope);
+                            CPPScope *global_scope);
 
 
 private:
 private:
   CPPToken internal_get_next_token();
   CPPToken internal_get_next_token();
@@ -109,19 +109,19 @@ private:
   int get_preprocessor_args(int c, string &args);
   int get_preprocessor_args(int c, string &args);
 
 
   void handle_define_directive(const string &args, int first_line,
   void handle_define_directive(const string &args, int first_line,
-			       int first_col, const CPPFile &first_file);
+                               int first_col, const CPPFile &first_file);
   void handle_undef_directive(const string &args, int first_line,
   void handle_undef_directive(const string &args, int first_line,
-			      int first_col, const CPPFile &first_file);
+                              int first_col, const CPPFile &first_file);
   void handle_ifdef_directive(const string &args, int first_line,
   void handle_ifdef_directive(const string &args, int first_line,
-			      int first_col, const CPPFile &first_file);
+                              int first_col, const CPPFile &first_file);
   void handle_ifndef_directive(const string &args, int first_line,
   void handle_ifndef_directive(const string &args, int first_line,
-			       int first_col, const CPPFile &first_file);
+                               int first_col, const CPPFile &first_file);
   void handle_if_directive(const string &args, int first_line,
   void handle_if_directive(const string &args, int first_line,
-			   int first_col, const CPPFile &first_file);
+                           int first_col, const CPPFile &first_file);
   void handle_include_directive(const string &args, int first_line,
   void handle_include_directive(const string &args, int first_line,
-				int first_col, const CPPFile &first_file);
+                                int first_col, const CPPFile &first_file);
   void handle_error_directive(const string &args, int first_line,
   void handle_error_directive(const string &args, int first_line,
-			      int first_col, const CPPFile &first_file);
+                              int first_col, const CPPFile &first_file);
 
 
   void skip_false_if_block(bool consider_elifs);
   void skip_false_if_block(bool consider_elifs);
 
 
@@ -130,13 +130,13 @@ private:
   CPPToken get_identifier(int c);
   CPPToken get_identifier(int c);
   CPPToken expand_manifest(const CPPManifest *manifest);
   CPPToken expand_manifest(const CPPManifest *manifest);
   void extract_manifest_args(const string &name, int num_args,
   void extract_manifest_args(const string &name, int num_args,
-			     vector_string &args);
+                             vector_string &args);
   void expand_defined_function(string &expr, size_t q, size_t &p);
   void expand_defined_function(string &expr, size_t q, size_t &p);
   void expand_manifest_inline(string &expr, size_t q, size_t &p,
   void expand_manifest_inline(string &expr, size_t q, size_t &p,
-			      const CPPManifest *manifest);
+                              const CPPManifest *manifest);
   void extract_manifest_args_inline(const string &name, int num_args,
   void extract_manifest_args_inline(const string &name, int num_args,
-				    vector_string &args,
-				    const string &expr, size_t &p);
+                                    vector_string &args,
+                                    const string &expr, size_t &p);
 
 
   CPPToken get_number(int c, int c2 = 0);
   CPPToken get_number(int c, int c2 = 0);
   static int check_keyword(const string &name);
   static int check_keyword(const string &name);

+ 4 - 4
dtool/src/cppparser/cppReferenceType.cxx

@@ -39,7 +39,7 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPReferenceType::
 CPPDeclaration *CPPReferenceType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     return (*si).second;
     return (*si).second;
@@ -132,10 +132,10 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPReferenceType::
 void CPPReferenceType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   _pointing_at->output_instance(out, indent_level, scope, complete, 
   _pointing_at->output_instance(out, indent_level, scope, complete, 
-				"&" + prename, name);
+                                "&" + prename, name);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 8 - 8
dtool/src/cppparser/cppReferenceType.h

@@ -11,7 +11,7 @@
 #include "cppType.h"
 #include "cppType.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPReferenceType
+//       Class : CPPReferenceType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPReferenceType : public CPPType {
 class CPPReferenceType : public CPPType {
@@ -22,21 +22,21 @@ public:
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
   virtual bool is_equivalent(const CPPType &other) const;
   virtual bool is_equivalent(const CPPType &other) const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
 
 
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 

+ 93 - 93
dtool/src/cppparser/cppScope.cxx

@@ -30,7 +30,7 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope::
 CPPScope::
 CPPScope(CPPScope *parent_scope,
 CPPScope(CPPScope *parent_scope,
-	 const CPPNameComponent &name, CPPVisibility starting_vis) :
+         const CPPNameComponent &name, CPPVisibility starting_vis) :
   _name(name),
   _name(name),
   _parent_scope(parent_scope),
   _parent_scope(parent_scope),
   _current_vis(starting_vis)
   _current_vis(starting_vis)
@@ -113,7 +113,7 @@ get_current_vis() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPScope::
 void CPPScope::
 add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
 add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
-		CPPPreprocessor *preprocessor, const cppyyltype &pos) {
+                CPPPreprocessor *preprocessor, const cppyyltype &pos) {
   decl->_vis = _current_vis;
   decl->_vis = _current_vis;
 
 
   // Get the recent comments from the preprocessor.  These are the
   // Get the recent comments from the preprocessor.  These are the
@@ -215,7 +215,7 @@ define_namespace(CPPNamespace *scope) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPScope::
 void CPPScope::
 add_using(CPPUsing *using_decl, CPPScope *global_scope,
 add_using(CPPUsing *using_decl, CPPScope *global_scope,
-	  CPPPreprocessor *error_sink) {
+          CPPPreprocessor *error_sink) {
   if (using_decl->_full_namespace) {
   if (using_decl->_full_namespace) {
     CPPScope *scope = 
     CPPScope *scope = 
       using_decl->_ident->find_scope(this, global_scope);
       using_decl->_ident->find_scope(this, global_scope);
@@ -223,7 +223,7 @@ add_using(CPPUsing *using_decl, CPPScope *global_scope,
       _using.insert(scope);
       _using.insert(scope);
     } else {
     } else {
       if (error_sink != NULL) {
       if (error_sink != NULL) {
-	error_sink->warning("Attempt to use undefined namespace: " + using_decl->_ident->get_fully_scoped_name());
+        error_sink->warning("Attempt to use undefined namespace: " + using_decl->_ident->get_fully_scoped_name());
       }
       }
     }
     }
   } else {
   } else {
@@ -232,7 +232,7 @@ add_using(CPPUsing *using_decl, CPPScope *global_scope,
       handle_declaration(decl, global_scope);
       handle_declaration(decl, global_scope);
     } else {
     } else {
       if (error_sink != NULL) {
       if (error_sink != NULL) {
-	error_sink->warning("Attempt to use unknown symbol: " + using_decl->_ident->get_fully_scoped_name());
+        error_sink->warning("Attempt to use unknown symbol: " + using_decl->_ident->get_fully_scoped_name());
       }
       }
     }
     }
   }
   }
@@ -287,15 +287,15 @@ is_fully_specified() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPScope::
 CPPScope *CPPScope::
 instantiate(const CPPTemplateParameterList *actual_params,
 instantiate(const CPPTemplateParameterList *actual_params,
-	    CPPScope *current_scope, CPPScope *global_scope,
-	    CPPPreprocessor *error_sink) const {
+            CPPScope *current_scope, CPPScope *global_scope,
+            CPPPreprocessor *error_sink) const {
   CPPScope *this_scope = (CPPScope *)this;
   CPPScope *this_scope = (CPPScope *)this;
 
 
   if (_parent_scope == NULL || 
   if (_parent_scope == NULL || 
       _parent_scope->as_template_scope() == NULL) {
       _parent_scope->as_template_scope() == NULL) {
     if (error_sink != NULL) {
     if (error_sink != NULL) {
       error_sink->warning("Ignoring template parameters for scope " + 
       error_sink->warning("Ignoring template parameters for scope " + 
-			  get_local_name());
+                          get_local_name());
     }
     }
     return this_scope;
     return this_scope;
   }
   }
@@ -314,14 +314,14 @@ instantiate(const CPPTemplateParameterList *actual_params,
 
 
   /*
   /*
     cerr << "Instantiating " << get_simple_name()
     cerr << "Instantiating " << get_simple_name()
-	 << "<" << *actual_params << ">\n";
+         << "<" << *actual_params << ">\n";
   */
   */
 
 
   // Build the mapping of formal parameters to actual parameters.
   // Build the mapping of formal parameters to actual parameters.
   CPPTemplateScope *tscope = _parent_scope->as_template_scope();
   CPPTemplateScope *tscope = _parent_scope->as_template_scope();
   CPPDeclaration::SubstDecl subst;
   CPPDeclaration::SubstDecl subst;
   actual_params->build_subst_decl(tscope->_parameters, subst,
   actual_params->build_subst_decl(tscope->_parameters, subst,
-				  current_scope, global_scope);
+                                  current_scope, global_scope);
 
 
   CPPScope *scope;
   CPPScope *scope;
   if (subst.empty()) {
   if (subst.empty()) {
@@ -338,16 +338,16 @@ instantiate(const CPPTemplateParameterList *actual_params,
     // "instantiated" this scope with another template parameter.
     // "instantiated" this scope with another template parameter.
     CPPTemplateParameterList::Parameters::const_iterator pi;
     CPPTemplateParameterList::Parameters::const_iterator pi;
     for (pi = actual_params->_parameters.begin();
     for (pi = actual_params->_parameters.begin();
-	 pi != actual_params->_parameters.end();
-	 ++pi) {
+         pi != actual_params->_parameters.end();
+         ++pi) {
       CPPDeclaration *decl = (*pi);
       CPPDeclaration *decl = (*pi);
       CPPClassTemplateParameter *ctp = decl->as_class_template_parameter();
       CPPClassTemplateParameter *ctp = decl->as_class_template_parameter();
       if (ctp != NULL) {
       if (ctp != NULL) {
-	CPPInstance *inst = new CPPInstance(ctp, ctp->_ident);
-	CPPTypedef *td = new CPPTypedef(inst, true);
-	scope->_typedefs.insert(Typedefs::value_type
-				(ctp->_ident->get_local_name(),
-				 td));
+        CPPInstance *inst = new CPPInstance(ctp, ctp->_ident);
+        CPPTypedef *td = new CPPTypedef(inst, true);
+        scope->_typedefs.insert(Typedefs::value_type
+                                (ctp->_ident->get_local_name(),
+                                 td));
       }
       }
     }
     }
   }
   }
@@ -366,7 +366,7 @@ instantiate(const CPPTemplateParameterList *actual_params,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPScope::
 CPPScope *CPPScope::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) const {
+                CPPScope *current_scope, CPPScope *global_scope) const {
   CPPScope *this_scope = (CPPScope *)this;
   CPPScope *this_scope = (CPPScope *)this;
 
 
   if (is_fully_specified()) {
   if (is_fully_specified()) {
@@ -434,14 +434,14 @@ find_type(const string &name, bool recurse) const {
   if (_struct_type != NULL) {
   if (_struct_type != NULL) {
     CPPStructType::Derivation::const_iterator di;
     CPPStructType::Derivation::const_iterator di;
     for (di = _struct_type->_derivation.begin(); 
     for (di = _struct_type->_derivation.begin(); 
-	 di != _struct_type->_derivation.end(); 
-	 ++di) {
+         di != _struct_type->_derivation.end(); 
+         ++di) {
       CPPStructType *st = (*di)._base->as_struct_type();
       CPPStructType *st = (*di)._base->as_struct_type();
       if (st != NULL) {
       if (st != NULL) {
-	CPPType *type = st->_scope->find_type(name, false);
-	if (type != NULL) {
-	  return type;
-	}
+        CPPType *type = st->_scope->find_type(name, false);
+        if (type != NULL) {
+          return type;
+        }
       }
       }
     }
     }
   }
   }
@@ -460,7 +460,7 @@ find_type(const string &name, bool recurse) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPType *CPPScope::
 CPPType *CPPScope::
 find_type(const string &name, CPPDeclaration::SubstDecl &subst,
 find_type(const string &name, CPPDeclaration::SubstDecl &subst,
-	  CPPScope *global_scope, bool recurse) const {
+          CPPScope *global_scope, bool recurse) const {
   Typedefs::const_iterator ti;
   Typedefs::const_iterator ti;
   ti = _typedefs.find(name);
   ti = _typedefs.find(name);
   if (ti != _typedefs.end()) {
   if (ti != _typedefs.end()) {
@@ -480,15 +480,15 @@ find_type(const string &name, CPPDeclaration::SubstDecl &subst,
   if (_struct_type != NULL) {
   if (_struct_type != NULL) {
     CPPStructType::Derivation::const_iterator di;
     CPPStructType::Derivation::const_iterator di;
     for (di = _struct_type->_derivation.begin(); 
     for (di = _struct_type->_derivation.begin(); 
-	 di != _struct_type->_derivation.end(); 
-	 ++di) {
+         di != _struct_type->_derivation.end(); 
+         ++di) {
       CPPStructType *st = (*di)._base->as_struct_type();
       CPPStructType *st = (*di)._base->as_struct_type();
       if (st != NULL) {
       if (st != NULL) {
-	CPPType *type = st->_scope->find_type(name, subst, global_scope, 
-					      false);
-	if (type != NULL) {
-	  return type;
-	}
+        CPPType *type = st->_scope->find_type(name, subst, global_scope, 
+                                              false);
+        if (type != NULL) {
+          return type;
+        }
       }
       }
     }
     }
   }
   }
@@ -522,11 +522,11 @@ find_scope(const string &name, bool recurse) const {
   } else if (_struct_type != NULL) {
   } else if (_struct_type != NULL) {
     CPPStructType::Derivation::const_iterator di;
     CPPStructType::Derivation::const_iterator di;
     for (di = _struct_type->_derivation.begin(); 
     for (di = _struct_type->_derivation.begin(); 
-	 di != _struct_type->_derivation.end(); 
-	 ++di) {
+         di != _struct_type->_derivation.end(); 
+         ++di) {
       CPPStructType *st = (*di)._base->as_struct_type();
       CPPStructType *st = (*di)._base->as_struct_type();
       if (st != NULL) {
       if (st != NULL) {
-	type = st->_scope->find_type(name, false);
+        type = st->_scope->find_type(name, false);
       }
       }
     }
     }
   }
   }
@@ -560,7 +560,7 @@ find_scope(const string &name, bool recurse) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPScope *CPPScope::
 CPPScope *CPPScope::
 find_scope(const string &name, CPPDeclaration::SubstDecl &subst,
 find_scope(const string &name, CPPDeclaration::SubstDecl &subst,
-	   CPPScope *global_scope, bool recurse) const {
+           CPPScope *global_scope, bool recurse) const {
   CPPType *type = find_type(name, subst, global_scope, recurse);
   CPPType *type = find_type(name, subst, global_scope, recurse);
   if (type == NULL) {
   if (type == NULL) {
     return NULL;
     return NULL;
@@ -617,14 +617,14 @@ find_symbol(const string &name, bool recurse) const {
   if (_struct_type != NULL) {
   if (_struct_type != NULL) {
     CPPStructType::Derivation::const_iterator di;
     CPPStructType::Derivation::const_iterator di;
     for (di = _struct_type->_derivation.begin(); 
     for (di = _struct_type->_derivation.begin(); 
-	 di != _struct_type->_derivation.end(); 
-	 ++di) {
+         di != _struct_type->_derivation.end(); 
+         ++di) {
       CPPStructType *st = (*di)._base->as_struct_type();
       CPPStructType *st = (*di)._base->as_struct_type();
       if (st != NULL) {
       if (st != NULL) {
-	CPPDeclaration *decl = st->_scope->find_symbol(name, false);
-	if (decl != NULL) {
-	  return decl;
-	}
+        CPPDeclaration *decl = st->_scope->find_symbol(name, false);
+        if (decl != NULL) {
+          return decl;
+        }
       }
       }
     }
     }
   }
   }
@@ -660,14 +660,14 @@ find_template(const string &name, bool recurse) const {
   if (_struct_type != NULL) {
   if (_struct_type != NULL) {
     CPPStructType::Derivation::const_iterator di;
     CPPStructType::Derivation::const_iterator di;
     for (di = _struct_type->_derivation.begin(); 
     for (di = _struct_type->_derivation.begin(); 
-	 di != _struct_type->_derivation.end(); 
-	 ++di) {
+         di != _struct_type->_derivation.end(); 
+         ++di) {
       CPPStructType *st = (*di)._base->as_struct_type();
       CPPStructType *st = (*di)._base->as_struct_type();
       if (st != NULL) {
       if (st != NULL) {
-	CPPDeclaration *decl = st->_scope->find_template(name, false);
-	if (decl != NULL) {
-	  return decl;
-	}
+        CPPDeclaration *decl = st->_scope->find_template(name, false);
+        if (decl != NULL) {
+          return decl;
+        }
       }
       }
     }
     }
   }
   }
@@ -769,7 +769,7 @@ write(ostream &out, int indent_level, CPPScope *scope) const {
     bool complete = false;
     bool complete = false;
 
 
     if (cd->as_typedef() != NULL || cd->as_type() != NULL ||
     if (cd->as_typedef() != NULL || cd->as_type() != NULL ||
-	cd->as_namespace() != NULL) {
+        cd->as_namespace() != NULL) {
       complete = true;
       complete = true;
     }
     }
 
 
@@ -822,7 +822,7 @@ as_template_scope() {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 bool CPPScope::
 bool CPPScope::
 copy_substitute_decl(CPPScope *to_scope, CPPDeclaration::SubstDecl &subst,
 copy_substitute_decl(CPPScope *to_scope, CPPDeclaration::SubstDecl &subst,
-		     CPPScope *global_scope) const {
+                     CPPScope *global_scope) const {
   bool anything_changed = false;
   bool anything_changed = false;
 
 
   if (_struct_type != NULL) {
   if (_struct_type != NULL) {
@@ -832,21 +832,21 @@ copy_substitute_decl(CPPScope *to_scope, CPPDeclaration::SubstDecl &subst,
     }
     }
     to_scope->_struct_type = 
     to_scope->_struct_type = 
       new CPPStructType(_struct_type->_type, 
       new CPPStructType(_struct_type->_type, 
-			new CPPIdentifier(to_scope->_name),
-			native_scope, to_scope, _struct_type->_file);
+                        new CPPIdentifier(to_scope->_name),
+                        native_scope, to_scope, _struct_type->_file);
     to_scope->_struct_type->_incomplete = false;
     to_scope->_struct_type->_incomplete = false;
 
 
     // Copy the derivation to the new type.
     // Copy the derivation to the new type.
     CPPStructType::Derivation::const_iterator di;
     CPPStructType::Derivation::const_iterator di;
     for (di = _struct_type->_derivation.begin();
     for (di = _struct_type->_derivation.begin();
-	 di != _struct_type->_derivation.end();
-	 ++di) {
+         di != _struct_type->_derivation.end();
+         ++di) {
       CPPStructType::Base b = (*di);
       CPPStructType::Base b = (*di);
       b._base = 
       b._base = 
-	(*di)._base->substitute_decl(subst, to_scope, global_scope)->as_type();
+        (*di)._base->substitute_decl(subst, to_scope, global_scope)->as_type();
       to_scope->_struct_type->_derivation.push_back(b);
       to_scope->_struct_type->_derivation.push_back(b);
       if (b._base != (*di)._base) {
       if (b._base != (*di)._base) {
-	anything_changed = true;
+        anything_changed = true;
       }
       }
     }
     }
   }
   }
@@ -926,13 +926,13 @@ copy_substitute_decl(CPPScope *to_scope, CPPDeclaration::SubstDecl &subst,
 
 
     CPPFunctionGroup::Instances::const_iterator ii;
     CPPFunctionGroup::Instances::const_iterator ii;
     for (ii = fgroup->_instances.begin(); 
     for (ii = fgroup->_instances.begin(); 
-	 ii != fgroup->_instances.end();
-	 ++ii) {
+         ii != fgroup->_instances.end();
+         ++ii) {
       CPPInstance *inst = 
       CPPInstance *inst = 
-	(*ii)->substitute_decl(subst, to_scope, global_scope)->as_instance();
+        (*ii)->substitute_decl(subst, to_scope, global_scope)->as_instance();
       to_fgroup->_instances.push_back(inst);
       to_fgroup->_instances.push_back(inst);
       if (inst != (*ii)) {
       if (inst != (*ii)) {
-	anything_changed = true;
+        anything_changed = true;
       }
       }
     }
     }
   }
   }
@@ -994,7 +994,7 @@ handle_declaration(CPPDeclaration *decl, CPPScope *global_scope) {
       // by the same name in another scope.
       // by the same name in another scope.
       
       
       if (find_template(name) == NULL) {
       if (find_template(name) == NULL) {
-	_templates.insert(Templates::value_type(name, def));
+        _templates.insert(Templates::value_type(name, def));
       }
       }
     }
     }
     return;
     return;
@@ -1016,42 +1016,42 @@ handle_declaration(CPPDeclaration *decl, CPPScope *global_scope) {
     string name = inst->get_simple_name();
     string name = inst->get_simple_name();
     if (!name.empty() && inst->get_scope(this, global_scope) == this) {
     if (!name.empty() && inst->get_scope(this, global_scope) == this) {
       if (inst->_type->as_function_type()) {
       if (inst->_type->as_function_type()) {
-	// This is a function declaration; hence it gets added to
-	// the _functions member.  But we must be careful to share
-	// common-named functions.
-	
-	CPPFunctionGroup *fgroup;
-	Functions::const_iterator fi;
-	fi = _functions.find(name);
-	if (fi == _functions.end()) {
-	  fgroup = new CPPFunctionGroup(name);
-	  _functions.insert(Functions::value_type(name, fgroup));
-	} else {
-	  fgroup = (*fi).second;
-	}
-	fgroup->_instances.push_back(inst);
-	
+        // This is a function declaration; hence it gets added to
+        // the _functions member.  But we must be careful to share
+        // common-named functions.
+
+        CPPFunctionGroup *fgroup;
+        Functions::const_iterator fi;
+        fi = _functions.find(name);
+        if (fi == _functions.end()) {
+          fgroup = new CPPFunctionGroup(name);
+          _functions.insert(Functions::value_type(name, fgroup));
+        } else {
+          fgroup = (*fi).second;
+        }
+        fgroup->_instances.push_back(inst);
+
       } else {
       } else {
-	// This is not a function declaration; hence it gets added
-	// to the _variables member.
-	_variables[name] = inst;
+        // This is not a function declaration; hence it gets added
+        // to the _variables member.
+        _variables[name] = inst;
       }
       }
     
     
       if (inst->is_template()) {
       if (inst->is_template()) {
-	// Don't add a new template definition if we already had one
-	// by the same name in another scope.
-
-	if (find_template(name) == NULL) {
-	  _templates.insert(Templates::value_type(name, inst));
-	}
-	
-	/*
-	if (inst->_type->as_function_type() == NULL ||
-	    (inst->_type->as_function_type()->_flags & 
-	     CPPFunctionType::F_constructor) == 0) {
-	  _templates.insert(Templates::value_type(name, inst));
-	}
-	*/
+        // Don't add a new template definition if we already had one
+        // by the same name in another scope.
+
+        if (find_template(name) == NULL) {
+          _templates.insert(Templates::value_type(name, inst));
+        }
+
+        /*
+        if (inst->_type->as_function_type() == NULL ||
+            (inst->_type->as_function_type()->_flags & 
+             CPPFunctionType::F_constructor) == 0) {
+          _templates.insert(Templates::value_type(name, inst));
+        }
+        */
       }
       }
     }
     }
     return;
     return;

+ 18 - 18
dtool/src/cppparser/cppScope.h

@@ -35,13 +35,13 @@ class CPPNameComponent;
 struct cppyyltype;
 struct cppyyltype;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPScope
+//       Class : CPPScope
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPScope {
 class CPPScope {
 public:
 public:
   CPPScope(CPPScope *parent_scope,
   CPPScope(CPPScope *parent_scope,
-	   const CPPNameComponent &name, CPPVisibility starting_vis);
+           const CPPNameComponent &name, CPPVisibility starting_vis);
   virtual ~CPPScope();
   virtual ~CPPScope();
 
 
   void set_current_vis(CPPVisibility current_vis);
   void set_current_vis(CPPVisibility current_vis);
@@ -52,40 +52,40 @@ public:
   CPPScope *get_parent_scope() const;
   CPPScope *get_parent_scope() const;
 
 
   virtual void add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
   virtual void add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
-			       CPPPreprocessor *preprocessor, 
-			       const cppyyltype &pos);
+                               CPPPreprocessor *preprocessor, 
+                               const cppyyltype &pos);
   virtual void add_enum_value(CPPInstance *inst);
   virtual void add_enum_value(CPPInstance *inst);
   virtual void define_extension_type(CPPExtensionType *type);
   virtual void define_extension_type(CPPExtensionType *type);
   virtual void define_namespace(CPPNamespace *scope);
   virtual void define_namespace(CPPNamespace *scope);
   virtual void add_using(CPPUsing *using_decl, CPPScope *global_scope,
   virtual void add_using(CPPUsing *using_decl, CPPScope *global_scope,
-			 CPPPreprocessor *error_sink = NULL);
+                         CPPPreprocessor *error_sink = NULL);
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
 
 
   CPPScope *
   CPPScope *
   instantiate(const CPPTemplateParameterList *actual_params,
   instantiate(const CPPTemplateParameterList *actual_params,
-	      CPPScope *current_scope, CPPScope *global_scope,
-	      CPPPreprocessor *error_sink = NULL) const;
+              CPPScope *current_scope, CPPScope *global_scope,
+              CPPPreprocessor *error_sink = NULL) const;
 
 
   CPPScope *
   CPPScope *
   substitute_decl(CPPDeclaration::SubstDecl &subst,
   substitute_decl(CPPDeclaration::SubstDecl &subst,
-		  CPPScope *current_scope,
-		  CPPScope *global_scope) const;
+                  CPPScope *current_scope,
+                  CPPScope *global_scope) const;
 
 
   CPPType *find_type(const string &name, bool recurse = true) const;
   CPPType *find_type(const string &name, bool recurse = true) const;
   CPPType *find_type(const string &name,
   CPPType *find_type(const string &name,
-		     CPPDeclaration::SubstDecl &subst,
-		     CPPScope *global_scope,
-		     bool recurse = true) const;
+                     CPPDeclaration::SubstDecl &subst,
+                     CPPScope *global_scope,
+                     bool recurse = true) const;
   CPPScope *find_scope(const string &name, bool recurse = true) const;
   CPPScope *find_scope(const string &name, bool recurse = true) const;
   CPPScope *find_scope(const string &name,
   CPPScope *find_scope(const string &name,
-		       CPPDeclaration::SubstDecl &subst,
-		       CPPScope *global_scope,
-		       bool recurse = true) const;
+                       CPPDeclaration::SubstDecl &subst,
+                       CPPScope *global_scope,
+                       bool recurse = true) const;
   CPPDeclaration *find_symbol(const string &name,
   CPPDeclaration *find_symbol(const string &name,
-			      bool recurse = true) const;
+                              bool recurse = true) const;
   CPPDeclaration *find_template(const string &name,
   CPPDeclaration *find_template(const string &name,
-				bool recurse = true) const;
+                                bool recurse = true) const;
 
 
   virtual string get_simple_name() const;
   virtual string get_simple_name() const;
   virtual string get_local_name(CPPScope *scope = NULL) const;
   virtual string get_local_name(CPPScope *scope = NULL) const;
@@ -100,7 +100,7 @@ public:
 private:
 private:
   bool
   bool
   copy_substitute_decl(CPPScope *to_scope, CPPDeclaration::SubstDecl &subst,
   copy_substitute_decl(CPPScope *to_scope, CPPDeclaration::SubstDecl &subst,
-		       CPPScope *global_scope) const;
+                       CPPScope *global_scope) const;
 
 
   void handle_declaration(CPPDeclaration *decl, CPPScope *global_scope);
   void handle_declaration(CPPDeclaration *decl, CPPScope *global_scope);
 
 

+ 2 - 2
dtool/src/cppparser/cppSimpleType.h

@@ -11,7 +11,7 @@
 #include "cppType.h"
 #include "cppType.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPSimpleType
+//       Class : CPPSimpleType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPSimpleType : public CPPType {
 class CPPSimpleType : public CPPType {
@@ -44,7 +44,7 @@ public:
   virtual string get_preferred_name() const;
   virtual string get_preferred_name() const;
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPSimpleType *as_simple_type();
   virtual CPPSimpleType *as_simple_type();

+ 60 - 60
dtool/src/cppparser/cppStructType.cxx

@@ -35,8 +35,8 @@ output(ostream &out) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPStructType::
 CPPStructType::
 CPPStructType(CPPStructType::Type type, CPPIdentifier *ident, 
 CPPStructType(CPPStructType::Type type, CPPIdentifier *ident, 
-	      CPPScope *current_scope, CPPScope *scope, 
-	      const CPPFile &file) :
+              CPPScope *current_scope, CPPScope *scope, 
+              const CPPFile &file) :
   CPPExtensionType(type, ident, current_scope, file),
   CPPExtensionType(type, ident, current_scope, file),
   _scope(scope)
   _scope(scope)
 {
 {
@@ -180,12 +180,12 @@ get_destructor() const {
   fi = _scope->_functions.lower_bound("~");
   fi = _scope->_functions.lower_bound("~");
 
 
   while (fi != _scope->_functions.end() &&
   while (fi != _scope->_functions.end() &&
-	 (*fi).first[0] == '~') {
+         (*fi).first[0] == '~') {
     CPPFunctionGroup *fgroup = (*fi).second;
     CPPFunctionGroup *fgroup = (*fi).second;
     CPPFunctionGroup::Instances::const_iterator ii;
     CPPFunctionGroup::Instances::const_iterator ii;
     for (ii = fgroup->_instances.begin();
     for (ii = fgroup->_instances.begin();
-	 ii != fgroup->_instances.end();
-	 ++ii) {
+         ii != fgroup->_instances.end();
+         ++ii) {
       CPPInstance *inst = (*ii);
       CPPInstance *inst = (*ii);
       assert(inst->_type != (CPPType *)NULL);
       assert(inst->_type != (CPPType *)NULL);
       
       
@@ -193,7 +193,7 @@ get_destructor() const {
       assert(ftype != (CPPFunctionType *)NULL);
       assert(ftype != (CPPFunctionType *)NULL);
       
       
       if ((ftype->_flags & CPPFunctionType::F_destructor) != 0) {
       if ((ftype->_flags & CPPFunctionType::F_destructor) != 0) {
-	return inst;
+        return inst;
       }
       }
     }
     }
     ++fi;
     ++fi;
@@ -209,8 +209,8 @@ get_destructor() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPStructType::
 CPPDeclaration *CPPStructType::
 instantiate(const CPPTemplateParameterList *actual_params,
 instantiate(const CPPTemplateParameterList *actual_params,
-	    CPPScope *current_scope, CPPScope *global_scope,
-	    CPPPreprocessor *error_sink) const {
+            CPPScope *current_scope, CPPScope *global_scope,
+            CPPPreprocessor *error_sink) const {
 
 
   // I *think* this assertion is no longer valid.  Who knows.
   // I *think* this assertion is no longer valid.  Who knows.
   //  assert(!_incomplete);
   //  assert(!_incomplete);
@@ -218,7 +218,7 @@ instantiate(const CPPTemplateParameterList *actual_params,
   if (_scope == NULL) {
   if (_scope == NULL) {
     if (error_sink != NULL) {
     if (error_sink != NULL) {
       error_sink->warning("Ignoring template parameters for class " + 
       error_sink->warning("Ignoring template parameters for class " + 
-			  get_local_name());
+                          get_local_name());
     }
     }
     return (CPPDeclaration *)this;
     return (CPPDeclaration *)this;
   }
   }
@@ -255,7 +255,7 @@ instantiate(const CPPTemplateParameterList *actual_params,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPStructType::
 CPPDeclaration *CPPStructType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   SubstDecl::const_iterator si = subst.find(this);
   SubstDecl::const_iterator si = subst.find(this);
   if (si != subst.end()) {
   if (si != subst.end()) {
     assert((*si).second != NULL);
     assert((*si).second != NULL);
@@ -295,18 +295,18 @@ substitute_decl(CPPDeclaration::SubstDecl &subst,
       CPPScope *pscope = rep->_scope->get_parent_scope();
       CPPScope *pscope = rep->_scope->get_parent_scope();
 
 
       if (pscope != (CPPScope *)NULL && 
       if (pscope != (CPPScope *)NULL && 
-	  pscope->_name.has_templ()) {
-
-	// If the struct name didn't have an explicit template
-	// reference before, now it does.
-	if (!_ident->_names.empty() && !_ident->_names.back().has_templ()) {
-	  if (rep->is_template()) {
-	    rep->_template_scope = (CPPTemplateScope *)NULL;
-	    CPPNameComponent nc(get_simple_name());
-	    nc.set_templ(pscope->_name.get_templ());
-	    rep->_ident = new CPPIdentifier(nc);
-	  }
-	}
+          pscope->_name.has_templ()) {
+
+        // If the struct name didn't have an explicit template
+        // reference before, now it does.
+        if (!_ident->_names.empty() && !_ident->_names.back().has_templ()) {
+          if (rep->is_template()) {
+            rep->_template_scope = (CPPTemplateScope *)NULL;
+            CPPNameComponent nc(get_simple_name());
+            nc.set_templ(pscope->_name.get_templ());
+            rep->_ident = new CPPIdentifier(nc);
+          }
+        }
       }
       }
     }
     }
   }
   }
@@ -389,8 +389,8 @@ output(ostream &out, int indent_level, CPPScope *scope, bool complete) const {
       out << ": " << *di;
       out << ": " << *di;
       ++di;
       ++di;
       while (di != _derivation.end()) {
       while (di != _derivation.end()) {
-	out << ", " << *di;
-	++di;
+        out << ", " << *di;
+        ++di;
       }
       }
     }
     }
 
 
@@ -464,10 +464,10 @@ get_virtual_funcs(VFunctions &funcs) const {
       // destructors up by name.
       // destructors up by name.
       CPPInstance *destructor = get_destructor();
       CPPInstance *destructor = get_destructor();
       if (destructor != (CPPInstance *)NULL) {
       if (destructor != (CPPInstance *)NULL) {
-	// It's a match!  This destructor is virtual.
-	funcs.erase(vfi);
-	destructor->_storage_class |= 
-	  (CPPInstance::SC_virtual | CPPInstance::SC_inherited_virtual);
+        // It's a match!  This destructor is virtual.
+        funcs.erase(vfi);
+        destructor->_storage_class |= 
+          (CPPInstance::SC_virtual | CPPInstance::SC_inherited_virtual);
       }
       }
 
 
     } else {
     } else {
@@ -477,34 +477,34 @@ get_virtual_funcs(VFunctions &funcs) const {
       fi = _scope->_functions.find(fname);
       fi = _scope->_functions.find(fname);
 
 
       if (fi != _scope->_functions.end()) {
       if (fi != _scope->_functions.end()) {
-	CPPFunctionGroup *fgroup = (*fi).second;
-	
-	// Look for a matching function amid this group.
-	bool match_found = false;
-	CPPFunctionGroup::Instances::const_iterator ii;
-	for (ii = fgroup->_instances.begin();
-	     ii != fgroup->_instances.end() && !match_found;
-	     ++ii) {
-	  CPPInstance *new_inst = (*ii);
-	  assert(new_inst->_type != (CPPType *)NULL);
-	  
-	  CPPFunctionType *new_ftype = new_inst->_type->as_function_type();
-	  assert(new_ftype != (CPPFunctionType *)NULL);
-	  
-	  if (new_ftype->is_equivalent_function(*base_ftype)) {
-	    // It's a match!  We now know it's virtual.  Erase this
-	    // function from the list, so we can add it back in below.
-	    funcs.erase(vfi);
-	    match_found = true;
-
-	    // In fact, it's not only definitely virtual, but it's
-	    // *inherited* virtual, which means only that the
-	    // interface is defined in some parent class.  Sometimes
-	    // this is useful to know.
-	    new_inst->_storage_class |= 
-	      (CPPInstance::SC_virtual | CPPInstance::SC_inherited_virtual);
-	  }
-	}
+        CPPFunctionGroup *fgroup = (*fi).second;
+
+        // Look for a matching function amid this group.
+        bool match_found = false;
+        CPPFunctionGroup::Instances::const_iterator ii;
+        for (ii = fgroup->_instances.begin();
+             ii != fgroup->_instances.end() && !match_found;
+             ++ii) {
+          CPPInstance *new_inst = (*ii);
+          assert(new_inst->_type != (CPPType *)NULL);
+
+          CPPFunctionType *new_ftype = new_inst->_type->as_function_type();
+          assert(new_ftype != (CPPFunctionType *)NULL);
+
+          if (new_ftype->is_equivalent_function(*base_ftype)) {
+            // It's a match!  We now know it's virtual.  Erase this
+            // function from the list, so we can add it back in below.
+            funcs.erase(vfi);
+            match_found = true;
+
+            // In fact, it's not only definitely virtual, but it's
+            // *inherited* virtual, which means only that the
+            // interface is defined in some parent class.  Sometimes
+            // this is useful to know.
+            new_inst->_storage_class |= 
+              (CPPInstance::SC_virtual | CPPInstance::SC_inherited_virtual);
+          }
+        }
       }
       }
     }
     }
     vfi = vfnext;
     vfi = vfnext;
@@ -518,12 +518,12 @@ get_virtual_funcs(VFunctions &funcs) const {
     CPPFunctionGroup *fgroup = (*fi).second;
     CPPFunctionGroup *fgroup = (*fi).second;
     CPPFunctionGroup::Instances::const_iterator ii;
     CPPFunctionGroup::Instances::const_iterator ii;
     for (ii = fgroup->_instances.begin();
     for (ii = fgroup->_instances.begin();
-	 ii != fgroup->_instances.end();  
-	 ++ii) {
+         ii != fgroup->_instances.end();  
+         ++ii) {
       CPPInstance *inst = (*ii);
       CPPInstance *inst = (*ii);
       if ((inst->_storage_class & CPPInstance::SC_virtual) != 0) {
       if ((inst->_storage_class & CPPInstance::SC_virtual) != 0) {
-	// Here's a virtual function.
-	funcs.push_back(inst);
+        // Here's a virtual function.
+        funcs.push_back(inst);
       }
       }
     }
     }
   }
   }

+ 9 - 9
dtool/src/cppparser/cppStructType.h

@@ -18,15 +18,15 @@ class CPPScope;
 class CPPTypeProxy;
 class CPPTypeProxy;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPStructType
+//       Class : CPPStructType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPStructType : public CPPExtensionType {
 class CPPStructType : public CPPExtensionType {
 public:
 public:
   CPPStructType(Type type, CPPIdentifier *ident,
   CPPStructType(Type type, CPPIdentifier *ident,
-		CPPScope *current_scope,
-		CPPScope *scope,
-		const CPPFile &file);
+                CPPScope *current_scope,
+                CPPScope *scope,
+                const CPPFile &file);
   CPPStructType(const CPPStructType &copy);
   CPPStructType(const CPPStructType &copy);
   void operator = (const CPPStructType &copy);
   void operator = (const CPPStructType &copy);
 
 
@@ -43,15 +43,15 @@ public:
 
 
   virtual CPPDeclaration *
   virtual CPPDeclaration *
   instantiate(const CPPTemplateParameterList *actual_params,
   instantiate(const CPPTemplateParameterList *actual_params,
-	      CPPScope *current_scope, CPPScope *global_scope,
-	      CPPPreprocessor *error_sink = NULL) const;
+              CPPScope *current_scope, CPPScope *global_scope,
+              CPPPreprocessor *error_sink = NULL) const;
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPStructType *as_struct_type();
   virtual CPPStructType *as_struct_type();

+ 1 - 1
dtool/src/cppparser/cppTBDType.cxx

@@ -95,7 +95,7 @@ get_fully_scoped_name() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPTBDType::
 CPPDeclaration *CPPTBDType::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPDeclaration *top = 
   CPPDeclaration *top = 
     CPPDeclaration::substitute_decl(subst, current_scope, global_scope);
     CPPDeclaration::substitute_decl(subst, current_scope, global_scope);
   if (top != this) {
   if (top != this) {

+ 5 - 5
dtool/src/cppparser/cppTBDType.h

@@ -13,7 +13,7 @@
 class CPPIdentifier;
 class CPPIdentifier;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTBDType
+//       Class : CPPTBDType
 // Description : This represents a type whose exact meaning is still
 // Description : This represents a type whose exact meaning is still
 //               to-be-determined.  It happens when a typename is
 //               to-be-determined.  It happens when a typename is
 //               referenced in a template class (especially using the
 //               referenced in a template class (especially using the
@@ -25,7 +25,7 @@ public:
   CPPTBDType(CPPIdentifier *ident);
   CPPTBDType(CPPIdentifier *ident);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
 
 
@@ -34,11 +34,11 @@ public:
   virtual string get_fully_scoped_name() const;
   virtual string get_fully_scoped_name() const;
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPTBDType *as_tbd_type();
   virtual CPPTBDType *as_tbd_type();

+ 20 - 20
dtool/src/cppparser/cppTemplateParameterList.cxx

@@ -41,8 +41,8 @@ get_string() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPTemplateParameterList::
 void CPPTemplateParameterList::
 build_subst_decl(const CPPTemplateParameterList &formal_params,
 build_subst_decl(const CPPTemplateParameterList &formal_params,
-		 CPPDeclaration::SubstDecl &subst,
-		 CPPScope *current_scope, CPPScope *global_scope) const {
+                 CPPDeclaration::SubstDecl &subst,
+                 CPPScope *current_scope, CPPScope *global_scope) const {
   Parameters::const_iterator pfi, pai;
   Parameters::const_iterator pfi, pai;
   for (pfi = formal_params._parameters.begin(), pai = _parameters.begin();
   for (pfi = formal_params._parameters.begin(), pai = _parameters.begin();
        pfi != formal_params._parameters.end() && pai != _parameters.end();
        pfi != formal_params._parameters.end() && pai != _parameters.end();
@@ -66,25 +66,25 @@ build_subst_decl(const CPPTemplateParameterList &formal_params,
       // A value template parameter.  Its default is an expression.
       // A value template parameter.  Its default is an expression.
       CPPInstance *inst = decl->as_instance();
       CPPInstance *inst = decl->as_instance();
       if (inst->_initializer != NULL) {
       if (inst->_initializer != NULL) {
-	CPPDeclaration *decl = 
-	  inst->_initializer->substitute_decl(subst, current_scope,
-					      global_scope);
-	if (!(*decl == *inst)) {
-	  subst.insert(CPPDeclaration::SubstDecl::value_type
-		       (inst, decl));
-	}
+        CPPDeclaration *decl = 
+          inst->_initializer->substitute_decl(subst, current_scope,
+                                              global_scope);
+        if (!(*decl == *inst)) {
+          subst.insert(CPPDeclaration::SubstDecl::value_type
+                       (inst, decl));
+        }
       }
       }
     } else if (decl->as_class_template_parameter()) {
     } else if (decl->as_class_template_parameter()) {
       // A class template parameter.
       // A class template parameter.
       CPPClassTemplateParameter *cparam = decl->as_class_template_parameter();
       CPPClassTemplateParameter *cparam = decl->as_class_template_parameter();
       if (cparam->_default_type != NULL) {
       if (cparam->_default_type != NULL) {
-	CPPDeclaration *decl =
-	  cparam->_default_type->substitute_decl(subst, current_scope,
-						 global_scope);
-	if (!(*cparam == *decl)) {
-	  subst.insert(CPPDeclaration::SubstDecl::value_type
-		       (cparam, decl));
-	}
+        CPPDeclaration *decl =
+          cparam->_default_type->substitute_decl(subst, current_scope,
+                                                 global_scope);
+        if (!(*cparam == *decl)) {
+          subst.insert(CPPDeclaration::SubstDecl::value_type
+                       (cparam, decl));
+        }
       }
       }
     }
     }
     ++pfi;
     ++pfi;
@@ -124,7 +124,7 @@ is_tbd() const {
   for (int i = 0; i < (int)_parameters.size(); i++) {
   for (int i = 0; i < (int)_parameters.size(); i++) {
     CPPType *type = _parameters[i]->as_type();
     CPPType *type = _parameters[i]->as_type();
     if (type != (CPPType *)NULL && 
     if (type != (CPPType *)NULL && 
-	(type->is_tbd() || type->as_class_template_parameter() != NULL)) {
+        (type->is_tbd() || type->as_class_template_parameter() != NULL)) {
       return true;
       return true;
     }
     }
     CPPExpression *expr = _parameters[i]->as_expression();
     CPPExpression *expr = _parameters[i]->as_expression();
@@ -188,7 +188,7 @@ operator < (const CPPTemplateParameterList &other) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPTemplateParameterList *CPPTemplateParameterList::
 CPPTemplateParameterList *CPPTemplateParameterList::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPTemplateParameterList *rep = new CPPTemplateParameterList(*this);
   CPPTemplateParameterList *rep = new CPPTemplateParameterList(*this);
 
 
   bool anything_changed = false;
   bool anything_changed = false;
@@ -221,7 +221,7 @@ output(ostream &out, CPPScope *scope) const {
 
 
     ++pi;
     ++pi;
     while (pi != _parameters.end()) {
     while (pi != _parameters.end()) {
-      out << ", ";	
+      out << ", ";
       (*pi)->output(out, 0, scope, false);
       (*pi)->output(out, 0, scope, false);
       ++pi;
       ++pi;
     }
     }
@@ -244,7 +244,7 @@ write_formal(ostream &out, CPPScope *scope) const {
 
 
     ++pi;
     ++pi;
     while (pi != _parameters.end()) {
     while (pi != _parameters.end()) {
-      out << ", ";	
+      out << ", ";
       (*pi)->output(out, 0, scope, true);
       (*pi)->output(out, 0, scope, true);
       ++pi;
       ++pi;
     }
     }

+ 6 - 6
dtool/src/cppparser/cppTemplateParameterList.h

@@ -16,7 +16,7 @@
 class CPPScope;
 class CPPScope;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTemplateParameterList
+//       Class : CPPTemplateParameterList
 // Description : This class serves to store the parameter list for a
 // Description : This class serves to store the parameter list for a
 //               template function or class, both for the formal
 //               template function or class, both for the formal
 //               parameter list (given when the template is defined)
 //               parameter list (given when the template is defined)
@@ -29,8 +29,8 @@ public:
 
 
   string get_string() const;
   string get_string() const;
   void build_subst_decl(const CPPTemplateParameterList &formal_params,
   void build_subst_decl(const CPPTemplateParameterList &formal_params,
-			CPPDeclaration::SubstDecl &subst,
-			CPPScope *current_scope, CPPScope *global_scope) const;
+                        CPPDeclaration::SubstDecl &subst,
+                        CPPScope *current_scope, CPPScope *global_scope) const;
 
 
   bool is_fully_specified() const;
   bool is_fully_specified() const;
   bool is_tbd() const;
   bool is_tbd() const;
@@ -40,8 +40,8 @@ public:
   bool operator < (const CPPTemplateParameterList &other) const;
   bool operator < (const CPPTemplateParameterList &other) const;
 
 
   CPPTemplateParameterList *substitute_decl(CPPDeclaration::SubstDecl &subst,
   CPPTemplateParameterList *substitute_decl(CPPDeclaration::SubstDecl &subst,
-					    CPPScope *current_scope,
-					    CPPScope *global_scope);
+                                            CPPScope *current_scope,
+                                            CPPScope *global_scope);
 
 
   void output(ostream &out, CPPScope *scope) const;
   void output(ostream &out, CPPScope *scope) const;
   void write_formal(ostream &out, CPPScope *scope) const;
   void write_formal(ostream &out, CPPScope *scope) const;
@@ -62,7 +62,7 @@ operator << (ostream &out, const CPPTemplateParameterList &plist) {
 class CPPTPLCompare {
 class CPPTPLCompare {
 public:
 public:
   bool operator () (const CPPTemplateParameterList *a,
   bool operator () (const CPPTemplateParameterList *a,
-		    const CPPTemplateParameterList *b) const {
+                    const CPPTemplateParameterList *b) const {
     return (*a) < (*b);
     return (*a) < (*b);
   }
   }
 };
 };

+ 3 - 3
dtool/src/cppparser/cppTemplateScope.cxx

@@ -29,8 +29,8 @@ CPPTemplateScope(CPPScope *parent_scope) :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPTemplateScope::
 void CPPTemplateScope::
 add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
 add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
-		CPPPreprocessor *preprocessor,
-		const cppyyltype &pos) {
+                CPPPreprocessor *preprocessor,
+                const cppyyltype &pos) {
   decl->_template_scope = this;
   decl->_template_scope = this;
   assert(_parent_scope != NULL);
   assert(_parent_scope != NULL);
   _parent_scope->add_declaration(decl, global_scope, preprocessor, pos);
   _parent_scope->add_declaration(decl, global_scope, preprocessor, pos);
@@ -78,7 +78,7 @@ define_namespace(CPPNamespace *scope) {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPTemplateScope::
 void CPPTemplateScope::
 add_using(CPPUsing *using_decl, CPPScope *global_scope,
 add_using(CPPUsing *using_decl, CPPScope *global_scope,
-	  CPPPreprocessor *error_sink) {
+          CPPPreprocessor *error_sink) {
   assert(_parent_scope != NULL);
   assert(_parent_scope != NULL);
   _parent_scope->add_using(using_decl, global_scope, error_sink);
   _parent_scope->add_using(using_decl, global_scope, error_sink);
 }
 }

+ 4 - 4
dtool/src/cppparser/cppTemplateScope.h

@@ -12,7 +12,7 @@
 #include "cppTemplateParameterList.h"
 #include "cppTemplateParameterList.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTemplateScope
+//       Class : CPPTemplateScope
 // Description : This is an implicit scope that is created following
 // Description : This is an implicit scope that is created following
 //               the appearance of a "template<class x, class y>" or
 //               the appearance of a "template<class x, class y>" or
 //               some such line in a C++ file.  It simply defines the
 //               some such line in a C++ file.  It simply defines the
@@ -25,13 +25,13 @@ public:
   void add_template_parameter(CPPDeclaration *param);
   void add_template_parameter(CPPDeclaration *param);
  
  
   virtual void add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
   virtual void add_declaration(CPPDeclaration *decl, CPPScope *global_scope,
-			       CPPPreprocessor *preprocessor,
-			       const cppyyltype &pos);
+                               CPPPreprocessor *preprocessor,
+                               const cppyyltype &pos);
   virtual void add_enum_value(CPPInstance *inst);
   virtual void add_enum_value(CPPInstance *inst);
   virtual void define_extension_type(CPPExtensionType *type);
   virtual void define_extension_type(CPPExtensionType *type);
   virtual void define_namespace(CPPNamespace *scope);
   virtual void define_namespace(CPPNamespace *scope);
   virtual void add_using(CPPUsing *using_decl, CPPScope *global_scope,
   virtual void add_using(CPPUsing *using_decl, CPPScope *global_scope,
-			 CPPPreprocessor *error_sink = NULL);
+                         CPPPreprocessor *error_sink = NULL);
 
 
   virtual bool is_fully_specified() const;
   virtual bool is_fully_specified() const;
 
 

+ 2 - 2
dtool/src/cppparser/cppToken.cxx

@@ -17,8 +17,8 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPToken::
 CPPToken::
 CPPToken(int token, int line_number, int col_number,
 CPPToken(int token, int line_number, int col_number,
-	 const CPPFile &file, const string &str,
-	 const YYSTYPE &lval) :
+         const CPPFile &file, const string &str,
+         const YYSTYPE &lval) :
   _token(token), _lval(lval) 
   _token(token), _lval(lval) 
 {
 {
   _lval.str = str;
   _lval.str = str;

+ 4 - 4
dtool/src/cppparser/cppToken.h

@@ -11,15 +11,15 @@
 #include "cppBisonDefs.h"
 #include "cppBisonDefs.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPToken
+//       Class : CPPToken
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPToken {
 class CPPToken {
 public:
 public:
   CPPToken(int token, int line_number = 0, int col_number = 0,
   CPPToken(int token, int line_number = 0, int col_number = 0,
-	   const CPPFile &file = CPPFile(""),
-	   const string &str = string(),
-	   const YYSTYPE &lval = YYSTYPE());
+           const CPPFile &file = CPPFile(""),
+           const string &str = string(),
+           const YYSTYPE &lval = YYSTYPE());
   CPPToken(const CPPToken &copy);
   CPPToken(const CPPToken &copy);
   void operator = (const CPPToken &copy);
   void operator = (const CPPToken &copy);
 
 

+ 2 - 2
dtool/src/cppparser/cppType.cxx

@@ -192,8 +192,8 @@ output_instance(ostream &out, const string &name, CPPScope *scope) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPType::
 void CPPType::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   output(out, indent_level, scope, complete);
   output(out, indent_level, scope, complete);
   out << " " << prename << name;
   out << " " << prename << name;
 }
 }

+ 6 - 6
dtool/src/cppparser/cppType.h

@@ -25,7 +25,7 @@ public:
 };
 };
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPType
+//       Class : CPPType
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPType : public CPPDeclaration {
 class CPPType : public CPPDeclaration {
@@ -36,7 +36,7 @@ public:
   CPPType(const CPPFile &file);
   CPPType(const CPPFile &file);
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
 
 
@@ -52,11 +52,11 @@ public:
   virtual bool is_equivalent(const CPPType &other) const;
   virtual bool is_equivalent(const CPPType &other) const;
 
 
   void output_instance(ostream &out, const string &name, 
   void output_instance(ostream &out, const string &name, 
-		       CPPScope *scope) const;
+                       CPPScope *scope) const;
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
 
 
   virtual CPPType *as_type();
   virtual CPPType *as_type();
 
 

+ 1 - 1
dtool/src/cppparser/cppTypeDeclaration.cxx

@@ -29,7 +29,7 @@ CPPTypeDeclaration(CPPType *type) :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPTypeDeclaration::
 CPPDeclaration *CPPTypeDeclaration::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPDeclaration *decl = 
   CPPDeclaration *decl = 
     CPPInstance::substitute_decl(subst, current_scope, global_scope);
     CPPInstance::substitute_decl(subst, current_scope, global_scope);
   assert(decl != NULL);
   assert(decl != NULL);

+ 4 - 4
dtool/src/cppparser/cppTypeDeclaration.h

@@ -11,7 +11,7 @@
 #include "cppInstance.h"
 #include "cppInstance.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTypeDeclaration
+//       Class : CPPTypeDeclaration
 // Description : A CPPTypeDeclaration is a special declaration that
 // Description : A CPPTypeDeclaration is a special declaration that
 //               represents the top-level declaration of a type in a
 //               represents the top-level declaration of a type in a
 //               source file.  Typically this is the first appearance
 //               source file.  Typically this is the first appearance
@@ -22,11 +22,11 @@ public:
   CPPTypeDeclaration(CPPType *type);
   CPPTypeDeclaration(CPPType *type);
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPTypeDeclaration *as_type_declaration();
   virtual CPPTypeDeclaration *as_type_declaration();

+ 1 - 1
dtool/src/cppparser/cppTypeParser.h

@@ -14,7 +14,7 @@ class CPPType;
 class CPPScope;
 class CPPScope;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTypeParser
+//       Class : CPPTypeParser
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPTypeParser : public CPPPreprocessor {
 class CPPTypeParser : public CPPPreprocessor {

+ 3 - 3
dtool/src/cppparser/cppTypeProxy.cxx

@@ -170,14 +170,14 @@ is_incomplete() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 void CPPTypeProxy::
 void CPPTypeProxy::
 output_instance(ostream &out, int indent_level, CPPScope *scope,
 output_instance(ostream &out, int indent_level, CPPScope *scope,
-		bool complete, const string &prename,
-		const string &name) const {
+                bool complete, const string &prename,
+                const string &name) const {
   if (_actual_type == (CPPType *)NULL) {
   if (_actual_type == (CPPType *)NULL) {
     out << "unknown " << prename << name;
     out << "unknown " << prename << name;
     return;
     return;
   }
   }
   _actual_type->output_instance(out, indent_level, scope, complete,
   _actual_type->output_instance(out, indent_level, scope, complete,
-				prename, name);
+                                prename, name);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////

+ 6 - 6
dtool/src/cppparser/cppTypeProxy.h

@@ -12,7 +12,7 @@
 
 
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTypeProxy
+//       Class : CPPTypeProxy
 // Description : This is a special kind of type that is a placeholder
 // Description : This is a special kind of type that is a placeholder
 //               for some type, currently unknown, that will be filled
 //               for some type, currently unknown, that will be filled
 //               in later.  It's used when a type that references
 //               in later.  It's used when a type that references
@@ -23,7 +23,7 @@ public:
   CPPTypeProxy();
   CPPTypeProxy();
 
 
   virtual CPPType *resolve_type(CPPScope *current_scope,
   virtual CPPType *resolve_type(CPPScope *current_scope,
-				CPPScope *global_scope);
+                                CPPScope *global_scope);
 
 
   virtual bool is_tbd() const;
   virtual bool is_tbd() const;
 
 
@@ -38,11 +38,11 @@ public:
   virtual bool is_incomplete() const;
   virtual bool is_incomplete() const;
 
 
   virtual void output_instance(ostream &out, int indent_level,
   virtual void output_instance(ostream &out, int indent_level,
-			       CPPScope *scope,
-			       bool complete, const string &prename,
-			       const string &name) const;
+                               CPPScope *scope,
+                               bool complete, const string &prename,
+                               const string &name) const;
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
 
 
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 

+ 1 - 1
dtool/src/cppparser/cppTypedef.cxx

@@ -39,7 +39,7 @@ CPPTypedef(CPPInstance *inst, bool global) : CPPInstance(*inst)
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 CPPDeclaration *CPPTypedef::
 CPPDeclaration *CPPTypedef::
 substitute_decl(CPPDeclaration::SubstDecl &subst,
 substitute_decl(CPPDeclaration::SubstDecl &subst,
-		CPPScope *current_scope, CPPScope *global_scope) {
+                CPPScope *current_scope, CPPScope *global_scope) {
   CPPDeclaration *decl = 
   CPPDeclaration *decl = 
     CPPInstance::substitute_decl(subst, current_scope, global_scope);
     CPPInstance::substitute_decl(subst, current_scope, global_scope);
   assert(decl != NULL);
   assert(decl != NULL);

+ 4 - 4
dtool/src/cppparser/cppTypedef.h

@@ -11,7 +11,7 @@
 #include "cppInstance.h"
 #include "cppInstance.h"
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPTypedef
+//       Class : CPPTypedef
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPTypedef : public CPPInstance {
 class CPPTypedef : public CPPInstance {
@@ -19,11 +19,11 @@ public:
   CPPTypedef(CPPInstance *instance, bool global);
   CPPTypedef(CPPInstance *instance, bool global);
 
 
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
   virtual CPPDeclaration *substitute_decl(SubstDecl &subst,
-					  CPPScope *current_scope,
-					  CPPScope *global_scope);
+                                          CPPScope *current_scope,
+                                          CPPScope *global_scope);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPTypedef *as_typedef();
   virtual CPPTypedef *as_typedef();

+ 2 - 2
dtool/src/cppparser/cppUsing.h

@@ -14,7 +14,7 @@ class CPPIdentifier;
 class CPPScope;
 class CPPScope;
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : CPPUsing
+//       Class : CPPUsing
 // Description :
 // Description :
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 class CPPUsing : public CPPDeclaration {
 class CPPUsing : public CPPDeclaration {
@@ -22,7 +22,7 @@ public:
   CPPUsing(CPPIdentifier *ident, bool full_namespace, const CPPFile &file);
   CPPUsing(CPPIdentifier *ident, bool full_namespace, const CPPFile &file);
 
 
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
   virtual void output(ostream &out, int indent_level, CPPScope *scope,
-		      bool complete) const;
+                      bool complete) const;
   virtual SubType get_subtype() const;
   virtual SubType get_subtype() const;
 
 
   virtual CPPUsing *as_using();
   virtual CPPUsing *as_using();

+ 268 - 268
dtool/src/dconfig/configTable.cxx

@@ -41,9 +41,9 @@ bool ConfigTable::IsComment(const ConfigString& S)
 {
 {
   if (!S.empty()) {
   if (!S.empty()) {
     for (ConfigString::iterator i=configcmt.begin();
     for (ConfigString::iterator i=configcmt.begin();
-	 i!=configcmt.end(); ++i)
+         i!=configcmt.end(); ++i)
       if (S[0] == (*i))
       if (S[0] == (*i))
-	return true;
+        return true;
   }
   }
   return false;
   return false;
 }
 }
@@ -74,35 +74,35 @@ void ConfigTable::ParseConfigFile(istream& is, const ConfigString& Filename)
    while (!is.eof()) {
    while (!is.eof()) {
       std::getline(is, line);
       std::getline(is, line);
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	 microconfig_cat->spam() << "read from " << Filename << ": '" << line
-				 << "'" << endl;
+         microconfig_cat->spam() << "read from " << Filename << ": '" << line
+                                 << "'" << endl;
       CropString(line);
       CropString(line);
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	 microconfig_cat->spam() << "cropped line to: '" << line << "'"
-				 << endl;
+         microconfig_cat->spam() << "cropped line to: '" << line << "'"
+                                 << endl;
       if (!IsComment(line)) {
       if (!IsComment(line)) {
-	 ConfigString protosym(PopNextWord(line));
-	 if (microconfig_cat->is_spam())
-	    microconfig_cat->spam() << "protosym is '" << protosym
-				    << "' with value of '" << line << "'"
-				    << endl;
-	 size_t i(protosym.find("."));
-	 if (i == ConfigString::npos) {
-	    if (microconfig_cat->is_spam())
-	       microconfig_cat->spam() << "this is an unqualified symbol"
-				       << endl;
-	    unqualified[protosym].push_back(SymEnt(SymEnt::ConfigFile, line, Filename));
-	 } else {
-	   ConfigString scope(protosym.substr(0, i));
-	   ConfigString sym(protosym.substr(i+1, ConfigString::npos));
-	   if (microconfig_cat->is_spam())
-	     microconfig_cat->spam() << "this is a qualified symbol."
-				     << " scope '" << scope
-				     << "', symbol '" << sym << "'" << endl;
-	   (qualified[scope])[sym].push_back(SymEnt(SymEnt::ConfigFile, line, Filename));
-  	 }
+         ConfigString protosym(PopNextWord(line));
+         if (microconfig_cat->is_spam())
+            microconfig_cat->spam() << "protosym is '" << protosym
+                                    << "' with value of '" << line << "'"
+                                    << endl;
+         size_t i(protosym.find("."));
+         if (i == ConfigString::npos) {
+            if (microconfig_cat->is_spam())
+               microconfig_cat->spam() << "this is an unqualified symbol"
+                                       << endl;
+            unqualified[protosym].push_back(SymEnt(SymEnt::ConfigFile, line, Filename));
+         } else {
+           ConfigString scope(protosym.substr(0, i));
+           ConfigString sym(protosym.substr(i+1, ConfigString::npos));
+           if (microconfig_cat->is_spam())
+             microconfig_cat->spam() << "this is a qualified symbol."
+                                     << " scope '" << scope
+                                     << "', symbol '" << sym << "'" << endl;
+           (qualified[scope])[sym].push_back(SymEnt(SymEnt::ConfigFile, line, Filename));
+         }
       } else if (microconfig_cat->is_spam())
       } else if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "line is detected as a comment" << endl;
+        microconfig_cat->spam() << "line is detected as a comment" << endl;
    }
    }
 }
 }
 
 
@@ -130,7 +130,7 @@ void ConfigTable::ReadConfigFile(void) {
       int i = configpath.find_first_of(" ");
       int i = configpath.find_first_of(" ");
       ConfigString stmp = configpath.substr(0, i);
       ConfigString stmp = configpath.substr(0, i);
       if (ExecutionEnvironment::has_environment_variable(stmp)) {
       if (ExecutionEnvironment::has_environment_variable(stmp)) {
-	S += " ";
+        S += " ";
         S += ExecutionEnvironment::get_environment_variable(stmp);
         S += ExecutionEnvironment::get_environment_variable(stmp);
       }
       }
       configpath.erase(0, i);
       configpath.erase(0, i);
@@ -143,7 +143,7 @@ void ConfigTable::ReadConfigFile(void) {
   }
   }
   if (microconfig_cat->is_spam())
   if (microconfig_cat->is_spam())
     microconfig_cat->spam() << "evaluated value of configpath '"
     microconfig_cat->spam() << "evaluated value of configpath '"
-			    << configpath << "'" << endl;
+                            << configpath << "'" << endl;
   
   
   DSearchPath config_search(configpath);
   DSearchPath config_search(configpath);
   DSearchPath::Results config_files;
   DSearchPath::Results config_files;
@@ -151,24 +151,24 @@ void ConfigTable::ReadConfigFile(void) {
   if (!configsuffix.empty()) {
   if (!configsuffix.empty()) {
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "agregate config name is: "
       microconfig_cat->spam() << "agregate config name is: "
-			      << (configname + configsuffix) << endl;
+                              << (configname + configsuffix) << endl;
     config_search.find_all_files(configname + configsuffix, config_files);
     config_search.find_all_files(configname + configsuffix, config_files);
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "found " << config_files.get_num_files()
       microconfig_cat->spam() << "found " << config_files.get_num_files()
-			      << " files" << endl;
+                              << " files" << endl;
   } else {
   } else {
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "searching for '" << configname << "'"
       microconfig_cat->spam() << "searching for '" << configname << "'"
-			      << endl;
+                              << endl;
     config_search.find_all_files(configname, config_files);
     config_search.find_all_files(configname, config_files);
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "found " << config_files.get_num_files()
       microconfig_cat->spam() << "found " << config_files.get_num_files()
-			      << " files" << endl;
+                              << " files" << endl;
   }
   }
 
 
   if (microconfig_cat->is_spam())
   if (microconfig_cat->is_spam())
     microconfig_cat->spam() << "configpath parsed and searched"
     microconfig_cat->spam() << "configpath parsed and searched"
-			    << endl;
+                            << endl;
 
 
   int num_config_files = config_files.get_num_files();
   int num_config_files = config_files.get_num_files();
   for (int i = num_config_files - 1; i >= 0; i--) {
   for (int i = num_config_files - 1; i >= 0; i--) {
@@ -176,19 +176,19 @@ void ConfigTable::ReadConfigFile(void) {
 
 
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "examining file '" << config_file << "'"
       microconfig_cat->spam() << "examining file '" << config_file << "'"
-			       << endl;
+                               << endl;
     if (config_file.is_executable()) {
     if (config_file.is_executable()) {
       ConfigString line = config_file.to_os_specific() + " "
       ConfigString line = config_file.to_os_specific() + " "
-	+ ExecutionEnvironment::get_binary_name();
+        + ExecutionEnvironment::get_binary_name();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "file is executable, running '"
-				 << line << "'" << endl;
+        microconfig_cat->spam() << "file is executable, running '"
+                                 << line << "'" << endl;
       IPipeStream ifs(line);
       IPipeStream ifs(line);
       ParseConfigFile(ifs, config_file);
       ParseConfigFile(ifs, config_file);
     } else {
     } else {
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam()
-	  << "file is not executable, reading normally" << endl;
+        microconfig_cat->spam()
+          << "file is not executable, reading normally" << endl;
 
 
 #ifdef PENV_PS2
 #ifdef PENV_PS2
       ConfigString line = PS2_FILE_PREFIX + convert_pathname(config_file);
       ConfigString line = PS2_FILE_PREFIX + convert_pathname(config_file);
@@ -202,8 +202,8 @@ void ConfigTable::ReadConfigFile(void) {
 
 
       while (sceRead(fd, line_buffer, 2048) > 0)
       while (sceRead(fd, line_buffer, 2048) > 0)
       {
       {
-	file_buffer += line_buffer;
-	memset(line_buffer, 0, 2048);
+        file_buffer += line_buffer;
+        memset(line_buffer, 0, 2048);
       }
       }
 
 
       sceClose(fd);
       sceClose(fd);
@@ -221,43 +221,43 @@ void ConfigTable::ParseCommandEnv(ConfigString& S, const ConfigString& sym)
 {
 {
    if (microconfig_cat->is_spam())
    if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "value of '" << sym << "' is '" << S << "'"
       microconfig_cat->spam() << "value of '" << sym << "' is '" << S << "'"
-			       << endl;
+                               << endl;
    while (!S.empty()) {
    while (!S.empty()) {
       ConfigString protosym(PopNextWord(S));
       ConfigString protosym(PopNextWord(S));
       bool ok = false;
       bool ok = false;
       bool state = false;
       bool state = false;
       if (protosym[0] == '-')
       if (protosym[0] == '-')
-	 ok = true;
+         ok = true;
       else if (protosym[0] == '+') {
       else if (protosym[0] == '+') {
-	 ok = true;
-	 state = true;
+         ok = true;
+         state = true;
       }
       }
       if (ok) {
       if (ok) {
-	 protosym.erase(0, 1);
-	 CropString(protosym);
-	 size_t i(protosym.find("."));
-	 if (i == ConfigString::npos) {
-	    unqualified[protosym].push_back(SymEnt(SymEnt::CommandEnv,
-						   NextWord(S), sym, state));
-	    if (microconfig_cat->is_spam())
-	       microconfig_cat->spam() << "unqualified symbol '" << protosym
-				       << "' with value '" << NextWord(S)
-				       << "'" << endl;
-	 } else {
-	    ConfigString scope(protosym.substr(0, i));
-	    ConfigString sym(protosym.substr(i+1, ConfigString::npos));
-	    (qualified[scope])[sym].push_back(SymEnt(SymEnt::CommandEnv,
-						     NextWord(S), sym, state));
-	    if (microconfig_cat->is_spam())
-	       microconfig_cat->spam() << "qualified symbol '" << sym
-				       << "' in scope '" << scope
-				       << "' and value '" << NextWord(S)
-				       << "'" << endl;
-	 }
+         protosym.erase(0, 1);
+         CropString(protosym);
+         size_t i(protosym.find("."));
+         if (i == ConfigString::npos) {
+            unqualified[protosym].push_back(SymEnt(SymEnt::CommandEnv,
+                                                   NextWord(S), sym, state));
+            if (microconfig_cat->is_spam())
+               microconfig_cat->spam() << "unqualified symbol '" << protosym
+                                       << "' with value '" << NextWord(S)
+                                       << "'" << endl;
+         } else {
+            ConfigString scope(protosym.substr(0, i));
+            ConfigString sym(protosym.substr(i+1, ConfigString::npos));
+            (qualified[scope])[sym].push_back(SymEnt(SymEnt::CommandEnv,
+                                                     NextWord(S), sym, state));
+            if (microconfig_cat->is_spam())
+               microconfig_cat->spam() << "qualified symbol '" << sym
+                                       << "' in scope '" << scope
+                                       << "' and value '" << NextWord(S)
+                                       << "'" << endl;
+         }
       } else if (microconfig_cat->is_spam())
       } else if (microconfig_cat->is_spam())
-	 microconfig_cat->spam() << "'" << protosym
-				 << "' was not recognized as an option"
-				 << endl;
+         microconfig_cat->spam() << "'" << protosym
+                                 << "' was not recognized as an option"
+                                 << endl;
    }
    }
 }
 }
 
 
@@ -283,31 +283,31 @@ void ConfigTable::ParseArgs(void)
        size_t i(line.find("."));
        size_t i(line.find("."));
        ConfigString aparam;
        ConfigString aparam;
        if (n + 1 < num_args) {
        if (n + 1 < num_args) {
-	 aparam = ExecutionEnvironment::get_arg(n + 1);
+         aparam = ExecutionEnvironment::get_arg(n + 1);
        }
        }
 
 
        if (i == ConfigString::npos) {
        if (i == ConfigString::npos) {
-	 unqualified[line].push_back(SymEnt(SymEnt::Commandline,
-					    aparam, "", state));
-	 if (microconfig_cat->is_spam())
-	   microconfig_cat->spam() << "unqualified symbol '" << line
-				   << "' with value '" << aparam
-				   << "'" << endl;
+         unqualified[line].push_back(SymEnt(SymEnt::Commandline,
+                                            aparam, "", state));
+         if (microconfig_cat->is_spam())
+           microconfig_cat->spam() << "unqualified symbol '" << line
+                                   << "' with value '" << aparam
+                                   << "'" << endl;
        } else {
        } else {
-	 ConfigString scope(line.substr(0, i));
-	 ConfigString sym(line.substr(i+1, ConfigString::npos));
-	 (qualified[scope])[sym].push_back(SymEnt(SymEnt::Commandline,
-						  aparam, "", state));
-	 if (microconfig_cat->is_spam())
-	   microconfig_cat->spam() << "qualified symbol '" << sym
-				   << "' with scope '" << scope
-				   << "' and value '" << aparam
-				   << "'" << endl;
+         ConfigString scope(line.substr(0, i));
+         ConfigString sym(line.substr(i+1, ConfigString::npos));
+         (qualified[scope])[sym].push_back(SymEnt(SymEnt::Commandline,
+                                                  aparam, "", state));
+         if (microconfig_cat->is_spam())
+           microconfig_cat->spam() << "qualified symbol '" << sym
+                                   << "' with scope '" << scope
+                                   << "' and value '" << aparam
+                                   << "'" << endl;
        }
        }
      } else if (microconfig_cat->is_spam()) {
      } else if (microconfig_cat->is_spam()) {
        microconfig_cat->spam() << "argument #" << n << " ('" << line
        microconfig_cat->spam() << "argument #" << n << " ('" << line
-			       << "') is not recognized as an option"
-			       << endl;
+                               << "') is not recognized as an option"
+                               << endl;
      }
      }
      ++n;
      ++n;
    }
    }
@@ -349,149 +349,149 @@ void ConfigTable::MicroConfig(void)
    if (!cc.empty()) {
    if (!cc.empty()) {
       ConfigString configconfig(cc);
       ConfigString configconfig(cc);
       if (configconfig.length() > 1) {
       if (configconfig.length() > 1) {
-	 ConfigString assign = "=";
-	 ConfigString sep = configconfig.substr(0, 1);
-	 if (microconfig_cat->is_spam())
-	    microconfig_cat->spam() << "separator character is: '" << sep
-				    << "'" << endl;
-	 typedef std::vector<ConfigString> strvec;
-	 typedef Serialize::Deserializer<strvec, Serialize::StdExt<ConfigString> > deser;
-	 configconfig.erase(0, 1);
-	 deser ds(configconfig, sep);
-	 strvec sv = ds;
-	 if (microconfig_cat->is_spam())
-	    microconfig_cat->spam()
-	       << "extracted vector of microconfig options" << endl;
-	 for (strvec::iterator i=sv.begin(); i!=sv.end(); ++i) {
-	    if (microconfig_cat->is_spam())
-	       microconfig_cat->spam() << "parsing microconfig option '"
-				       << *i << "'" << endl;
-	    if ((*i).length() == 1) {
-	      // new assignment character
-	      assign += *i;
-	      continue;
-	    }
-	    size_t j = (*i).find_first_of(assign);
-	    if (j != ConfigString::npos) {
-	       ConfigString tok = (*i).substr(0, j);
-	       ConfigString rest = (*i).substr(j+1, ConfigString::npos);
-	       if (microconfig_cat->is_spam())
-		  microconfig_cat->spam() << "split microconfig option into '"
-					  << tok << "' and '" << rest << "'"
-					  << endl;
-	       if (tok == "pathsep") {
-		  pathsep = rest;
-		  psep = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig pathsep directive, "
-			<< "setting the path separator to '" << pathsep << "'"
-			<< endl;
-	       } else if (tok == "filesep") {
-		  filesep = rest;
-		  fsep = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig filesep directive, "
-			<< "setting the file separator to '" << filesep << "'"
-			<< endl;
-	       } else if (tok == "configname") {
-		  configname = rest;
-		  cname = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig configname directive, "
-			<< "setting the configfile name to '" << configname
-			<< "'" << endl;
-	       } else if (tok == "configsuffix") {
-		  configsuffix = rest;
-		  csuff = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig configsuffix directive, "
-			<< "setting the config file suffix to '"
-			<< configsuffix << "'"
-			<< endl;
-	       } else if (tok == "configpath") {
-		  if (cpath) {
-		    configpath += " " + rest;
-		    if (microconfig_cat->is_spam())
-		      microconfig_cat->spam()
-		        << "got a microconfig configpath directive, "
-			<< "adding '" << rest << "' to the configpath"
-			<< endl;
-		  } else {
-		    configpath = rest;
-		    if (microconfig_cat->is_spam())
-		      microconfig_cat->spam()
-		        << "got a microconfig configpath directive, "
-			<< "setting the configpath to '" << configpath << "'"
-			<< endl;
-		  }
-		  cpath = true;
-	       } else if (tok == "configcmt") {
-		  configcmt = rest;
-		  ccmt = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig configcmt directive, "
-			<< "setting the config comment to '" << configcmt
-			<< "'" << endl;
-	       } else if (tok == "argsuffix") {
-		  argsuffix = rest;
-		  asuff = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig argsuffix directive, "
-			<< "setting the argument environment suffix to '"
-			<< argsuffix << "'" << endl;
-	       } else if (tok == "commandstub") {
-		  commandstub = rest;
-		  cstub = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig commandstub directive, "
-			<< "setting the command environment stub "
-			<< "to '" << commandstub << "'" << endl;
-	       } else if (tok == "configdbg") {
-		  configdbg = TrueOrFalse(rest);
-		  cdbg = true;
-		  if (configdbg) {
-		     microconfig_cat->set_severity(NS_spam);
-		     dconfig_cat->set_severity(NS_spam);
-		  } else {
-		     microconfig_cat->set_severity(NS_info);
-		     dconfig_cat->set_severity(NS_info);
-		  }
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig configdbg directive, "
-			<< "setting the config spam state to " << configdbg
-			<< endl;
-	       } else if (tok == "readargs") {
-		  readargs = TrueOrFalse(rest);
-		  rdarg = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig readargs directive, "
-			<< (readargs?"will":"will not")
-			<< " read from the commandline." << endl;
-	       } else if (tok == "readenv") {
-		  readenvs = TrueOrFalse(rest);
-		  rdenv = true;
-		  if (microconfig_cat->is_spam())
-		     microconfig_cat->spam()
-		        << "got a microconfig readenv directive, "
-			<< (readargs?"will":"will not")
-			<< " read the environment." << endl;
-	       }
-	    } else if (microconfig_cat->is_spam())
-	       microconfig_cat->spam()
-		  << "no '=' in microconfig option, ignoring it" << endl;
-	 }
+         ConfigString assign = "=";
+         ConfigString sep = configconfig.substr(0, 1);
+         if (microconfig_cat->is_spam())
+            microconfig_cat->spam() << "separator character is: '" << sep
+                                    << "'" << endl;
+         typedef std::vector<ConfigString> strvec;
+         typedef Serialize::Deserializer<strvec, Serialize::StdExt<ConfigString> > deser;
+         configconfig.erase(0, 1);
+         deser ds(configconfig, sep);
+         strvec sv = ds;
+         if (microconfig_cat->is_spam())
+            microconfig_cat->spam()
+               << "extracted vector of microconfig options" << endl;
+         for (strvec::iterator i=sv.begin(); i!=sv.end(); ++i) {
+            if (microconfig_cat->is_spam())
+               microconfig_cat->spam() << "parsing microconfig option '"
+                                       << *i << "'" << endl;
+            if ((*i).length() == 1) {
+              // new assignment character
+              assign += *i;
+              continue;
+            }
+            size_t j = (*i).find_first_of(assign);
+            if (j != ConfigString::npos) {
+               ConfigString tok = (*i).substr(0, j);
+               ConfigString rest = (*i).substr(j+1, ConfigString::npos);
+               if (microconfig_cat->is_spam())
+                  microconfig_cat->spam() << "split microconfig option into '"
+                                          << tok << "' and '" << rest << "'"
+                                          << endl;
+               if (tok == "pathsep") {
+                  pathsep = rest;
+                  psep = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig pathsep directive, "
+                        << "setting the path separator to '" << pathsep << "'"
+                        << endl;
+               } else if (tok == "filesep") {
+                  filesep = rest;
+                  fsep = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig filesep directive, "
+                        << "setting the file separator to '" << filesep << "'"
+                        << endl;
+               } else if (tok == "configname") {
+                  configname = rest;
+                  cname = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig configname directive, "
+                        << "setting the configfile name to '" << configname
+                        << "'" << endl;
+               } else if (tok == "configsuffix") {
+                  configsuffix = rest;
+                  csuff = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig configsuffix directive, "
+                        << "setting the config file suffix to '"
+                        << configsuffix << "'"
+                        << endl;
+               } else if (tok == "configpath") {
+                  if (cpath) {
+                    configpath += " " + rest;
+                    if (microconfig_cat->is_spam())
+                      microconfig_cat->spam()
+                        << "got a microconfig configpath directive, "
+                        << "adding '" << rest << "' to the configpath"
+                        << endl;
+                  } else {
+                    configpath = rest;
+                    if (microconfig_cat->is_spam())
+                      microconfig_cat->spam()
+                        << "got a microconfig configpath directive, "
+                        << "setting the configpath to '" << configpath << "'"
+                        << endl;
+                  }
+                  cpath = true;
+               } else if (tok == "configcmt") {
+                  configcmt = rest;
+                  ccmt = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig configcmt directive, "
+                        << "setting the config comment to '" << configcmt
+                        << "'" << endl;
+               } else if (tok == "argsuffix") {
+                  argsuffix = rest;
+                  asuff = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig argsuffix directive, "
+                        << "setting the argument environment suffix to '"
+                        << argsuffix << "'" << endl;
+               } else if (tok == "commandstub") {
+                  commandstub = rest;
+                  cstub = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig commandstub directive, "
+                        << "setting the command environment stub "
+                        << "to '" << commandstub << "'" << endl;
+               } else if (tok == "configdbg") {
+                  configdbg = TrueOrFalse(rest);
+                  cdbg = true;
+                  if (configdbg) {
+                     microconfig_cat->set_severity(NS_spam);
+                     dconfig_cat->set_severity(NS_spam);
+                  } else {
+                     microconfig_cat->set_severity(NS_info);
+                     dconfig_cat->set_severity(NS_info);
+                  }
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig configdbg directive, "
+                        << "setting the config spam state to " << configdbg
+                        << endl;
+               } else if (tok == "readargs") {
+                  readargs = TrueOrFalse(rest);
+                  rdarg = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig readargs directive, "
+                        << (readargs?"will":"will not")
+                        << " read from the commandline." << endl;
+               } else if (tok == "readenv") {
+                  readenvs = TrueOrFalse(rest);
+                  rdenv = true;
+                  if (microconfig_cat->is_spam())
+                     microconfig_cat->spam()
+                        << "got a microconfig readenv directive, "
+                        << (readargs?"will":"will not")
+                        << " read the environment." << endl;
+               }
+            } else if (microconfig_cat->is_spam())
+               microconfig_cat->spam()
+                  << "no '=' in microconfig option, ignoring it" << endl;
+         }
       } else if (microconfig_cat->is_spam())
       } else if (microconfig_cat->is_spam())
-	 microconfig_cat->spam()
-	    << "CONFIG_CONFIG contains only a single character" << endl;
+         microconfig_cat->spam()
+            << "CONFIG_CONFIG contains only a single character" << endl;
    } else if (microconfig_cat->is_spam())
    } else if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "CONFIG_CONFIG is empty" << endl;
       microconfig_cat->spam() << "CONFIG_CONFIG is empty" << endl;
    if (!cdbg)
    if (!cdbg)
@@ -499,72 +499,72 @@ void ConfigTable::MicroConfig(void)
    if (!psep) {
    if (!psep) {
       PathSepDefault();
       PathSepDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	 microconfig_cat->spam() << "no microconfig for pathsep, "
-				  << "setting to default '" << pathsep << "'"
-				  << endl;
+         microconfig_cat->spam() << "no microconfig for pathsep, "
+                                  << "setting to default '" << pathsep << "'"
+                                  << endl;
    }
    }
    if (!fsep) {
    if (!fsep) {
       FileSepDefault();
       FileSepDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for filesep, "
-				<< "setting to default '" << filesep << "'"
-				<< endl;
+        microconfig_cat->spam() << "no microconfig for filesep, "
+                                << "setting to default '" << filesep << "'"
+                                << endl;
    }
    }
    if (!cname) {
    if (!cname) {
       ConfigNameDefault();
       ConfigNameDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for configname, "
-				<< "setting to default '" << configname
-				<< "'" << endl;
+        microconfig_cat->spam() << "no microconfig for configname, "
+                                << "setting to default '" << configname
+                                << "'" << endl;
    }
    }
    if (!csuff) {
    if (!csuff) {
       ConfigSuffixDefault();
       ConfigSuffixDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for configsuffix, "
-				<< "setting to default '" << configsuffix
-				<< "'" << endl;
+        microconfig_cat->spam() << "no microconfig for configsuffix, "
+                                << "setting to default '" << configsuffix
+                                << "'" << endl;
    }
    }
    if (!cpath) {
    if (!cpath) {
       ConfigPathDefault();
       ConfigPathDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for configpath, "
-				<< "setting to default '" << configpath
-				<< "'" << endl;
+        microconfig_cat->spam() << "no microconfig for configpath, "
+                                << "setting to default '" << configpath
+                                << "'" << endl;
    }
    }
    if (!ccmt) {
    if (!ccmt) {
       ConfigCmtDefault();
       ConfigCmtDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for configcmt, "
-				<< "setting to default '" << configcmt
-				<< "'" << endl;
+        microconfig_cat->spam() << "no microconfig for configcmt, "
+                                << "setting to default '" << configcmt
+                                << "'" << endl;
    }
    }
    if (!asuff) {
    if (!asuff) {
       ArgSuffixDefault();
       ArgSuffixDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for argsuffix, "
-				<< "setting to default '" << argsuffix
-				<< "'" << endl;
+        microconfig_cat->spam() << "no microconfig for argsuffix, "
+                                << "setting to default '" << argsuffix
+                                << "'" << endl;
    }
    }
    if (!cstub) {
    if (!cstub) {
       CommandStubDefault();
       CommandStubDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for commandstub, "
-				<< "setting to default '" << commandstub
-				<< "'" << endl;
+        microconfig_cat->spam() << "no microconfig for commandstub, "
+                                << "setting to default '" << commandstub
+                                << "'" << endl;
    }
    }
    if (!rdarg) {
    if (!rdarg) {
       ReadArgsDefault();
       ReadArgsDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for readargs, "
-				<< "setting to default: "
-				<< (readargs?"true":"false") << endl;
+        microconfig_cat->spam() << "no microconfig for readargs, "
+                                << "setting to default: "
+                                << (readargs?"true":"false") << endl;
    }
    }
    if (!rdenv) {
    if (!rdenv) {
       ReadEnvsDefault();
       ReadEnvsDefault();
       if (microconfig_cat->is_spam())
       if (microconfig_cat->is_spam())
-	microconfig_cat->spam() << "no microconfig for readenv, "
-				<< "setting to default: "
-				<< (readargs?"true":"false") << endl;
+        microconfig_cat->spam() << "no microconfig for readenv, "
+                                << "setting to default: "
+                                << (readargs?"true":"false") << endl;
    }
    }
 }
 }
 
 
@@ -576,7 +576,7 @@ void ConfigTable::GetData(void) {
     ConfigString comarg = commandstub + argsuffix;
     ConfigString comarg = commandstub + argsuffix;
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "comarg is '" << comarg << "'"
       microconfig_cat->spam() << "comarg is '" << comarg << "'"
-			      << endl;
+                              << endl;
     if (ExecutionEnvironment::has_environment_variable(comarg)) {
     if (ExecutionEnvironment::has_environment_variable(comarg)) {
       ConfigString env = ExecutionEnvironment::get_environment_variable(comarg);
       ConfigString env = ExecutionEnvironment::get_environment_variable(comarg);
       ParseCommandEnv(env, comarg);
       ParseCommandEnv(env, comarg);
@@ -585,7 +585,7 @@ void ConfigTable::GetData(void) {
     UpCase(line);
     UpCase(line);
     if (microconfig_cat->is_spam())
     if (microconfig_cat->is_spam())
       microconfig_cat->spam() << "binarg is '" << line << "'"
       microconfig_cat->spam() << "binarg is '" << line << "'"
-			      << endl;
+                              << endl;
     if (ExecutionEnvironment::has_environment_variable(line)) {
     if (ExecutionEnvironment::has_environment_variable(line)) {
       ConfigString env = ExecutionEnvironment::get_environment_variable(line);
       ConfigString env = ExecutionEnvironment::get_environment_variable(line);
       ParseCommandEnv(env, line);
       ParseCommandEnv(env, line);
@@ -632,13 +632,13 @@ bool ConfigTable::TrueOrFalse(const ConfigString& in, bool def) {
 }
 }
 
 
 bool ConfigTable::Defined(const ConfigString& sym,
 bool ConfigTable::Defined(const ConfigString& sym,
-				 const ConfigString qual) {
+                                 const ConfigString qual) {
 #ifdef DISABLE_CONFIG
 #ifdef DISABLE_CONFIG
   return false;
   return false;
 #else
 #else
   if (qual.empty()) {
   if (qual.empty()) {
     return (unqualified.count(sym) != 0 ||
     return (unqualified.count(sym) != 0 ||
-	    ExecutionEnvironment::has_environment_variable(sym));
+            ExecutionEnvironment::has_environment_variable(sym));
 
 
   } else {
   } else {
     TableMap::const_iterator ti;
     TableMap::const_iterator ti;
@@ -646,7 +646,7 @@ bool ConfigTable::Defined(const ConfigString& sym,
     if (ti != qualified.end()) {
     if (ti != qualified.end()) {
       const SymbolTable &table = (*ti).second;
       const SymbolTable &table = (*ti).second;
       if (table.count(sym) != 0) {
       if (table.count(sym) != 0) {
-	return true;
+        return true;
       }
       }
     }
     }
 
 
@@ -656,7 +656,7 @@ bool ConfigTable::Defined(const ConfigString& sym,
 }
 }
 
 
 ConfigTable::SymEnt ConfigTable::Get(const ConfigString& sym,
 ConfigTable::SymEnt ConfigTable::Get(const ConfigString& sym,
-				     const ConfigString qual) {
+                                     const ConfigString qual) {
 #ifndef DISABLE_CONFIG
 #ifndef DISABLE_CONFIG
   const ConfigTable::Symbol &symbol = GetSym(sym, qual);
   const ConfigTable::Symbol &symbol = GetSym(sym, qual);
   if (!symbol.empty()) {
   if (!symbol.empty()) {
@@ -680,7 +680,7 @@ ConfigTable::SymEnt ConfigTable::Get(const ConfigString& sym,
 }
 }
 
 
 const ConfigTable::Symbol& ConfigTable::GetSym(const ConfigString& sym,
 const ConfigTable::Symbol& ConfigTable::GetSym(const ConfigString& sym,
-					       const ConfigString qual) {
+                                               const ConfigString qual) {
   static ConfigTable::Symbol empty_symbol;
   static ConfigTable::Symbol empty_symbol;
 
 
 #ifndef DISABLE_CONFIG
 #ifndef DISABLE_CONFIG
@@ -700,7 +700,7 @@ const ConfigTable::Symbol& ConfigTable::GetSym(const ConfigString& sym,
       SymbolTable::const_iterator si;
       SymbolTable::const_iterator si;
       si = table.find(sym);
       si = table.find(sym);
       if (si != table.end()) {
       if (si != table.end()) {
-	return (*si).second;
+        return (*si).second;
       }
       }
     }
     }
   }
   }

+ 1 - 1
dtool/src/dconfig/configTable.h

@@ -72,7 +72,7 @@ class EXPCL_DTOOLCONFIG ConfigTable {
       bool Defined(const ConfigString& sym, const ConfigString qual="");
       bool Defined(const ConfigString& sym, const ConfigString qual="");
       SymEnt Get(const ConfigString& sym, const ConfigString qual = "");
       SymEnt Get(const ConfigString& sym, const ConfigString qual = "");
       const Symbol& GetSym(const ConfigString& sym,
       const Symbol& GetSym(const ConfigString& sym,
-			   const ConfigString qual = "");
+                           const ConfigString qual = "");
       INLINE ConfigString GetConfigPath(void) const;
       INLINE ConfigString GetConfigPath(void) const;
 };
 };
 
 

+ 37 - 37
dtool/src/dconfig/dconfig.h

@@ -63,14 +63,14 @@ class Config {
       static bool         Defined(const ConfigString& sym);
       static bool         Defined(const ConfigString& sym);
       static ConfigString Get(const ConfigString sym);
       static ConfigString Get(const ConfigString sym);
       static ConfigTable::Symbol& GetAll(const ConfigString,
       static ConfigTable::Symbol& GetAll(const ConfigString,
-					 ConfigTable::Symbol&);
+                                         ConfigTable::Symbol&);
    PUBLISHED:
    PUBLISHED:
       static bool         GetBool(const ConfigString sym, bool def = false);
       static bool         GetBool(const ConfigString sym, bool def = false);
       static int          GetInt(const ConfigString sym, int def = 0);
       static int          GetInt(const ConfigString sym, int def = 0);
       static float        GetFloat(const ConfigString sym, float def = 0.);
       static float        GetFloat(const ConfigString sym, float def = 0.);
       static double       GetDouble(const ConfigString sym, double def = 0.);
       static double       GetDouble(const ConfigString sym, double def = 0.);
       static ConfigString GetString(const ConfigString sym,
       static ConfigString GetString(const ConfigString sym,
-				    const ConfigString def = "");
+                                    const ConfigString def = "");
 };
 };
 
 
 // Implementation follows
 // Implementation follows
@@ -121,11 +121,11 @@ void Config<GetConfig>::Init(void)
       ConfigString s = Get("notify-level-config");
       ConfigString s = Get("notify-level-config");
       NotifySeverity sev = Notify::string_severity(s);
       NotifySeverity sev = Notify::string_severity(s);
       if (sev != NS_unspecified) {
       if (sev != NS_unspecified) {
-	 microconfig_cat->set_severity(sev);
-	 dconfig_cat->set_severity(sev);
+         microconfig_cat->set_severity(sev);
+         dconfig_cat->set_severity(sev);
       } else {
       } else {
-	 microconfig_cat->set_severity(NS_info);
-	 dconfig_cat->set_severity(NS_info);
+         microconfig_cat->set_severity(NS_info);
+         dconfig_cat->set_severity(NS_info);
       }
       }
    } else {
    } else {
       microconfig_cat->set_severity(NS_info);
       microconfig_cat->set_severity(NS_info);
@@ -137,11 +137,11 @@ void Config<GetConfig>::Init(void)
 
 
    if (dconfig_cat->is_spam())
    if (dconfig_cat->is_spam())
       dconfig_cat->spam() << "calling ConfigFunc for '" << Name() << "'"
       dconfig_cat->spam() << "calling ConfigFunc for '" << Name() << "'"
-			 << endl;
+                         << endl;
    ConfigFunc();
    ConfigFunc();
    if (dconfig_cat->is_spam())
    if (dconfig_cat->is_spam())
       dconfig_cat->spam() << "back from ConfigFunc for '" << Name() << "'"
       dconfig_cat->spam() << "back from ConfigFunc for '" << Name() << "'"
-			 << endl;
+                         << endl;
    total_time_external_init += clock();
    total_time_external_init += clock();
 }
 }
 
 
@@ -187,7 +187,7 @@ ConfigString Config<GetConfig>::Get(ConfigString sym)
 
 
 template<class GetConfig>
 template<class GetConfig>
 ConfigTable::Symbol& Config<GetConfig>::GetAll(const ConfigString sym,
 ConfigTable::Symbol& Config<GetConfig>::GetAll(const ConfigString sym,
-						ConfigTable::Symbol& s)
+                                                ConfigTable::Symbol& s)
 {
 {
    Init();
    Init();
    ConfigTable* tab = ConfigTable::Instance();
    ConfigTable* tab = ConfigTable::Instance();
@@ -214,15 +214,15 @@ bool Config<GetConfig>::GetBool(const ConfigString sym, bool def)
       ConfigString s = Get(sym);
       ConfigString s = Get(sym);
       bool ret = ConfigTable::TrueOrFalse(s, def);
       bool ret = ConfigTable::TrueOrFalse(s, def);
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
-			    << (ret?"true":"false") << endl;
+         dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
+                            << (ret?"true":"false") << endl;
       return ret;
       return ret;
    } else {
    } else {
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam()
-	    << "symbol '" << sym
-	    << "' is not defined, returning provided default: "
-	    << (def?"true":"false") << endl;
+         dconfig_cat->spam()
+            << "symbol '" << sym
+            << "' is not defined, returning provided default: "
+            << (def?"true":"false") << endl;
       return def;
       return def;
    }
    }
 }
 }
@@ -237,14 +237,14 @@ int Config<GetConfig>::GetInt(const ConfigString sym, int def)
       int i;
       int i;
       s >> i;
       s >> i;
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
-			    << i << endl;
+         dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
+                            << i << endl;
       return i;
       return i;
    } else {
    } else {
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam()
-	    << "symbol '" << sym
-	    << "' is not defined, returning provided default: " << def << endl;
+         dconfig_cat->spam()
+            << "symbol '" << sym
+            << "' is not defined, returning provided default: " << def << endl;
       return def;
       return def;
    }
    }
 }
 }
@@ -259,14 +259,14 @@ float Config<GetConfig>::GetFloat(const ConfigString sym, float def)
       float f;
       float f;
       s >> f;
       s >> f;
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
-			    << f << endl;
+         dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
+                            << f << endl;
       return f;
       return f;
    } else {
    } else {
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam()
-	    << "symbol '" << sym
-	    << "' is not defined, returning provided default: " << def << endl;
+         dconfig_cat->spam()
+            << "symbol '" << sym
+            << "' is not defined, returning provided default: " << def << endl;
       return def;
       return def;
    }
    }
 }
 }
@@ -281,35 +281,35 @@ double Config<GetConfig>::GetDouble(const ConfigString sym, double def)
       double d;
       double d;
       s >> d;
       s >> d;
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
-			    << d << endl;
+         dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: "
+                            << d << endl;
       return d;
       return d;
    } else {
    } else {
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam()
-	    << "symbol '" << sym
-	    << "' is not defined, returning provided default: " << def << endl;
+         dconfig_cat->spam()
+            << "symbol '" << sym
+            << "' is not defined, returning provided default: " << def << endl;
       return def;
       return def;
    }
    }
 }
 }
 
 
 template<class GetConfig>
 template<class GetConfig>
 ConfigString Config<GetConfig>::GetString(const ConfigString sym,
 ConfigString Config<GetConfig>::GetString(const ConfigString sym,
-					   const ConfigString def)
+                                           const ConfigString def)
 {
 {
    Init();
    Init();
    if (Defined(sym)) {
    if (Defined(sym)) {
       ConfigString ret = Get(sym);
       ConfigString ret = Get(sym);
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: '"
-			    << ret << "'" << endl;
+         dconfig_cat->spam() << "symbol '" << sym << "' defined, returning: '"
+                            << ret << "'" << endl;
       return ret;
       return ret;
    } else {
    } else {
       if (dconfig_cat->is_spam())
       if (dconfig_cat->is_spam())
-	 dconfig_cat->spam()
-	    << "symbol '" << sym
-	    << "' is not defined, returning provided default: '" << def
-	    << "'" << endl;
+         dconfig_cat->spam()
+            << "symbol '" << sym
+            << "' is not defined, returning provided default: '" << def
+            << "'" << endl;
       return def;
       return def;
    }
    }
 }
 }

+ 14 - 14
dtool/src/dconfig/notify.cxx

@@ -378,7 +378,7 @@ ptr() {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 bool Notify::
 bool Notify::
 assert_failure(const char *expression, int line,
 assert_failure(const char *expression, int line,
-	       const char *source_file) {
+               const char *source_file) {
   ostringstream message_str;
   ostringstream message_str;
   message_str 
   message_str 
     << expression << " at line " << line << " of " << source_file;
     << expression << " at line " << line << " of " << source_file;
@@ -471,23 +471,23 @@ config_initialized() {
     string notify_output = config_notify.GetString("notify-output", "");
     string notify_output = config_notify.GetString("notify-output", "");
     if (!notify_output.empty()) {
     if (!notify_output.empty()) {
       if (notify_output == "stdout") {
       if (notify_output == "stdout") {
-	cout.setf(ios::unitbuf);
-	set_ostream_ptr(&cout, false);
+        cout.setf(ios::unitbuf);
+        set_ostream_ptr(&cout, false);
 
 
       } else if (notify_output == "stderr") {
       } else if (notify_output == "stderr") {
-	set_ostream_ptr(&cerr, false);
+        set_ostream_ptr(&cerr, false);
 
 
       } else {
       } else {
-	Filename filename = notify_output;
-	filename.set_text();
-	ofstream *out = new ofstream;
-	if (!filename.open_write(*out)) {
-	  nout << "Unable to open file " << filename << " for output.\n";
-	  delete out;
-	} else {
-	  out->setf(ios::unitbuf);
-	  set_ostream_ptr(out, true);
-	}
+        Filename filename = notify_output;
+        filename.set_text();
+        ofstream *out = new ofstream;
+        if (!filename.open_write(*out)) {
+          nout << "Unable to open file " << filename << " for output.\n";
+          delete out;
+        } else {
+          out->setf(ios::unitbuf);
+          set_ostream_ptr(out, true);
+        }
       }
       }
     }
     }
   }
   }

+ 5 - 5
dtool/src/dconfig/notify.h

@@ -16,7 +16,7 @@
 #include <map>
 #include <map>
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : Notify
+//       Class : Notify
 // Description : An object that handles general error reporting to the
 // Description : An object that handles general error reporting to the
 //               user.  It contains a pointer to an ostream, initially
 //               user.  It contains a pointer to an ostream, initially
 //               cerr, which can be reset at will to point to
 //               cerr, which can be reset at will to point to
@@ -38,7 +38,7 @@ PUBLISHED:
   ostream *get_ostream_ptr() const;
   ostream *get_ostream_ptr() const;
 
 
   typedef bool AssertHandler(const char *expression, int line,
   typedef bool AssertHandler(const char *expression, int line,
-			     const char *source_file);
+                             const char *source_file);
   
   
   void set_assert_handler(AssertHandler *assert_handler);
   void set_assert_handler(AssertHandler *assert_handler);
   void clear_assert_handler();
   void clear_assert_handler();
@@ -51,9 +51,9 @@ PUBLISHED:
 
 
   NotifyCategory *get_top_category();
   NotifyCategory *get_top_category();
   NotifyCategory *get_category(const string &basename, 
   NotifyCategory *get_category(const string &basename, 
-			       NotifyCategory *parent_category);
+                               NotifyCategory *parent_category);
   NotifyCategory *get_category(const string &basename, 
   NotifyCategory *get_category(const string &basename, 
-			       const string &parent_fullname);
+                               const string &parent_fullname);
   NotifyCategory *get_category(const string &fullname);
   NotifyCategory *get_category(const string &fullname);
 
 
   static ostream &out();
   static ostream &out();
@@ -65,7 +65,7 @@ public:
   static long get_literal_flag();
   static long get_literal_flag();
 
 
   bool assert_failure(const char *expression, int line,
   bool assert_failure(const char *expression, int line,
-		      const char *source_file);
+                      const char *source_file);
 
 
   static NotifySeverity string_severity(const string &string);
   static NotifySeverity string_severity(const string &string);
 
 

+ 12 - 12
dtool/src/dconfig/notifyCategory.cxx

@@ -16,7 +16,7 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 NotifyCategory::
 NotifyCategory::
 NotifyCategory(const string &fullname, const string &basename, 
 NotifyCategory(const string &fullname, const string &basename, 
-	       NotifyCategory *parent) : 
+               NotifyCategory *parent) : 
   _fullname(fullname), 
   _fullname(fullname), 
   _basename(basename), 
   _basename(basename), 
   _parent(parent)
   _parent(parent)
@@ -49,8 +49,8 @@ NotifyCategory(const string &fullname, const string &basename,
       _severity = Notify::string_severity(severity_name);
       _severity = Notify::string_severity(severity_name);
       
       
       if (_severity == NS_unspecified) {
       if (_severity == NS_unspecified) {
-	nout << "Invalid severity name for " << config_name << ": "
-	     << severity_name << "\n";
+        nout << "Invalid severity name for " << config_name << ": "
+             << severity_name << "\n";
       }
       }
     }
     }
   }
   }
@@ -86,19 +86,19 @@ out(NotifySeverity severity, bool prefix) const {
   if (is_on(severity)) {
   if (is_on(severity)) {
     if (prefix) {
     if (prefix) {
       if (get_notify_timestamp()) {
       if (get_notify_timestamp()) {
-	// Format a timestamp to include as a prefix as well.
-	time_t now = time(NULL);
-	struct tm *ptm = localtime(&now);
-	
-	char buffer[128];
-	strftime(buffer, 128, ":%m-%d-%Y %H:%M:%S ", ptm);
-	nout << buffer;
+        // Format a timestamp to include as a prefix as well.
+        time_t now = time(NULL);
+        struct tm *ptm = localtime(&now);
+
+        char buffer[128];
+        strftime(buffer, 128, ":%m-%d-%Y %H:%M:%S ", ptm);
+        nout << buffer;
       }
       }
 
 
       if (severity == NS_info) {
       if (severity == NS_info) {
-	return nout << *this << ": ";
+        return nout << *this << ": ";
       } else {
       } else {
-	return nout << *this << "(" << severity << "): ";
+        return nout << *this << "(" << severity << "): ";
       }
       }
     } else {
     } else {
       return nout;
       return nout;

+ 2 - 2
dtool/src/dconfig/notifyCategory.h

@@ -14,7 +14,7 @@
 #include <vector>
 #include <vector>
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : NotifyCategory
+//       Class : NotifyCategory
 // Description : A particular category of error messages.  Typically
 // Description : A particular category of error messages.  Typically
 //               there will be one of these per package, so that we
 //               there will be one of these per package, so that we
 //               can turn on or off error messages at least at a
 //               can turn on or off error messages at least at a
@@ -25,7 +25,7 @@
 class EXPCL_DTOOLCONFIG NotifyCategory {
 class EXPCL_DTOOLCONFIG NotifyCategory {
 private:
 private:
   NotifyCategory(const string &fullname, const string &basename, 
   NotifyCategory(const string &fullname, const string &basename, 
-		 NotifyCategory *parent);
+                 NotifyCategory *parent);
   
   
 PUBLISHED:
 PUBLISHED:
   INLINE string get_fullname() const;
   INLINE string get_fullname() const;

+ 1 - 1
dtool/src/dconfig/notifyCategoryProxy.h

@@ -13,7 +13,7 @@
 #include "notify.h"
 #include "notify.h"
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : NotifyCategoryProxy
+//       Class : NotifyCategoryProxy
 // Description : A handy wrapper around a NotifyCategory pointer.
 // Description : A handy wrapper around a NotifyCategory pointer.
 //               This wrapper pretends to be a NotifyCategory object
 //               This wrapper pretends to be a NotifyCategory object
 //               itself, except that it is capable of initializing its
 //               itself, except that it is capable of initializing its

+ 73 - 73
dtool/src/dconfig/serialization.h

@@ -16,9 +16,9 @@ template <class X>
 class StdIns {
 class StdIns {
    public:
    public:
       INLINE ConfigString operator()(const X& val) {
       INLINE ConfigString operator()(const X& val) {
-	 ostringstream oss;
-	 oss << val;
-	 return oss.str();
+         ostringstream oss;
+         oss << val;
+         return oss.str();
       }
       }
 };
 };
 
 
@@ -26,10 +26,10 @@ template <class X>
 class StdExt {
 class StdExt {
    public:
    public:
       INLINE X operator()(ConfigString S) {
       INLINE X operator()(ConfigString S) {
-	 istringstream iss(S);
-	 X ret;
-	 iss >> ret;
-	 return ret;
+         istringstream iss(S);
+         X ret;
+         iss >> ret;
+         return ret;
       }
       }
 };
 };
 
 
@@ -47,15 +47,15 @@ class Serializer {
       Serializer() {}
       Serializer() {}
    public:
    public:
       Serializer(const Collection& C, ConfigString Delim = ":") :
       Serializer(const Collection& C, ConfigString Delim = ":") :
-	_result(Serializer::SerializeToString(C, Delim)) {}
+        _result(Serializer::SerializeToString(C, Delim)) {}
       Serializer(const Serializer<Collection, Inserter>& c) :
       Serializer(const Serializer<Collection, Inserter>& c) :
         _result(c._result) {}
         _result(c._result) {}
       ~Serializer() {}
       ~Serializer() {}
       INLINE ConfigString operator()() { return _result; }
       INLINE ConfigString operator()() { return _result; }
       INLINE ConfigString operator()(const Collection& C,
       INLINE ConfigString operator()(const Collection& C,
-				     const ConfigString& Delim = ":") {
-	 _result = SerializeToString(C, Delim);
-	 return _result;
+                                     const ConfigString& Delim = ":") {
+         _result = SerializeToString(C, Delim);
+         return _result;
       }
       }
       INLINE operator ConfigString() { return _result; }
       INLINE operator ConfigString() { return _result; }
 };
 };
@@ -63,14 +63,14 @@ class Serializer {
 template <class Collection, class Inserter>
 template <class Collection, class Inserter>
 ConfigString
 ConfigString
 Serializer<Collection, Inserter>::SerializeToString(const Collection& C,
 Serializer<Collection, Inserter>::SerializeToString(const Collection& C,
-						    const ConfigString& Delim)
+                                                    const ConfigString& Delim)
 {
 {
    ConfigString ret;
    ConfigString ret;
    Inserter in;
    Inserter in;
 
 
    for (TYPENAME Collection::const_iterator i=C.begin(); i!=C.end(); ++i) {
    for (TYPENAME Collection::const_iterator i=C.begin(); i!=C.end(); ++i) {
       if (i != C.begin())
       if (i != C.begin())
-	 ret += Delim;
+         ret += Delim;
       ret += in(*i);
       ret += in(*i);
    }
    }
    return ret;
    return ret;
@@ -84,86 +84,86 @@ class Deserializer {
       INLINE void Clear() { _result.erase(_result.begin(), _result.end()); }
       INLINE void Clear() { _result.erase(_result.begin(), _result.end()); }
       template <class ForwardIterator>
       template <class ForwardIterator>
       int FindFirstOfInString(ConfigString S, ForwardIterator DelimBegin,
       int FindFirstOfInString(ConfigString S, ForwardIterator DelimBegin,
-			      ForwardIterator DelimEnd) {
-	 int i = ConfigString::npos;
-	 ForwardIterator j = DelimBegin;
-
-	 while (j != DelimEnd) {
-	    int k = S.find(*j);
-	    if (k != ConfigString::npos)
-	       if ((i == ConfigString::npos) || (i > k))
-		  i = k;
-	    ++j;
-	 }
-	 return i;
+                              ForwardIterator DelimEnd) {
+         int i = ConfigString::npos;
+         ForwardIterator j = DelimBegin;
+
+         while (j != DelimEnd) {
+            int k = S.find(*j);
+            if (k != ConfigString::npos)
+               if ((i == ConfigString::npos) || (i > k))
+                  i = k;
+            ++j;
+         }
+         return i;
       }
       }
       template <class ForwardIterator>
       template <class ForwardIterator>
       int FindFirstNotOfInString(ConfigString S, ForwardIterator DelimBegin,
       int FindFirstNotOfInString(ConfigString S, ForwardIterator DelimBegin,
-				 ForwardIterator DelimEnd) {
-	 int i = ConfigString::npos;
-	 ForwardIterator j = DelimBegin;
-	 ForwardIterator k = DelimBegin;
-
-	 while (j != DelimEnd) {
-	    int l = S.find(*j);
-	    if (l != ConfigString::npos)
- 	       if ((i == ConfigString::npos) || (i > l)) {
-		  i = l;
-		  k = j;
-	       }
-	    ++j;
-	 }
-	 if (i != ConfigString::npos) {
-	    i += Serialize::Length(*k);
-	    if (i >= S.length())
-	       i = ConfigString::npos;
-	 }
-	 return i;
+                                 ForwardIterator DelimEnd) {
+         int i = ConfigString::npos;
+         ForwardIterator j = DelimBegin;
+         ForwardIterator k = DelimBegin;
+
+         while (j != DelimEnd) {
+            int l = S.find(*j);
+            if (l != ConfigString::npos)
+               if ((i == ConfigString::npos) || (i > l)) {
+                  i = l;
+                  k = j;
+               }
+            ++j;
+         }
+         if (i != ConfigString::npos) {
+            i += Serialize::Length(*k);
+            if (i >= S.length())
+               i = ConfigString::npos;
+         }
+         return i;
       }
       }
       template <class ForwardIterator>
       template <class ForwardIterator>
       void DeserializeFromString(ConfigString S, ForwardIterator DelimBegin,
       void DeserializeFromString(ConfigString S, ForwardIterator DelimBegin,
-				 ForwardIterator DelimEnd) {
-	 Clear();
-	 Extractor ex;
-
-	 while (!S.empty()) {
-	    int i = FindFirstOfInString(S, DelimBegin, DelimEnd);
-	    _result.push_back(ex(S.substr(0, i)));
-	    S.erase(0, i);
-	    i = FindFirstNotOfInString(S, DelimBegin, DelimEnd);
-	    S.erase(0, i);
-	 }
+                                 ForwardIterator DelimEnd) {
+         Clear();
+         Extractor ex;
+
+         while (!S.empty()) {
+            int i = FindFirstOfInString(S, DelimBegin, DelimEnd);
+            _result.push_back(ex(S.substr(0, i)));
+            S.erase(0, i);
+            i = FindFirstNotOfInString(S, DelimBegin, DelimEnd);
+            S.erase(0, i);
+         }
       }
       }
       void DeserializeFromString(ConfigString S, ConfigString Delim) {
       void DeserializeFromString(ConfigString S, ConfigString Delim) {
-	 Clear();
-	 Extractor ex;
-
-	 while (!S.empty()) {
-	    size_t i = S.find_first_of(Delim);
-	    _result.push_back(ex(S.substr(0, i)));
-	    if (i == ConfigString::npos)
-	       S.erase(0, i);
-	    else
-	       S.erase(0, i+1);
-	 }
+         Clear();
+         Extractor ex;
+
+         while (!S.empty()) {
+            size_t i = S.find_first_of(Delim);
+            _result.push_back(ex(S.substr(0, i)));
+            if (i == ConfigString::npos)
+               S.erase(0, i);
+            else
+               S.erase(0, i+1);
+         }
       }
       }
       Deserializer() {}
       Deserializer() {}
    public:
    public:
       Deserializer(ConfigString S, ConfigString Delim = ":") {
       Deserializer(ConfigString S, ConfigString Delim = ":") {
-	 Deserializer::DeserializeFromString(S, Delim);
+         Deserializer::DeserializeFromString(S, Delim);
       }
       }
       template <class ForwardIterator>
       template <class ForwardIterator>
       Deserializer(ConfigString S, ForwardIterator DelimBegin,
       Deserializer(ConfigString S, ForwardIterator DelimBegin,
-		   ForwardIterator DelimEnd) {
-	 Deserializer::DeserializeFromString(S, DelimBegin, DelimEnd);
+                   ForwardIterator DelimEnd) {
+         Deserializer::DeserializeFromString(S, DelimBegin, DelimEnd);
       }
       }
       ~Deserializer() {}
       ~Deserializer() {}
       INLINE const Collection& operator()() { return _result; }
       INLINE const Collection& operator()() { return _result; }
       template <class ForwardIterator>
       template <class ForwardIterator>
       INLINE const Collection& operator()(ConfigString S,
       INLINE const Collection& operator()(ConfigString S,
-					  ForwardIterator DelimBegin,
-					  ForwardIterator DelimEnd) {
-	 Deserializer::DeserializeFromString(S, DelimBegin, DelimEnd);
+                                          ForwardIterator DelimBegin,
+                                          ForwardIterator DelimEnd) {
+         Deserializer::DeserializeFromString(S, DelimBegin, DelimEnd);
       }
       }
       INLINE operator const Collection&() { return _result; }
       INLINE operator const Collection&() { return _result; }
 };
 };

+ 3 - 3
dtool/src/dconfig/symbolEnt.h

@@ -17,7 +17,7 @@ namespace Config {
 class EXPCL_DTOOLCONFIG SymbolEnt {
 class EXPCL_DTOOLCONFIG SymbolEnt {
    public:
    public:
       enum SymbolEntSrc { ConfigFile, Environment, CommandEnv, Commandline,
       enum SymbolEntSrc { ConfigFile, Environment, CommandEnv, Commandline,
-			  Other, Invalid };
+                          Other, Invalid };
    private:
    private:
       ConfigString _src;
       ConfigString _src;
       ConfigString _val;
       ConfigString _val;
@@ -26,8 +26,8 @@ class EXPCL_DTOOLCONFIG SymbolEnt {
    public:
    public:
       SymbolEnt() : _srctok(Invalid) {}
       SymbolEnt() : _srctok(Invalid) {}
       SymbolEnt(enum SymbolEntSrc tok, const ConfigString& val,
       SymbolEnt(enum SymbolEntSrc tok, const ConfigString& val,
-		const ConfigString& src = "", bool state = false)
-	: _src(src), _val(val), _state(state), _srctok(tok) {}
+                const ConfigString& src = "", bool state = false)
+        : _src(src), _val(val), _state(state), _srctok(tok) {}
       SymbolEnt(const SymbolEnt& c) : _src(c._src), _val(c._val),
       SymbolEnt(const SymbolEnt& c) : _src(c._src), _val(c._val),
           _state(c._state), _srctok(c._srctok) {}
           _state(c._state), _srctok(c._srctok) {}
       INLINE SymbolEnt& operator=(const SymbolEnt&);
       INLINE SymbolEnt& operator=(const SymbolEnt&);

+ 1 - 1
dtool/src/dconfig/test_pfstream.cxx

@@ -12,7 +12,7 @@ void ReadIt(istream& ifs) {
    while (!ifs.eof()) {
    while (!ifs.eof()) {
       std::getline(ifs, line);
       std::getline(ifs, line);
       if (line.length() != 0)
       if (line.length() != 0)
-	 cout << line << endl;
+         cout << line << endl;
    }
    }
 }
 }
 
 

+ 2 - 2
dtool/src/dconfig/test_serialization.cxx

@@ -42,7 +42,7 @@ void TestFromString()
    intlist ides1 = intdes1;
    intlist ides1 = intdes1;
    for (intlist::iterator i=ides1.begin(); i!=ides1.end(); ++i) {
    for (intlist::iterator i=ides1.begin(); i!=ides1.end(); ++i) {
       if (i != ides1.begin())
       if (i != ides1.begin())
-	 cout << ", ";
+         cout << ", ";
       cout << (*i);
       cout << (*i);
    }
    }
    cout << endl;
    cout << endl;
@@ -52,7 +52,7 @@ void TestFromString()
    floatvec fdes1 = floatdes1;
    floatvec fdes1 = floatdes1;
    for (floatvec::iterator j=fdes1.begin(); j!=fdes1.end(); ++j) {
    for (floatvec::iterator j=fdes1.begin(); j!=fdes1.end(); ++j) {
       if (j != fdes1.begin())
       if (j != fdes1.begin())
-	 cout << ", ";
+         cout << ", ";
       cout << (*j);
       cout << (*j);
    }
    }
    cout << endl;
    cout << endl;

+ 10 - 10
dtool/src/dtoolbase/version.h

@@ -1,10 +1,10 @@
-#define PANDA_VERSION_MAJOR                0
-#define PANDA_VERSION_MINOR                0
-#define PANDA_VERSION_BUILDSUBVERSION      0
-#define PANDA_VERSION_BUILDSUBSUBVERSION   1
-
-#define PANDA_VERSION_MAJOR_STR                "0"
-#define PANDA_VERSION_MINOR_STR                "0"
-#define PANDA_VERSION_BUILDSUBVERSION_STR      "0"
-#define PANDA_VERSION_BUILDSUBSUBVERSION_STR   "1"
-
+#define PANDA_VERSION_MAJOR                0
+#define PANDA_VERSION_MINOR                0
+#define PANDA_VERSION_BUILDSUBVERSION      0
+#define PANDA_VERSION_BUILDSUBSUBVERSION   1
+
+#define PANDA_VERSION_MAJOR_STR                "0"
+#define PANDA_VERSION_MINOR_STR                "0"
+#define PANDA_VERSION_BUILDSUBVERSION_STR      "0"
+#define PANDA_VERSION_BUILDSUBSUBVERSION_STR   "1"
+

+ 1 - 1
dtool/src/dtoolutil/dSearchPath.I

@@ -15,7 +15,7 @@
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 INLINE Filename DSearchPath::
 INLINE Filename DSearchPath::
 search_path(const Filename &filename, const string &path, 
 search_path(const Filename &filename, const string &path, 
-	    const string &delimiters) {
+            const string &delimiters) {
   DSearchPath search(path, delimiters);
   DSearchPath search(path, delimiters);
   return search.find_file(filename);
   return search.find_file(filename);
 }
 }

+ 2 - 2
dtool/src/dtoolutil/dSearchPath.cxx

@@ -202,7 +202,7 @@ prepend_path(const DSearchPath &path) {
   if (!path._directories.empty()) {
   if (!path._directories.empty()) {
     Directories new_directories = path._directories;
     Directories new_directories = path._directories;
     copy(_directories.begin(), _directories.end(),
     copy(_directories.begin(), _directories.end(),
-	 back_inserter(new_directories));
+         back_inserter(new_directories));
     _directories.swap(new_directories);
     _directories.swap(new_directories);
   }
   }
 }
 }
@@ -270,7 +270,7 @@ find_file(const Filename &filename) const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 int DSearchPath::
 int DSearchPath::
 find_all_files(const Filename &filename, 
 find_all_files(const Filename &filename, 
-	       DSearchPath::Results &results) const {
+               DSearchPath::Results &results) const {
   results._files.clear();
   results._files.clear();
 
 
   Directories::const_iterator di;
   Directories::const_iterator di;

+ 3 - 3
dtool/src/dtoolutil/dSearchPath.h

@@ -13,7 +13,7 @@
 #include <vector>
 #include <vector>
 
 
 ///////////////////////////////////////////////////////////////////
 ///////////////////////////////////////////////////////////////////
-// 	 Class : DSearchPath
+//       Class : DSearchPath
 // Description : This class stores a list of directories that can be
 // Description : This class stores a list of directories that can be
 //               searched, in order, to locate a particular file.  It
 //               searched, in order, to locate a particular file.  It
 //               is normally constructed by passing it a traditional
 //               is normally constructed by passing it a traditional
@@ -51,7 +51,7 @@ PUBLISHED:
   void append_directory(const Filename &directory);
   void append_directory(const Filename &directory);
   void prepend_directory(const Filename &directory);
   void prepend_directory(const Filename &directory);
   void append_path(const string &path,
   void append_path(const string &path,
-		   const string &delimiters = ": \t\n");
+                   const string &delimiters = ": \t\n");
   void append_path(const DSearchPath &path);
   void append_path(const DSearchPath &path);
   void prepend_path(const DSearchPath &path);
   void prepend_path(const DSearchPath &path);
 
 
@@ -64,7 +64,7 @@ PUBLISHED:
 
 
   INLINE static Filename 
   INLINE static Filename 
   search_path(const Filename &filename, const string &path,
   search_path(const Filename &filename, const string &path,
-	      const string &delimiters = ": \t\n");
+              const string &delimiters = ": \t\n");
 
 
   void output(ostream &out, const string &separator = ":") const;
   void output(ostream &out, const string &separator = ":") const;
   void write(ostream &out, int indent_level = 0) const;
   void write(ostream &out, int indent_level = 0) const;

+ 13 - 13
dtool/src/dtoolutil/executionEnvironment.cxx

@@ -82,20 +82,20 @@ expand_string(const string &str) {
       size_t end = start;
       size_t end = start;
 
 
       if (str[start] == '{') {
       if (str[start] == '{') {
-	// Curly braces delimit the variable name explicitly.
-	end = str.find('}', start + 1);
-	if (end != string::npos) {
-	  varname = str.substr(start + 1, end - (start + 1));
-	  end++;
-	}
+        // Curly braces delimit the variable name explicitly.
+        end = str.find('}', start + 1);
+        if (end != string::npos) {
+          varname = str.substr(start + 1, end - (start + 1));
+          end++;
+        }
       }
       }
 
 
       if (end == start) {
       if (end == start) {
-	// Scan for the end of the variable name.
-	while (end < str.length() && (isalnum(str[end]) || str[end] == '_')) {
-	  end++;
-	}
-	varname = str.substr(start, end - start);
+        // Scan for the end of the variable name.
+        while (end < str.length() && (isalnum(str[end]) || str[end] == '_')) {
+          end++;
+        }
+        varname = str.substr(start, end - start);
       }
       }
 
 
       string subst = 
       string subst = 
@@ -274,8 +274,8 @@ read_environment_variables() {
     if (ch == '=') {
     if (ch == '=') {
       ch = proc.get();
       ch = proc.get();
       while (!proc.eof() && !proc.fail() && ch != '\0') {
       while (!proc.eof() && !proc.fail() && ch != '\0') {
-	value += (char)ch;
-	ch = proc.get();
+        value += (char)ch;
+        ch = proc.get();
       }
       }
     }
     }
 
 

+ 1 - 1
dtool/src/dtoolutil/executionEnvironment.h

@@ -14,7 +14,7 @@
 #include <map>
 #include <map>
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : ExecutionEnvironment
+//       Class : ExecutionEnvironment
 // Description : Encapsulates access to the environment variables and
 // Description : Encapsulates access to the environment variables and
 //               command-line arguments at the time of execution.
 //               command-line arguments at the time of execution.
 //               This is encapsulated to support accessing these
 //               This is encapsulated to support accessing these

+ 29 - 29
dtool/src/dtoolutil/filename.cxx

@@ -117,8 +117,8 @@ convert_pathname(const string &unix_style_pathname) {
     windows_pathname = front_to_back_slash(unix_style_pathname);
     windows_pathname = front_to_back_slash(unix_style_pathname);
 
 
   } else if (unix_style_pathname.length() > 3 &&
   } else if (unix_style_pathname.length() > 3 &&
-	     isalpha(unix_style_pathname[1]) &&
-	     unix_style_pathname[2] == '/') {
+             isalpha(unix_style_pathname[1]) &&
+             unix_style_pathname[2] == '/') {
     // This is a pathname that begins with a single letter.  That must
     // This is a pathname that begins with a single letter.  That must
     // be the drive letter.
     // be the drive letter.
     windows_pathname = 
     windows_pathname = 
@@ -242,7 +242,7 @@ from_os_specific(const string &os_specific, Filename::Type type) {
     for (p = 0; p < panda_root.length() && matches; p++) {
     for (p = 0; p < panda_root.length() && matches; p++) {
       char c = tolower(panda_root[p]);
       char c = tolower(panda_root[p]);
       if (c == '\\') {
       if (c == '\\') {
-	c = '/';
+        c = '/';
       }
       }
       matches = (c == tolower(result[p]));
       matches = (c == tolower(result[p]));
     }
     }
@@ -253,7 +253,7 @@ from_os_specific(const string &os_specific, Filename::Type type) {
       result = result.substr(panda_root.length());
       result = result.substr(panda_root.length());
       assert(!result.empty());
       assert(!result.empty());
       if (result[0] != '/') {
       if (result[0] != '/') {
-	result = '/' + result;
+        result = '/' + result;
       }
       }
       Filename filename(result);
       Filename filename(result);
       filename.set_type(type);
       filename.set_type(type);
@@ -500,7 +500,7 @@ standardize() {
     if (component == ".") {
     if (component == ".") {
       // Ignore /./.
       // Ignore /./.
     } else if (component == ".." && !components.empty() && 
     } else if (component == ".." && !components.empty() && 
-	       !(components.back() == "..")) {
+               !(components.back() == "..")) {
       // Back up.
       // Back up.
       components.pop_back();
       components.pop_back();
     } else {
     } else {
@@ -808,8 +808,8 @@ is_executable() const {
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 int Filename::
 int Filename::
 compare_timestamps(const Filename &other, 
 compare_timestamps(const Filename &other, 
-		   bool this_missing_is_old, 
-		   bool other_missing_is_old) const {
+                   bool this_missing_is_old, 
+                   bool other_missing_is_old) const {
   string os_specific = to_os_specific();
   string os_specific = to_os_specific();
   string other_os_specific = other.to_os_specific();
   string other_os_specific = other.to_os_specific();
 
 
@@ -883,7 +883,7 @@ compare_timestamps(const Filename &other,
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 bool Filename::
 bool Filename::
 resolve_filename(const DSearchPath &searchpath, 
 resolve_filename(const DSearchPath &searchpath, 
-		 const string &default_extension) {
+                 const string &default_extension) {
   string found;
   string found;
 
 
   if (is_local()) {
   if (is_local()) {
@@ -893,9 +893,9 @@ resolve_filename(const DSearchPath &searchpath,
       // We didn't find it with the given extension; can we try the
       // We didn't find it with the given extension; can we try the
       // default extension?
       // default extension?
       if (get_extension().empty() && !default_extension.empty()) {
       if (get_extension().empty() && !default_extension.empty()) {
-	Filename try_ext = *this;
-	try_ext.set_extension(default_extension);
-	found = searchpath.find_file(try_ext.get_fullpath());
+        Filename try_ext = *this;
+        try_ext.set_extension(default_extension);
+        found = searchpath.find_file(try_ext.get_fullpath());
       }
       }
     }
     }
 
 
@@ -908,11 +908,11 @@ resolve_filename(const DSearchPath &searchpath,
       // The full pathname doesn't exist with the given extension;
       // The full pathname doesn't exist with the given extension;
       // does it exist with the default extension?
       // does it exist with the default extension?
       if (get_extension().empty() && !default_extension.empty()) {
       if (get_extension().empty() && !default_extension.empty()) {
-	Filename try_ext = *this;
-	try_ext.set_extension(default_extension);
-	if (try_ext.exists()) {
-	  found = try_ext;
-	}
+        Filename try_ext = *this;
+        try_ext.set_extension(default_extension);
+        if (try_ext.exists()) {
+          found = try_ext;
+        }
       }
       }
     }
     }
   }
   }
@@ -1226,8 +1226,8 @@ touch() const {
       // So the file doesn't already exist; create it.
       // So the file doesn't already exist; create it.
       int fd = creat(os_specific.c_str(), 0666);
       int fd = creat(os_specific.c_str(), 0666);
       if (fd < 0) {
       if (fd < 0) {
-	perror(os_specific.c_str());
-	return false;
+        perror(os_specific.c_str());
+        return false;
       }
       }
       close(fd);
       close(fd);
       return true;
       return true;
@@ -1274,17 +1274,17 @@ rename_to(const Filename &other) const {
   string os_specific = to_os_specific();
   string os_specific = to_os_specific();
   string other_os_specific = other.to_os_specific();
   string other_os_specific = other.to_os_specific();
   return (rename(os_specific.c_str(), 
   return (rename(os_specific.c_str(), 
-		 other_os_specific.c_str()) == 0);
+                 other_os_specific.c_str()) == 0);
 }
 }
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 //     Function: Filename::make_dir
 //     Function: Filename::make_dir
 //       Access: Public
 //       Access: Public
 //  Description: Creates all the directories in the path to the file
 //  Description: Creates all the directories in the path to the file
-//		 specified in the filename, except for the basename
-//		 itself.  This assumes that the Filename contains the
-//		 name of a file, not a directory name; it ensures that
-//		 the directory containing the file exists.
+//               specified in the filename, except for the basename
+//               itself.  This assumes that the Filename contains the
+//               name of a file, not a directory name; it ensures that
+//               the directory containing the file exists.
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
 bool Filename::
 bool Filename::
 make_dir() const {
 make_dir() const {
@@ -1343,14 +1343,14 @@ locate_basename() {
       // we want to treat them as a single slash.  The directory
       // we want to treat them as a single slash.  The directory
       // therefore actually ends at the first of these; back up a bit.
       // therefore actually ends at the first of these; back up a bit.
       while (_dirname_end > 0 && _filename[_dirname_end-1] == '/') {
       while (_dirname_end > 0 && _filename[_dirname_end-1] == '/') {
-	_dirname_end--;
+        _dirname_end--;
       }
       }
       
       
       // Another exception: if the dirname was nothing but slashes, it
       // Another exception: if the dirname was nothing but slashes, it
       // was the root directory, or / itself.  In this case the dirname
       // was the root directory, or / itself.  In this case the dirname
       // does include the terminal slash (of course).
       // does include the terminal slash (of course).
       if (_dirname_end == 0) {
       if (_dirname_end == 0) {
-	_dirname_end = 1;
+        _dirname_end = 1;
       }
       }
       
       
     } else {
     } else {
@@ -1424,7 +1424,7 @@ get_common_prefix(const string &other) const {
 
 
   // First, get the length of the common initial substring.
   // First, get the length of the common initial substring.
   while (len < length() && len < other.length() &&
   while (len < length() && len < other.length() &&
-	 _filename[len] == other[len]) {
+         _filename[len] == other[len]) {
     len++;
     len++;
   }
   }
 
 
@@ -1455,11 +1455,11 @@ count_slashes(const string &str) {
       // Skip consecutive slashes.
       // Skip consecutive slashes.
       ++si;
       ++si;
       while (*si == '/') {
       while (*si == '/') {
-	++si;
+        ++si;
       }
       }
       if (si == str.end()) {
       if (si == str.end()) {
-	// Oops, that was a terminal slash.  Don't count it.
-	count--;
+        // Oops, that was a terminal slash.  Don't count it.
+        count--;
       }
       }
 
 
     } else {
     } else {

+ 6 - 6
dtool/src/dtoolutil/filename.h

@@ -24,7 +24,7 @@
 class DSearchPath;
 class DSearchPath;
 
 
 ////////////////////////////////////////////////////////////////////
 ////////////////////////////////////////////////////////////////////
-// 	 Class : Filename
+//       Class : Filename
 // Description : The name of a file, such as a texture file or an Egg
 // Description : The name of a file, such as a texture file or an Egg
 //               file.  Stores the full pathname, and includes
 //               file.  Stores the full pathname, and includes
 //               functions for extracting out the directory prefix
 //               functions for extracting out the directory prefix
@@ -72,9 +72,9 @@ PUBLISHED:
   INLINE static Filename executable_filename(const string &filename);
   INLINE static Filename executable_filename(const string &filename);
 
 
   static Filename from_os_specific(const string &os_specific, 
   static Filename from_os_specific(const string &os_specific, 
-				   Type type = T_general);
+                                   Type type = T_general);
   static Filename temporary(const string &dirname, const string &prefix,
   static Filename temporary(const string &dirname, const string &prefix,
-			    Type type = T_general);
+                            Type type = T_general);
 
 
   // Assignment is via the = operator.
   // Assignment is via the = operator.
   INLINE Filename &operator = (const string &filename);
   INLINE Filename &operator = (const string &filename);
@@ -134,10 +134,10 @@ PUBLISHED:
   bool is_directory() const;
   bool is_directory() const;
   bool is_executable() const;
   bool is_executable() const;
   int compare_timestamps(const Filename &other,
   int compare_timestamps(const Filename &other,
-			 bool this_missing_is_old = true,
-			 bool other_missing_is_old = true) const;
+                         bool this_missing_is_old = true,
+                         bool other_missing_is_old = true) const;
   bool resolve_filename(const DSearchPath &searchpath,
   bool resolve_filename(const DSearchPath &searchpath,
-			const string &default_extension = string());
+                        const string &default_extension = string());
   bool make_relative_to(Filename directory, bool allow_backups = true);
   bool make_relative_to(Filename directory, bool allow_backups = true);
   int find_on_searchpath(const DSearchPath &searchpath);
   int find_on_searchpath(const DSearchPath &searchpath);
 
 

+ 16 - 16
dtool/src/dtoolutil/gnu_getopt.h

@@ -25,7 +25,7 @@
 #define getopt_long gnu_getopt_long
 #define getopt_long gnu_getopt_long
 #define getopt_long_only gnu_getopt_long_only
 #define getopt_long_only gnu_getopt_long_only
 
 
-#ifdef	__cplusplus
+#ifdef  __cplusplus
 extern "C" {
 extern "C" {
 #endif
 #endif
 
 
@@ -66,9 +66,9 @@ extern int optopt;
    zero.
    zero.
 
 
    The field `has_arg' is:
    The field `has_arg' is:
-   no_argument		(or 0) if the option does not take an argument,
-   required_argument	(or 1) if the option requires an argument,
-   optional_argument 	(or 2) if the option takes an optional argument.
+   no_argument          (or 0) if the option does not take an argument,
+   required_argument    (or 1) if the option requires an argument,
+   optional_argument    (or 2) if the option takes an optional argument.
 
 
    If the field `flag' is not NULL, it points to a variable that is set
    If the field `flag' is not NULL, it points to a variable that is set
    to the value given in the field `val' when the option is found, but
    to the value given in the field `val' when the option is found, but
@@ -83,7 +83,7 @@ extern int optopt;
 
 
 struct option
 struct option
 {
 {
-#if	__STDC__
+#if     __STDC__
   const char *name;
   const char *name;
 #else
 #else
   char *name;
   char *name;
@@ -97,28 +97,28 @@ struct option
 
 
 /* Names for the values of the `has_arg' field of `struct option'.  */
 /* Names for the values of the `has_arg' field of `struct option'.  */
 
 
-#define	no_argument		0
-#define required_argument	1
-#define optional_argument	2
+#define no_argument             0
+#define required_argument       1
+#define optional_argument       2
 
 
 extern EXPCL_DTOOL int
 extern EXPCL_DTOOL int
 getopt (int argc, char *const *argv, const char *shortopts);
 getopt (int argc, char *const *argv, const char *shortopts);
 extern EXPCL_DTOOL int
 extern EXPCL_DTOOL int
 getopt_long (int argc, char *const *argv, const char *shortopts,
 getopt_long (int argc, char *const *argv, const char *shortopts,
-	     const struct option *long_options, int *opt_index);
+             const struct option *long_options, int *opt_index);
 extern EXPCL_DTOOL int
 extern EXPCL_DTOOL int
 getopt_long_only (int argc, char *const *argv,
 getopt_long_only (int argc, char *const *argv,
-		  const char *shortopts,
-		  const struct option *long_options, 
-		  int *opt_index);
+                  const char *shortopts,
+                  const struct option *long_options, 
+                  int *opt_index);
 
 
 /* Internal only.  Users should not call this directly.  */
 /* Internal only.  Users should not call this directly.  */
 extern int _getopt_internal (int argc, char *const *argv,
 extern int _getopt_internal (int argc, char *const *argv,
-			     const char *shortopts,
-		             const struct option *longopts, int *longind,
-			     int long_only);
+                             const char *shortopts,
+                             const struct option *longopts, int *longind,
+                             int long_only);
 
 
-#ifdef	__cplusplus
+#ifdef  __cplusplus
 }
 }
 #endif
 #endif
 
 

برخی فایل ها در این مقایسه diff نمایش داده نمی شوند زیرا تعداد فایل ها بسیار زیاد است