Bug 1256573 - Add missing primitives to the ConfigureSandbox documentation. r=nalexander
authorMike Hommey <mh+mozilla@glandium.org>
Sun, 27 Mar 2016 09:40:50 +0900
changeset 290989 f01a178847233cf15e9cddaaa97a5db6fc371cc0
parent 290988 178b2c7228b6527ce26c306c07dde4ed538215b6
child 290990 96ef4c62378d5ddabb8c27c745bc928517273c20
push id19656
push usergwagner@mozilla.com
push dateMon, 04 Apr 2016 13:43:23 +0000
treeherderb2g-inbound@e99061fde28a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersnalexander
bugs1256573
milestone48.0a1
Bug 1256573 - Add missing primitives to the ConfigureSandbox documentation. r=nalexander Not directly related, but since this bug is about to add another primitive...
python/mozbuild/mozbuild/configure/__init__.py
--- a/python/mozbuild/mozbuild/configure/__init__.py
+++ b/python/mozbuild/mozbuild/configure/__init__.py
@@ -52,25 +52,28 @@ def forbidden_import(*args, **kwargs):
     raise ImportError('Importing modules is forbidden')
 
 
 class ConfigureSandbox(dict):
     """Represents a sandbox for executing Python code for build configuration.
     This is a different kind of sandboxing than the one used for moz.build
     processing.
 
-    The sandbox has 5 primitives:
+    The sandbox has 8 primitives:
     - option
     - depends
     - template
     - advanced
     - include
+    - set_config
+    - set_define
+    - imply_option
 
-    `option` and `include` are functions. `depends`, `template` and `advanced`
-    are decorators.
+    `option`, `include`, `set_config`, `set_define` and `imply_option` are
+    functions. `depends`, `template` and `advanced` are decorators.
 
     These primitives are declared as name_impl methods to this class and
     the mapping name -> name_impl is done automatically in __getitem__.
 
     Additional primitives should be frowned upon to keep the sandbox itself as
     simple as possible. Instead, helpers should be created within the sandbox
     with the existing primitives.