--- a/ClassCategoryReader.st Thu Feb 02 13:13:16 1995 +0100
+++ b/ClassCategoryReader.st Thu Feb 02 13:23:05 1995 +0100
@@ -11,7 +11,7 @@
"
Object subclass:#ClassCategoryReader
- instanceVariableNames:'myClass myCategory privacy ignore'
+ instanceVariableNames:'myClass myCategory privacy ignore primSpec'
classVariableNames:''
poolDictionaries:''
category:'Kernel-Support'
@@ -21,7 +21,7 @@
COPYRIGHT (c) 1989 by Claus Gittinger
All Rights Reserved
-$Header: /cvs/stx/stx/libbasic/ClassCategoryReader.st,v 1.11 1994-10-28 01:19:53 claus Exp $
+$Header: /cvs/stx/stx/libbasic/ClassCategoryReader.st,v 1.12 1995-02-02 12:20:48 claus Exp $
'!
!ClassCategoryReader class methodsFor:'documentation'!
@@ -42,7 +42,7 @@
version
"
-$Header: /cvs/stx/stx/libbasic/ClassCategoryReader.st,v 1.11 1994-10-28 01:19:53 claus Exp $
+$Header: /cvs/stx/stx/libbasic/ClassCategoryReader.st,v 1.12 1995-02-02 12:20:48 claus Exp $
"
!
@@ -63,6 +63,12 @@
^ self new class:aClass category:aCategory
!
+class:aClass primitiveSpec:which
+ "return a ClassCategoryReader to read a primitiveSpec chunk"
+
+ ^ self new class:aClass primitiveSpec:which
+!
+
skippingChunks
"return a class categoryReader which skips chunks up to the next empty one"
@@ -76,7 +82,14 @@
myClass := aClass.
myCategory := aCategory.
- privacy := nil.
+ ignore := false
+!
+
+class:aClass primitiveSpec:which
+ "set the instance variables"
+
+ myClass := aClass.
+ primSpec := which.
ignore := false
! !
@@ -110,6 +123,13 @@
aString := aStream nextChunk.
done := aString isNil or:[aString isEmpty].
done ifFalse:[
+ primSpec notNil ifTrue:[
+ myClass perform:primSpec with:aString.
+ "
+ ignore rest
+ "
+ ignore := true
+ ].
ignore ifFalse:[
method := myClass compiler compile:aString
forClass:myClass