aboutsummaryrefslogtreecommitdiff
path: root/nix/boost/format/exceptions.hpp
blob: 80da6d57189a1d9b2881e8cb06b9f49214fd7bac (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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
// -*- 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)

// ------------------------------------------------------------------------------
// exceptions.hpp 
// ------------------------------------------------------------------------------


#ifndef BOOST_FORMAT_EXCEPTIONS_HPP
#define BOOST_FORMAT_EXCEPTIONS_HPP


#include <stdexcept>


namespace boost {

namespace io {

// **** exceptions -----------------------------------------------

class format_error : public std::exception
{
public:
  format_error() {}
  virtual const char *what() const throw()
  {
    return "boost::format_error: "
      "format generic failure";
  }
};

class bad_format_string : public format_error
{
public:
  bad_format_string() {}
  virtual const char *what() const throw()
  {
    return "boost::bad_format_string: "
      "format-string is ill-formed";
  }
};

class too_few_args : public format_error
{
public:
  too_few_args() {}
  virtual const char *what() const throw()
  {
    return "boost::too_few_args: "
      "format-string referred to more arguments than were passed";
  }
};

class too_many_args : public format_error
{
public:
  too_many_args() {}
  virtual const char *what() const throw()
  {
    return "boost::too_many_args: "
      "format-string referred to less arguments than were passed";
  }
};


class  out_of_range : public format_error
{
public:
  out_of_range() {}
  virtual const char *what() const throw()
  {
    return "boost::out_of_range: "
      "tried to refer to an argument (or item) number which is out of range, "
      "according to the format string.";
  }
};


} // namespace io

} // namespace boost


#endif // BOOST_FORMAT_EXCEPTIONS_HPP
ILE_NAME>: Resolve its absolute path via the 'realpath' command. Maxim Cournoyer 2021-04-24guix-install.sh: Allow overriding the Guix binary source....This is useful for example for testing release candidates not yet uploaded to the FTP, or for testing manually downloaded images from the CI. * etc/guix-install.sh (main)[GUIX_BINARY_FILE_NAME]: When this variable is defined, use it as the file name of a Guix binary, instead of automatically retrieving the latest archive from the FTP. Maxim Cournoyer 2021-04-14guix-install.sh: Add the build users to the 'kvm' group....Fixes <https://bugs.gnu.org/42129>. * etc/guix-install.sh (sys_create_build_user): If a 'kvm' group exists, add it to the guixbuilders' lists of supplementary groups. Leo Famulari 2021-03-23Add powerpc64le-linux as a supported Guix architecture....This makes powerpc64le-linux a supported architecture for Guix, but not for Guix System. * Makefile.am (SUPPORTED_SYSTEMS): Add an entry for powerpc64le-linux. * etc/guix-install.sh (chk_sys_arch): Same. * guix/packages.scm (%supported-systems): Same. * m4/guix.m4 (GUIX_ASSERT_SUPPORTED_SYSTEM): Same. * tests/guix-build.sh (all_systems): Same. Chris Marusich 2021-01-03/etc/profile.d/guix.sh: Add guix pull profile even when absent...* etc/guix-install.sh (sys_create_init_profile): Set PATH and INFOPATH even when $_GUIX_PROFILE does not exist. After initial installation on a foreign distro, the guix pull profile won't be present in path. This means that the first guix pull won't take effect until the shell is restarted. ~/.guix-profile cannot be pre-loaded like this as the relevant paths are stored in ~/.guix-profile/etc/profile, which simply won't exist. However, guix package will output a relevant hint that instructs the user to reload the profile, so this isn't a problem. Jakub Kądziołka 2020-12-18guix-install.sh: Add variable quoting and curly-bracketing....* etc/guix-install.sh (guix_get_bin)[dl_path]: Add variable quoting and curly-bracketing. Signed-off-by: Christopher Baines <mail@cbaines.net> Vincent Legoll 2020-12-18guix-install.sh: Adjust variable use in guix_get_bin_list()....* etc/guix-install.sh (guix_get_bin_list)[BIN_VER]: Add curly-brackets, [latest_ver]: Likewise & add explicit array zero-indexing. Signed-off-by: Christopher Baines <mail@cbaines.net> Vincent Legoll 2020-12-18guix-install.sh: Add variable quoting in sys_make_guix_available....* etc/guix-install.sh (sys_make_guix_available): Add variable quoting. Signed-off-by: Christopher Baines <mail@cbaines.net> Vincent Legoll 2020-12-18guix-install.sh: Replace tabs with spaces....Almost the entire file is indented with spaces, a few tabs slipped in, clean them up. * etc/guix-install.sh(chk_sys_arch): Replace tabs with spaces. (sys_enable_guix_daemon): Likewise. Signed-off-by: Christopher Baines <mail@cbaines.net> Vincent Legoll 2020-11-15guix-install.sh: don't throw away release candidates when picking the latest ......* etc/guix-install.sh (guix_get_bin_list): modify regexes to allow rcN syntax Signed-off-by: Ludovic Courtès <ludo@gnu.org> Daniel Brooks 2020-10-16guix-install.sh: Check the service 'nscd' and suggest it....Fixes <https://bugs.gnu.org/43744>. * etc/guix-install.sh (chk_sys_nscd): New function to check if the service 'nscd is running, otherwise suggest to install distribution-wide. Signed-off-by: Ludovic Courtès <ludo@gnu.org> zimoun 2020-10-16guix-install.sh: Add symbolic links for supported shell completions....Fixes <https://bugs.gnu.org/43744>. * etc/guix-install.sh (sys_create_shell_completion): New function to add system wide all the symlinks for supported shell completions. Signed-off-by: Ludovic Courtès <ludo@gnu.org> zimoun 2020-09-17guix-install.sh: Support OpenRC....* etc/guix-install.sh (chk_init_sys): Detect OpenRC. (sys_enable_guix_daemon): Install & enable the Guix daemon on such systems. * etc/openrc/guix-daemon.in: New file. * nix/local.mk: Add a rule for it. (openrcservicedir, nodist_openrcservice_DATA): New variables. (CLEANFILES, EXTRA_DIST): Add them. * .gitignore: Ignore etc/openrc/guix-daemon. Signed-off-by: Tobias Geerinckx-Rice <me@tobias.gr> Morgan Smith 2020-09-17guix-install.sh: Be POSIX-compliant....* etc/guix-install.sh (guix_get_bin_list): Call grep with an extended regular expression instead of a non-POSIX Perl regular expression. (sys_create_store): Remove ‘--warning=no-timestamp’ argument to tar. Signed-off-by: Tobias Geerinckx-Rice <me@tobias.gr> Morgan Smith 2020-09-09guix-install.sh: Quote the OpenPGP key URL....Without quotes, zsh fails with "no matches found" as it tries to interpret the question mark. * etc/guix-install.sh (chk_gpg_keyring): Enclose URL in single quotes. Ludovic Courtès 2020-07-16guix-install.sh: Make sure /etc/profile is sourced....New users regularly report missing newly-installed programmes and icons. * etc/guix-install.scm (main): Tell users to log out & back in. Tobias Geerinckx-Rice 2020-07-16guix-install.sh: Suggest running gpg as root....The original example regularly prevented new users from installing Guix at all. * etc/guix-install.scm (chk_gpg_keyring): Suggest ‘sudo -i gpg’. Tobias Geerinckx-Rice 2020-07-14etc: Enable mount unit only if it exists....* etc/guix-install.sh (sys_enable_guix_daemon): Enable gnu-store.mount only if it was actually installed. Reported by peanutbutterandc on #guix. Tobias Geerinckx-Rice 2020-05-23guix-install.sh: Fix ‘systemctl not found’ error message at probe....* etc/guix-install.sh (chk_init_sys): Redirect systemctl errors to /dev/null. Signed-off-by: Tobias Geerinckx-Rice <me@tobias.gr> Vincent Legoll 2020-05-23guix-install.sh: Add xz to requirements....* etc/guix-install.sh (REQUIRE): Add xz to requirements list. Signed-off-by: Tobias Geerinckx-Rice <me@tobias.gr> Vincent Legoll 2020-05-17etc: Install mount unit only if it exists....This follows up on 1a1faa78b0498fbb71f1533beb4b65817c1d3f2a, and avoids the (non-fatal) error seen in <https://issues.guix.gnu.org/41356>. /gnu/store will remain writable on new foreign distribution installations until the next release. * etc/guix-install.sh (sys_enable_guix_daemon): Check for ‘gnu-store.mount’ presence before trying to cp it. Update forgotten copyright header. Tobias Geerinckx-Rice 2020-05-16etc: Add a systemd unit to bind-mount @storedir@ read-only....* etc/gnu-store.mount.in: New file. * nix/local.mk (nodist_systemdservice_DATA): Add it. (etc/%.mount): New rule for it. * etc/guix-install.sh (sys_enable_guix_daemon): Install it. * doc/guix.texi (Binary Installation): Document it. * .gitignore: Ignore changes to it. Tobias Geerinckx-Rice