>From 879c8e7d0b48201a5b5662bf280b3b621a97e1a9 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Sat, 24 Apr 2010 13:09:09 +0800 Subject: [PATCH 1/5] Indicate which package file was loaded for the package name. This can be extremely helpful when trying to figure out if the changed code of a package was ran or the initial one. 2010-04-24 Holger Hans Peter Freyther * kernel/PkgLoader.st: Print the file name of the package that will be loaded. Add Package>>describe and StarPackage>>describe to describe the origin. --- ChangeLog | 6 ++++++ kernel/PkgLoader.st | 13 ++++++++++++- 2 files changed, 18 insertions(+), 1 deletions(-) diff --git a/ChangeLog b/ChangeLog index f4aed11..d2701a0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2010-04-24 Holger Hans Peter Freyther + + * kernel/PkgLoader.st: Print the file name of the package that will + be loaded. Add Package>>describe and StarPackage>>describe to + describe the origin. + 2010-04-15 Paolo Bonzini * kernel/Regex.st: Fix printing a MatchingRegexResults. diff --git a/kernel/PkgLoader.st b/kernel/PkgLoader.st index 840890f..e0e24d5 100644 --- a/kernel/PkgLoader.st +++ b/kernel/PkgLoader.st @@ -1094,6 +1094,11 @@ PackageInfo subclass: StarPackage [ loadedPackage := package. ^loadedPackage ] + + describe [ + + ^self name, ' from ', self fileName + ] ] ] @@ -1602,6 +1607,11 @@ XML.'> [self error: 'error in packages file: unmatched start tags' , stack asArray printString]] ] + + describe [ + + ^self name + ] ] @@ -1865,7 +1875,8 @@ into a Smalltalk image, correctly handling dependencies.'> OutputVerbosity > 0 ifTrue: [Transcript - nextPutAll: 'Loading package ' , each; + nextPutAll: 'Loading package ' , + (self packageAt: each) describe; nl]. (self packageAt: each) primFileIn] ] -- 1.7.0.1