Fixed visibility -> validity to match dtd

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@15164 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
CaS 2002-11-28 07:25:02 +00:00
parent 4c4d520d6b
commit e8551b6817

View file

@ -1964,7 +1964,7 @@ try:
- (NSMutableDictionary*) parseInstanceVariables - (NSMutableDictionary*) parseInstanceVariables
{ {
NSString *visibility = @"private"; NSString *validity = @"private";
NSMutableDictionary *ivars; NSMutableDictionary *ivars;
BOOL shouldDocument = documentAllInstanceVariables; BOOL shouldDocument = documentAllInstanceVariables;
@ -1984,27 +1984,27 @@ try:
if ((token = [self parseIdentifier]) == nil if ((token = [self parseIdentifier]) == nil
|| [self parseSpace] >= length) || [self parseSpace] >= length)
{ {
[self log: @"interface with bad visibility directive"]; [self log: @"interface with bad validity directive"];
goto fail; goto fail;
} }
if ([token isEqual: @"private"] == YES) if ([token isEqual: @"private"] == YES)
{ {
ASSIGN(visibility, token); ASSIGN(validity, token);
shouldDocument = documentAllInstanceVariables; shouldDocument = documentAllInstanceVariables;
} }
else if ([token isEqual: @"protected"] == YES) else if ([token isEqual: @"protected"] == YES)
{ {
ASSIGN(visibility, token); ASSIGN(validity, token);
shouldDocument = YES; shouldDocument = YES;
} }
else if ([token isEqual: @"public"] == YES) else if ([token isEqual: @"public"] == YES)
{ {
ASSIGN(visibility, token); ASSIGN(validity, token);
shouldDocument = YES; shouldDocument = YES;
} }
else else
{ {
[self log: @"interface with bad visibility (%@)", token]; [self log: @"interface with bad validity (%@)", token];
goto fail; goto fail;
} }
} }
@ -2019,7 +2019,7 @@ try:
if (iv != nil) if (iv != nil)
{ {
if ([visibility isEqual: @"private"] == NO) if ([validity isEqual: @"private"] == NO)
{ {
NSString *n = [iv objectForKey: @"Name"]; NSString *n = [iv objectForKey: @"Name"];
@ -2035,7 +2035,7 @@ try:
[self appendComment: c to: iv]; [self appendComment: c to: iv];
} }
} }
[iv setObject: visibility forKey: @"Visibility"]; [iv setObject: validity forKey: @"Validity"];
[ivars setObject: iv forKey: [iv objectForKey: @"Name"]]; [ivars setObject: iv forKey: [iv objectForKey: @"Name"]];
} }
} }