--- a/Smalltalk.st Sat Jul 20 14:28:22 1996 +0200
+++ b/Smalltalk.st Mon Jul 22 11:12:10 1996 +0200
@@ -2183,131 +2183,131 @@
].
[
- Class withoutUpdatingChangesDo:
- [
- ok := false.
-
- "
- first, look for a loader-driver file (in fileIn/xxx.ld)
- "
- (ok := self fileIn:('fileIn/' , aClassName , '.ld') lazy:loadLazy silent:beSilent)
- ifFalse:[
- shortName := self fileNameForClass:aClassName.
- "
- try abbreviated driver-file (in fileIn/xxx.ld)
- "
- shortName ~= aClassName ifTrue:[
- ok := self fileIn:('fileIn/' , shortName , '.ld') lazy:loadLazy silent:beSilent
- ].
- ok ifFalse:[
- "
- then, if dynamic linking is available,
- "
- (LoadBinaries and:[ObjectFileLoader notNil]) ifTrue:[
- sharedLibExtension := ObjectFileLoader sharedLibraryExtension.
-
- "
- first look for a class packages shared binary in binary/xxx.o
- "
- libName := self libraryFileNameOfClass:aClassName.
- libName notNil ifTrue:[
- (ok := self fileInClass:aClassName fromObject:(libName, sharedLibExtension))
- ifFalse:[
- sharedLibExtension ~= '.o' ifTrue:[
- ok := self fileInClass:aClassName fromObject:(libName, '.o')
- ]
- ].
- ].
-
- "
- then, look for a shared binary in binary/xxx.o
- "
- ok ifFalse:[
- (ok := self fileInClass:aClassName fromObject:(aClassName, sharedLibExtension))
- ifFalse:[
- sharedLibExtension ~= '.o' ifTrue:[
- ok := self fileInClass:aClassName fromObject:(aClassName, '.o')
- ].
- ok ifFalse:[
- shortName ~= aClassName ifTrue:[
- (ok := self fileInClass:aClassName fromObject:(shortName, sharedLibExtension))
- ifFalse:[
- sharedLibExtension ~= '.o' ifTrue:[
- ok := self fileInClass:aClassName fromObject:(shortName, '.o')
- ]
- ]
- ].
- ].
- ].
- ].
- ].
-
- "
- if that did not work, look for a compiled-bytecode file ...
- "
- ok ifFalse:[
- (ok := self fileIn:(aClassName , '.cls') lazy:loadLazy silent:beSilent)
- ifFalse:[
- shortName ~= aClassName ifTrue:[
- ok := self fileIn:(shortName , '.cls') lazy:loadLazy silent:beSilent
- ]
- ]
- ].
-
- "
- if that did not work, look for an st-source file ...
- "
- ok ifFalse:[
- (ok := self fileIn:(aClassName , '.st') lazy:loadLazy silent:beSilent)
- ifFalse:[
- shortName ~= aClassName ifTrue:[
- ok := self fileIn:(shortName , '.st') lazy:loadLazy silent:beSilent
- ].
- ok ifFalse:[
- "
- ... and in the standard source-directory
- "
- (ok := self fileIn:('source/' , aClassName , '.st') lazy:loadLazy silent:beSilent)
- ifFalse:[
- shortName ~= aClassName ifTrue:[
- ok := self fileIn:('source/' , shortName , '.st') lazy:loadLazy silent:beSilent
- ]
- ]
- ]
- ].
- ok ifFalse:[
- "
- new: if there is a sourceCodeManager, ask it for the classes sourceCode
- "
- (mgr := Smalltalk at:#SourceCodeManager) notNil ifTrue:[
- inStream := mgr mostRecentSourceStreamForClassNamed:aClassName.
- inStream notNil ifTrue:[
- ok := self fileInStream:inStream lazy:loadLazy silent:beSilent logged:false addPath:nil.
- ]
- ].
- ].
- ].
- ].
- ]
- ].
- ok ifTrue:[
- newClass := self at:(aClassName asSymbol).
- newClass notNil ifTrue:[
- doInit ifTrue:[
- newClass initialize
- ]
- ]
- ].
+ Class withoutUpdatingChangesDo:
+ [
+ ok := false.
+
+ shortName := self fileNameForClass:aClassName.
+ "
+ first, look for a loader-driver file (in fileIn/xxx.ld)
+ "
+ (ok := self fileIn:('fileIn/' , shortName , '.ld') lazy:loadLazy silent:beSilent)
+ ifFalse:[
+ "
+ try abbreviated driver-file (in fileIn/xxx.ld)
+ "
+ shortName ~= aClassName ifTrue:[
+ ok := self fileIn:('fileIn/' , aClassName , '.ld') lazy:loadLazy silent:beSilent
+ ].
+ ok ifFalse:[
+ "
+ then, if dynamic linking is available,
+ "
+ (LoadBinaries and:[ObjectFileLoader notNil]) ifTrue:[
+ sharedLibExtension := ObjectFileLoader sharedLibraryExtension.
+
+ "
+ first look for a class packages shared binary in binary/xxx.o
+ "
+ libName := self libraryFileNameOfClass:aClassName.
+ libName notNil ifTrue:[
+ (ok := self fileInClass:aClassName fromObject:(libName, sharedLibExtension))
+ ifFalse:[
+ sharedLibExtension ~= '.o' ifTrue:[
+ ok := self fileInClass:aClassName fromObject:(libName, '.o')
+ ]
+ ].
+ ].
+
+ "
+ then, look for a shared binary in binary/xxx.o
+ "
+ ok ifFalse:[
+ (ok := self fileInClass:aClassName fromObject:(shortName, sharedLibExtension))
+ ifFalse:[
+ sharedLibExtension ~= '.o' ifTrue:[
+ ok := self fileInClass:aClassName fromObject:(shortName, '.o')
+ ].
+ ok ifFalse:[
+ shortName ~= aClassName ifTrue:[
+ (ok := self fileInClass:aClassName fromObject:(aClassName, sharedLibExtension))
+ ifFalse:[
+ sharedLibExtension ~= '.o' ifTrue:[
+ ok := self fileInClass:aClassName fromObject:(aClassName, '.o')
+ ]
+ ]
+ ].
+ ].
+ ].
+ ].
+ ].
+
+ "
+ if that did not work, look for a compiled-bytecode file ...
+ "
+ ok ifFalse:[
+ (ok := self fileIn:(shortName , '.cls') lazy:loadLazy silent:beSilent)
+ ifFalse:[
+ shortName ~= aClassName ifTrue:[
+ ok := self fileIn:(aClassName , '.cls') lazy:loadLazy silent:beSilent
+ ]
+ ]
+ ].
+
+ "
+ if that did not work, look for an st-source file ...
+ "
+ ok ifFalse:[
+ (ok := self fileIn:(shortName , '.st') lazy:loadLazy silent:beSilent)
+ ifFalse:[
+ shortName ~= aClassName ifTrue:[
+ ok := self fileIn:(aClassName , '.st') lazy:loadLazy silent:beSilent
+ ].
+ ok ifFalse:[
+ "
+ ... and in the standard source-directory
+ "
+ (ok := self fileIn:('source/' , shortName , '.st') lazy:loadLazy silent:beSilent)
+ ifFalse:[
+ shortName ~= aClassName ifTrue:[
+ ok := self fileIn:('source/' , aClassName , '.st') lazy:loadLazy silent:beSilent
+ ]
+ ]
+ ]
+ ].
+ ok ifFalse:[
+ "
+ new: if there is a sourceCodeManager, ask it for the classes sourceCode
+ "
+ (mgr := Smalltalk at:#SourceCodeManager) notNil ifTrue:[
+ inStream := mgr mostRecentSourceStreamForClassNamed:aClassName.
+ inStream notNil ifTrue:[
+ ok := self fileInStream:inStream lazy:loadLazy silent:beSilent logged:false addPath:nil.
+ ]
+ ].
+ ].
+ ].
+ ].
+ ]
+ ].
+ ok ifTrue:[
+ newClass := self at:(aClassName asSymbol).
+ newClass notNil ifTrue:[
+ doInit ifTrue:[
+ newClass initialize
+ ]
+ ]
+ ].
] valueNowOrOnUnwindDo:[
- Compiler compileLazy:wasLazy.
- wasSilent notNil ifTrue:[
- self silentLoading:wasSilent
- ]
+ Compiler compileLazy:wasLazy.
+ wasSilent notNil ifTrue:[
+ self silentLoading:wasSilent
+ ]
].
^ newClass
- "Modified: 6.11.1995 / 15:36:02 / cg"
+ "Modified: 22.7.1996 / 11:10:49 / cg"
!
fileInClassLibrary:aClassLibraryName
@@ -3190,5 +3190,5 @@
!Smalltalk class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libbasic/Smalltalk.st,v 1.164 1996-07-19 09:26:38 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libbasic/Smalltalk.st,v 1.165 1996-07-22 09:12:10 cg Exp $'
! !