aboutsummaryrefslogtreecommitdiff
path: root/build2/function.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2018-07-14 18:30:28 +0200
committerKaren Arutyunov <karen@codesynthesis.com>2018-07-16 16:49:58 +0300
commit55e858010b9ba53c27475d9ce6f864a84d28fa81 (patch)
treeddbbcc909abc23310117afee2225f6197f475f18 /build2/function.hxx
parent3f2b42c3c01ecfee6a63653172d437aa0e915b68 (diff)
Resolve function overload via the argument reversal to untyped
Diffstat (limited to 'build2/function.hxx')
-rw-r--r--build2/function.hxx9
1 files changed, 6 insertions, 3 deletions
diff --git a/build2/function.hxx b/build2/function.hxx
index 62666cc..139f1fa 100644
--- a/build2/function.hxx
+++ b/build2/function.hxx
@@ -45,9 +45,6 @@ namespace build2
// expected to issue diagnostics and throw failed. Note that the arguments
// are conceptually "moved" and can be reused by the implementation.
//
- // @@ Maybe it makes sense to implicitly convert types like string to names
- // -- providing all the overload combinations really gets tedious.
- //
// A function can also optionally receive the current scope by having the
// first argument of the const scope* type. It may be NULL is the function
// is called out of any scope (e.g., command line).
@@ -72,6 +69,12 @@ namespace build2
// For more examples/ideas, study the existing function families (reside
// in the functions-*.cxx files).
//
+ // Note that normally there will be a function overload that has all the
+ // parameters untyped with an implementation that falls back to one of the
+ // overloads that have all the parameters typed, possibly inferring the type
+ // from the argument value "syntax" (e.g., presence of a trailing slash for
+ // a directory path).
+ //
struct function_overload;
using function_impl = value (const scope*,