gecko-dev/python
Mike Hommey 934828f009 Bug 1434765 - Properly reject invalid variables in #if{,n}def. r=froydnj,nalexander
The invalid variable test for #if{,n}def was only checking that the
first character in the variable was alphanumeric or underscore, not
the other characters.

More generally, preprocessor instructions were also cut out such that
whitespaces before and after arguments were part of the arguments.
Subtly, some legitimate strings end with what, in ISO-8859-1, is
considered as whitespaces, and because the preprocessor largely works
on byte strings (str), and because the regexps are using re.U, those
characters (e.g. 0xa0) that can legitimately appear in byte strings of
UTF-8 encoding, are treated as whitespaces. So we remove the re.U from
the instruction regexp, so that only plain ascii whitespaces only are
stripped out.

There's one place in layout/tools/reftest/manifest.jsm that was using
a broken pattern, making the test never true, which, once fixed, unveils
broken tests, so the branch that was never used is removed.

--HG--
extra : rebase_source : b695dec025c55aee0e50f2a0047278fe9c849c9e
2018-02-01 10:40:59 +09:00
..
devtools/migrate-l10n Bug 1346025 - Move vendored python modules from /python to /third_party/python, r=ted 2017-05-25 11:48:03 -04:00
l10n/fluent_migrations Bug 1411012 - Migrate a small chunk of Privacy pane in Preferences to Fluent. r=mshal,Pike 2017-11-09 12:11:32 -08:00
mach Bug 1434430 - [flake8] Fix blank 'except' statements r=rwood 2018-01-31 14:32:08 -05:00
mozboot Bug 1412006 - part 2 - add an --ndk-only option to mozboot/android.py; r=nalexander 2018-02-01 09:59:23 -05:00
mozbuild Bug 1434765 - Properly reject invalid variables in #if{,n}def. r=froydnj,nalexander 2018-02-01 10:40:59 +09:00
mozlint Bug 1429457 - [mozlint] Create formal 'setup' mechanism for bootstrapping lint dependencies, r=gbrown 2018-01-25 13:40:02 -05:00
mozterm Bug 1434430 - [flake8] Fix blank 'except' statements r=rwood 2018-01-31 14:32:08 -05:00
mozversioncontrol Bug 1405588 - [mozversioncontrol] Use base_ref instead of upstream as default outgoing comparison on git, r=gps 2017-11-01 12:57:03 -04:00
README Bug 1346025 - Move vendored python modules from /python to /third_party/python, r=ted 2017-05-25 11:48:03 -04:00
mach_commands.py Bug 1403012 - Fix TypeError when running python unittests via |mach test|, r=gbrown 2018-01-12 11:22:58 -05:00
moz.build Bug 1433974 - Update BUG_COMPONENT for some of the new Testing components, r=jmaher 2018-01-29 12:57:54 -05:00

README

This directory contains common Python code.

The basic rule is that if Python code is cross-module (that's "module" in the
Mozilla meaning - as in "module ownership") and is MPL-compatible, it should
go here.

What should not go here:

* Vendored python modules (use third_party/python instead)
* Python that is not MPL-compatible (see other-licenses/)
* Python that has good reason to remain close to its "owning" (Mozilla)
  module (e.g. it is only being consumed from there).

Historical information can be found at
https://bugzilla.mozilla.org/show_bug.cgi?id=775243
https://bugzilla.mozilla.org/show_bug.cgi?id=1346025