~ chicken-core (chicken-5) 2a153704899637e554b787bada3be182c01ba0e8


commit 2a153704899637e554b787bada3be182c01ba0e8
Author:     felix <felix@call-with-current-continuation.org>
AuthorDate: Sat Apr 9 14:31:55 2011 +0200
Commit:     felix <felix@call-with-current-continuation.org>
CommitDate: Sat Apr 9 14:31:55 2011 +0200

    -debug ? shows debugging options; removed them from manual

diff --git a/batch-driver.scm b/batch-driver.scm
index 37f70793..639ff2eb 100644
--- a/batch-driver.scm
+++ b/batch-driver.scm
@@ -178,6 +178,9 @@
 	 (map (lambda (c) (string->symbol (string c)))
 	      (string->list do) ) )
        (collect-options 'debug) ) )
+    (when (memq '? debugging-chicken)
+      (print-debug-options)
+      (exit))
     (set! dumpnodes (memq '|D| debugging-chicken))
     (set! import-libraries
       (map (lambda (il)
diff --git a/manual/Using the compiler b/manual/Using the compiler
index 1291989d..8009358f 100644
--- a/manual/Using the compiler	
+++ b/manual/Using the compiler	
@@ -32,37 +32,7 @@ the source text should be read from standard input.
 
 ; -consult-inline-file FILENAME : load file with definitions for cross-module inlining generated by a previous compiloer invocation via {{-emit-inline-file}}. Implies {{-inline}}.
 
-; -debug MODES : Enables one or more compiler debugging modes. {{MODES}} is a string of characters that select debugging information about the compiler that will be printed to standard output.
-
-     t          show time needed for compilation
-     b          show breakdown of time needed for each compiler pass
-     o          show performed optimizations
-     r          show invocation parameters
-     s          show program-size information and other statistics
-     a          show node-matching during simplification
-     p          show execution of compiler sub-passes
-     m          show GC statistics during compilation
-     n          print the line-number database 
-     c          print every expression before macro-expansion
-     u          lists all unassigned global variable references
-     d          lists all assigned global variables
-     x          display information about experimental features
-     D          when printing nodes, use node-tree output
-     N          show the real-name mapping table
-     S          show applications of compiler syntax
-     T          show expressions after converting to node tree
-     P          show expressions after specialization
-     U          show expressions after unboxing
-     M          show syntax-/runtime-requirements
-     1          show source expressions
-     2          show canonicalized expressions
-     3          show expressions converted into CPS
-     4          show database after each analysis pass
-     5          show expressions after each optimization pass
-     6          show expressions after each inlining pass
-     7          show expressions after complete optimization
-     8          show database after final analysis
-     9          show expressions after closure conversion
+; -debug MODES : Enables one or more compiler debugging modes. {{MODES}} is a string of characters that select debugging information about the compiler that will be printed to standard output. Use {{-debug ?}} to see a list of available debugging options.
 
 ; -debug-level LEVEL : Selects amount of debug-information. {{LEVEL}} should be an integer.
 
diff --git a/support.scm b/support.scm
index d3d8e2f3..d2c11dd5 100644
--- a/support.scm
+++ b/support.scm
@@ -1598,3 +1598,43 @@ Usage: chicken FILENAME OPTION ...
 
 EOF
 ) )
+
+(define (print-debug-options)
+  (display #<<EOF
+
+Available debugging options:
+
+     t          show time needed for compilation
+     b          show breakdown of time needed for each compiler pass
+     o          show performed optimizations
+     r          show invocation parameters
+     s          show program-size information and other statistics
+     a          show node-matching during simplification
+     p          show execution of compiler sub-passes
+     m          show GC statistics during compilation
+     n          print the line-number database 
+     c          print every expression before macro-expansion
+     u          lists all unassigned global variable references
+     d          lists all assigned global variables
+     x          display information about experimental features
+     D          when printing nodes, use node-tree output
+     N          show the real-name mapping table
+     S          show applications of compiler syntax
+     T          show expressions after converting to node tree
+     P          show expressions after specialization
+     U          show expressions after unboxing
+     M          show syntax-/runtime-requirements
+     1          show source expressions
+     2          show canonicalized expressions
+     3          show expressions converted into CPS
+     4          show database after each analysis pass
+     5          show expressions after each optimization pass
+     6          show expressions after each inlining pass
+     7          show expressions after complete optimization
+     8          show database after final analysis
+     9          show expressions after closure conversion
+     ?          you already figured that out
+
+
+EOF
+))
Trap