new: Warn about unused method vars
authorStefan Vogel <sv@exept.de>
Tue, 24 Jul 2001 10:13:08 +0200
changeset 3054 43a0f825bdb0
parent 3053 593d27ab513b
child 3055 a84f555bb673
new: Warn about unused method vars
AbstractLauncherApplication.st
--- a/AbstractLauncherApplication.st	Tue Jul 24 09:53:48 2001 +0200
+++ b/AbstractLauncherApplication.st	Tue Jul 24 10:13:08 2001 +0200
@@ -2009,11 +2009,11 @@
 compilerSettingsFor:requestor
     "open a dialog on compiler related settings"
 
-    |box warnings warnSTX warnUnderscore warnDollar warnOldStyle 
+    |box warnings warnSTX warnUnderscore warnDollar warnOldStyle warnUnusedVars
      allowDollar allowUnderscore allowSqueakExtensions allowQualifiedNames
      immutableArrays
      warnSTXBox warnUnderscoreBox warnOldStyleBox warnCommonMistakes warnCommonMistakesBox
-     warnCompatibility warnCompatibilityBox warnDollarBox
+     warnCompatibility warnCompatibilityBox warnDollarBox warnUnusedVarsBox
      stcCompilation compilationList stcCompilationOptions 
      historyLines fullHistoryUpdate 
      catchMethodRedefs catchClassRedefs keepSourceOptions keepSource  
@@ -2037,6 +2037,7 @@
     warnOldStyle := Compiler warnOldStyleAssignment asValue.
     warnCommonMistakes := Compiler warnCommonMistakes asValue.
     warnCompatibility := Compiler warnPossibleIncompatibilities asValue.
+    warnUnusedVars := Compiler warnUnusedVars asValue.
     allowUnderscore := Compiler allowUnderscoreInIdentifier asValue.
     allowDollar := Compiler allowDollarInIdentifier asValue.
     allowSqueakExtensions := Compiler allowSqueakExtensions asValue.
@@ -2092,6 +2093,7 @@
                 warnOldStyleBox enable.
                 warnCommonMistakesBox enable.
                 warnCompatibilityBox enable.
+                warnUnusedVarsBox enable.
                 allowUnderscore value ifTrue:[
                     warnUnderscoreBox enable.
                 ] ifFalse:[
@@ -2109,6 +2111,7 @@
                 warnOldStyleBox disable.
                 warnCommonMistakesBox disable.
                 warnCompatibilityBox disable.
+                warnUnusedVarsBox disable.
               ]].
 
     warnings onChangeEvaluate:warnEnabler.
@@ -2229,6 +2232,9 @@
     warnDollarBox := box addCheckBox:(resources string:'dollars in identifiers') on:warnDollar.
     warnDollarBox width:0.4.
 
+    warnUnusedVarsBox := box addCheckBox:(resources string:'unused method vars') on:warnUnusedVars.
+    warnUnusedVarsBox width:0.4.
+
     yMax := box yPosition.
 
     box yPosition:y.
@@ -2272,6 +2278,7 @@
         Compiler warnDollarInIdentifier:warnDollar value.
         Compiler warnCommonMistakes:warnCommonMistakes value.
         Compiler warnPossibleIncompatibilities:warnCompatibility value.
+        Compiler warnUnusedVars:warnUnusedVars value.
         Compiler allowUnderscoreInIdentifier:allowUnderscore value.
         Compiler allowDollarInIdentifier:allowDollar value.
         Compiler allowSqueakExtensions:allowSqueakExtensions value.
@@ -6426,5 +6433,5 @@
 !AbstractLauncherApplication class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libtool/AbstractLauncherApplication.st,v 1.150 2001-06-22 16:38:35 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libtool/AbstractLauncherApplication.st,v 1.151 2001-07-24 08:13:08 stefan Exp $'
 ! !