aboutsummaryrefslogtreecommitdiff
path: root/build2/functions-name.cxx
blob: 1bdff119a802b4ced10a2f317641e999aa7a0ead (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
// file      : build2/functions-name.cxx -*- C++ -*-
// copyright : Copyright (c) 2014-2018 Code Synthesis Ltd
// license   : MIT; see accompanying LICENSE file

#include <build2/function.hxx>
#include <build2/variable.hxx>

using namespace std;

namespace build2
{
  void
  name_functions ()
  {
    // function_family f ("name");

    // Name-specific overloads from builtins.
    //
    function_family b ("builtin");

    b[".concat"] = [](dir_path d, name n)
    {
      d /= n.dir;
      n.dir = move (d);
      return n;
    };
  }
}