aboutsummaryrefslogtreecommitdiff
path: root/nix/boost/format/internals_fwd.hpp
blob: a8ebf7c3abc105fb99b3d629ec79ca7216a1a208 (about) (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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
// -*- C++ -*-
//  Boost general library 'format'   ---------------------------
//  See http://www.boost.org for updates, documentation, and revision history.

//  (C) Samuel Krempp 2001
//                  krempp@crans.ens-cachan.fr
//  Permission to copy, use, modify, sell and
//  distribute this software is granted provided this copyright notice appears
//  in all copies. This software is provided "as is" without express or implied
//  warranty, and with no claim as to its suitability for any purpose.

// ideas taken from Rüdiger Loos's format class
// and Karl Nelson's ofstream (also took its parsing code as basis for printf parsing)

// ------------------------------------------------------------------------------
// internals_fwd.hpp :  forward declarations, for internal headers
// ------------------------------------------------------------------------------

#ifndef BOOST_FORMAT_INTERNAL_FWD_HPP
#define BOOST_FORMAT_INTERNAL_FWD_HPP

#include "boost/format/format_fwd.hpp"


namespace boost {
namespace io {

namespace detail {
  struct stream_format_state;
  struct format_item;
}


namespace detail {

  // these functions were intended as methods, 
  // but MSVC have problems with template member functions :

  // defined in format_implementation.hpp :
     template<class T> 
     basic_format&  modify_item_body( basic_format& self, 
                                          int itemN, const T& manipulator);

     template<class T> 
     basic_format&  bind_arg_body( basic_format& self,
                                           int argN, const T& val);

    template<class T> 
    void apply_manip_body( stream_format_state& self,
                           T manipulator);

  // argument feeding (defined in feed_args.hpp ) :
     template<class T> 
     void distribute(basic_format& self, T x);

     template<class T> 
     basic_format& feed(basic_format& self, T x);
 
} // namespace detail

} // namespace io
} // namespace boost


#endif //  BOOST_FORMAT_INTERNAL_FWD_HPP
--expose="$PWD=$HOME/sample" -- \ rm -v '$HOME/sample/home.scm' && false else echo "'guix home container' test SKIPPED" >&2 fi HOME="$test_directory" export HOME # # Test 'guix home reconfigure'. # echo "# This file will be overridden and backed up." > "$HOME/.bashrc" mkdir "$HOME/.config" echo "This file will be overridden too." > "$HOME/.config/test.conf" echo "This file will stay around." > "$HOME/.config/random-file" guix home reconfigure "${test_directory}/home.scm" test -d "${HOME}/.guix-home" test -h "${HOME}/.bash_profile" test -h "${HOME}/.bashrc" grep 'alias run="guix shell"' "$HOME/.bashrc" grep "alias path='echo \$PATH'" "$HOME/.bashrc" test "$(tail -n 2 "${HOME}/.bashrc")" == "\ # dot-bashrc test file for guix home # the content of bashrc-test-config.sh" grep -q "the content of ~/.config/test.conf" "${HOME}/.config/test.conf" grep '^export PS1="\$GUIX_ENVIRONMENT λ "$' "${HOME}/.bash_profile" ( . "${HOME}/.guix-home/setup-environment"; test "$TODAY" = "26 messidor" ) ( . "${HOME}/.guix-home/setup-environment"; test "$LITERAL" = '${abc}' ) ( . "${HOME}/.guix-home/setup-environment"; test "$STRING_WITH_ESCAPES" = "chars: \" /\\") ( . "${HOME}/.guix-home/setup-environment"; echo "$SHELL" | grep "/gnu/store/.*/bin/bash" ) # This one should still be here. grep "stay around" "$HOME/.config/random-file" # Make sure preexisting files were backed up. grep "overridden" "$HOME"/*guix-home*backup/.bashrc grep "overridden" "$HOME"/*guix-home*backup/.config/test.conf rm -r "$HOME"/*guix-home*backup # # Test 'guix home describe'. # configuration_file() { guix home describe \ | grep 'configuration file:' \ | cut -d : -f 2 \ | xargs echo } test "$(cat "$(configuration_file)")" == "$(cat home.scm)" canonical_file_name() { guix home describe \ | grep 'canonical file name:' \ | cut -d : -f 2 \ | xargs echo } test "$(canonical_file_name)" == "$(readlink "${HOME}/.guix-home")" # # Configure a new generation. # # Change the bashrc snippet content and comment out one service. sed -i "home.scm" -e's/the content of/the NEW content of/g' sed -i "home.scm" -e"s/(simple-service 'test-config/#;(simple-service 'test-config/g" guix home reconfigure "${test_directory}/home.scm" test "$(tail -n 2 "${HOME}/.bashrc")" == "\ # dot-bashrc test file for guix home # the NEW content of bashrc-test-config.sh" # This file must have been removed and not backed up. test ! -e "$HOME/.config/test.conf" test ! -e "$HOME"/*guix-home*backup/.config/test.conf test "$(cat "$(configuration_file)")" == "$(cat home.scm)" test "$(canonical_file_name)" == "$(readlink "${HOME}/.guix-home")" test $(guix home list-generations | grep "^Generation" | wc -l) -eq 2 # # Test 'guix home search'. # guix home search mcron | grep "^name: home-mcron" guix home search scheduling daemon | grep "^name: home-mcron" )