1.1 --- a/simplify.py Thu Feb 15 20:32:37 2007 +0100
1.2 +++ b/simplify.py Fri Feb 16 00:13:09 2007 +0100
1.3 @@ -838,10 +838,12 @@
1.4 (dstar)
1.5 """
1.6
1.7 - # NOTE: Making the actual subprogram defining, too.
1.8 + subprogram = Subprogram(function, name=function.name, module=self.module, structures=self.current_structures[:],
1.9 + internal=0, returns_value=1, star=None, dstar=None, is_method=self.within_class, original_def=function)
1.10
1.11 - subprogram = Subprogram(function, 1, name=function.name, module=self.module, structures=self.current_structures[:],
1.12 - internal=0, returns_value=1, star=None, dstar=None, is_method=self.within_class, original_def=function)
1.13 + # Make nice annotations for the viewer.
1.14 +
1.15 + function._subprogram = subprogram
1.16
1.17 self.current_subprograms.append(subprogram)
1.18 within_class = self.within_class
1.19 @@ -952,9 +954,15 @@
1.20
1.21 # Make a subprogram for the function and record it outside the main
1.22 # tree.
1.23 - # NOTE: Making the actual subprogram defining, too.
1.24 +
1.25 + subprogram = Subprogram(lambda_, name=None, module=self.module, internal=0, returns_value=1, star=None, dstar=None, original_def=lambda_)
1.26 +
1.27 + # Make nice annotations for the viewer.
1.28
1.29 - subprogram = Subprogram(lambda_, 1, name=None, module=self.module, internal=0, returns_value=1, star=None, dstar=None, original_def=lambda_)
1.30 + function._subprogram = subprogram
1.31 +
1.32 + # Process the lambda contents.
1.33 +
1.34 self.current_subprograms.append(subprogram)
1.35 subprogram.code = [ReturnFromFunction(expr=self.dispatch(lambda_.code))]
1.36 self.current_subprograms.pop()