Fix --optimizer-options=-optimize still applying some optimizations.

This option normally takes effect through the base class in lsloptimize.py, which doesn't call the optimization techniques if deactivated. However, lsloutput.py is not called by it, and it applied some optimizations on its own.

Fixed on the reading of the optimization options, by filtering them by whether the optimize option is active.
This commit is contained in:
Sei Lisa 2016-11-29 23:03:14 +01:00
parent 899b550133
commit 397dc896fb

View file

@ -437,9 +437,12 @@ class outscript(object):
self.tree, self.symtab = treesymtab
# Grab options
self.optsigns = 'optsigns' in options
self.optfloats = 'optfloats' in options
self.foldconst = 'constfold' in options
self.optimize = 'optimize' in options
# These are optimization options that depend on the above:
self.optsigns = self.optimize and 'optsigns' in options
self.optfloats = self.optimize and 'optfloats' in options
self.foldconst = self.optimize and 'constfold' in options
self.warntabs = 'warntabs' in options
ret = ''