| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use: https://github.com/JelleZijlstra/autotyping
to add "safe" return annotations.
Where a parameter has a default value that is an obvious scalar type
(bool, int, str, etc.) add those annotations as well.
Also fixed two small bugs that popped up when sanity-checking with
mypy. One in FortranCommon, where a return had been previously
annotated to be a tuple of Action, which should be ActionBase -
Action is the factory function, not the base class. The other was
a typo in the error raised in _add_cppdefines - the message was
formatted with the value of "define" which should have been "defines".
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added another try block so complete prepend e2e test can be run
on a branch where PR #4263 is not applied (for comparison).
Added license header.
Changed invalid-tuple unittest to use assertRaises (behavior
is the same)
Also added a versionadded and a versionchanged to docstrings.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
| |
negative test for non-two-tuple. Minor wording change
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After the previous proposals, addition of a bare tuple is restored
to the valued-macro behavior (this previously did not work
consistently). Strings are now consistently split if they contain
spaces, except if entered as a list member, in which case (as
documented) they are left alone. tuples with nore than two members
are now flagged as a UserError; previously the first two members were
taken as name=value and any further members were silently ignored.
More tests added.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
| |
A few places were deciding what to do based on result of is_List, when the
intent was really list-or-tuple-or-derivatives - changed to is_Sequence.
Added some test cases, including a unit test for processDefines
(which would have caught one of these cases).
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
| |
expanding among other things CPPDEFINES). source and target arguements were previously added to allow those values to be used by alternative definitions for _defines. This broke previous usage, including scons-contribs qt4 and qt5 tools. (See https://github.com/SCons/scons-contrib/issues/45 )
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Removed a number of imports reported as unused.
* Reorganize imports in a few places.
* Checker reported warnings problems ("Instantiating an exception,
but not raising it, has no effect"): serveral tool modules instantiated
a warning class thinking (?) it would issue the warning; changed these to
the standard use - calling the warn() function with the warnclass as an arg.
* Tool modules that were touched had the copyright header munging applied.
* Removed irritating "####" lines from gettext and msgfmt tools.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Usually, it's unit tests that do this, and it's not really crucial
to kill those off, but checkers do complain, including sider if you
touch anything in one of those files.
In SCons/Environment,py, removed all SCons.Util prefixes, than turned the
import of Util into a star import, running a tool on that then changes
it to import only the used symbols from Util. Since there are lots,
that ought to be a small performance win, since it doesn't have to do
namespace lookups on SCons.Util.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Touches the first and second levels of SCons (except SCons.Tool),
not tests or docs which remain TODO.
Make sure docstring is first non-comment content, eliminate cases where
docstring is set elsewhere but assigns to __doc__ - this approach of
course worked inside Python, but confuses various tools.
Some module-level docstrings modified a bit, in particular
the convention of having the name of the module as the first line
is dropped, replaced by a summary description going there instead -
this improves the look in the API Docs, which otherwise display
something like:
SCons.Foo - SCons.Foo
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
|
|
|
|
|
|
|
|
| |
Eliminate unneeded imports, and a few unneeded statements -
usually "pass" where it is not syntactically needed.
A couple of import try blocks were eliminated or changed
when they're "cannot happen" due to current floor Python version.
Signed-off-by: Mats Wichmann <mats@linux.com>
|
|
with current python packaging practices
|