mirror of
https://github.com/boostorg/build.git
synced 2026-02-15 13:02:11 +00:00
Documented that modules.call-in and modules.call-locally rules may forward at most 8 parameters to the rules they call. Also removed the extra unused $(9) parameter forwarding in the modules.call-locally rule.
[SVN r45304]
This commit is contained in:
@@ -63,7 +63,8 @@ rule peek ( module-name ? : variables + )
|
||||
# Call the given rule locally in the given module. Use this for rules accepting
|
||||
# rule names as arguments, so that the passed rule may be invoked in the context
|
||||
# of the rule's caller (for example, if the rule accesses module globals or is a
|
||||
# local rule).
|
||||
# local rule). Note that rules called this way may accept at most 8 parmeters.
|
||||
#
|
||||
rule call-in ( module-name ? : rule-name args * : * )
|
||||
{
|
||||
module $(module-name)
|
||||
@@ -75,14 +76,19 @@ rule call-in ( module-name ? : rule-name args * : * )
|
||||
|
||||
# Given a possibly qualified rule name and arguments, remove any initial module
|
||||
# qualification from the rule and invoke it in that module. If there is no
|
||||
# module qualification, the rule is invoked in the global module.
|
||||
# module qualification, the rule is invoked in the global module. Note that
|
||||
# rules called this way may accept at most 8 parmeters.
|
||||
#
|
||||
rule call-locally ( qualified-rule-name args * : * )
|
||||
{
|
||||
local module-rule = [ MATCH (.*)\\.(.*) : $(qualified-rule-name) ] ;
|
||||
local rule-name = $(module-rule[2]) ;
|
||||
rule-name ?= $(qualified-rule-name) ;
|
||||
return [ call-in $(module-rule[1]) : $(rule-name) $(args)
|
||||
: $(2) : $(3) : $(4) : $(5) : $(6) : $(7) : $(8) : $(9) ] ;
|
||||
# We pass only 8 parameters here since Boost Jam allows at most 9 rule
|
||||
# parameter positions and the call-in rule already uses up the initial
|
||||
# position for the module name.
|
||||
return [ call-in $(module-rule[1]) : $(rule-name) $(args) : $(2) : $(3) :
|
||||
$(4) : $(5) : $(6) : $(7) : $(8) ] ;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user