mirror of
https://github.com/boostorg/quickbook.git
synced 2026-01-30 08:02:38 +00:00
Avoid 'using namespace' as it confuses me.
[SVN r59287]
This commit is contained in:
@@ -24,7 +24,7 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace ph = boost::phoenix;
|
||||
|
||||
template <typename Iterator, typename Actions, bool skip_initial_spaces>
|
||||
|
||||
@@ -1224,9 +1224,8 @@ namespace quickbook
|
||||
if (err != 0)
|
||||
return err; // return early on error
|
||||
|
||||
typedef classic::position_iterator<std::string::const_iterator> iterator_type;
|
||||
iterator_type first(code.begin(), code.end(), file);
|
||||
iterator_type last(code.end(), code.end());
|
||||
iterator first(code.begin(), code.end(), file);
|
||||
iterator last(code.end(), code.end());
|
||||
|
||||
size_t fname_len = file.size();
|
||||
bool is_python = fname_len >= 3
|
||||
|
||||
@@ -32,13 +32,16 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace fs = boost::filesystem;
|
||||
using boost::spirit::unused_type;
|
||||
|
||||
// TODO: This is defined in two places.
|
||||
typedef qi::symbols<char, std::string> string_symbols;
|
||||
// TODO: This is defined in two places.
|
||||
typedef qi::symbols<char, std::string> string_symbols;
|
||||
|
||||
typedef classic::position_iterator<std::string::const_iterator> iterator;
|
||||
typedef boost::spirit::classic::position_iterator<
|
||||
std::string::const_iterator> iterator;
|
||||
typedef boost::spirit::classic::file_position file_position;
|
||||
typedef boost::iterator_range<iterator> iterator_range;
|
||||
typedef qi::symbols<char, std::string> string_symbols;
|
||||
typedef std::map<std::string, std::string> attribute_map;
|
||||
@@ -584,8 +587,8 @@ namespace quickbook
|
||||
table_action(quickbook::actions& actions)
|
||||
: actions(actions) {}
|
||||
|
||||
template <typename Arg1, typename Arg2>
|
||||
struct result { typedef void type; };
|
||||
template <typename Arg1, typename Arg2>
|
||||
struct result { typedef void type; };
|
||||
|
||||
void operator()(boost::optional<std::string> const&, std::string const&) const;
|
||||
|
||||
@@ -648,8 +651,8 @@ namespace quickbook
|
||||
, section_level(section_level)
|
||||
, qualified_section_id(qualified_section_id) {}
|
||||
|
||||
template <typename A1, typename A2>
|
||||
struct result { typedef void type; };
|
||||
template <typename A1, typename A2>
|
||||
struct result { typedef void type; };
|
||||
|
||||
void operator()(boost::optional<std::string> const&, iterator_range) const;
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace fs = boost::filesystem;
|
||||
|
||||
struct actions
|
||||
|
||||
@@ -20,10 +20,8 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace ph = boost::phoenix;
|
||||
using namespace ph::arg_names;
|
||||
using ph::bind;
|
||||
typedef std::string::const_iterator iter_type;
|
||||
|
||||
struct printer
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace fs = boost::filesystem;
|
||||
tm* current_time; // the current time
|
||||
tm* current_gm_time; // the current UTC time
|
||||
@@ -58,10 +58,9 @@ namespace quickbook
|
||||
return err;
|
||||
}
|
||||
|
||||
typedef classic::position_iterator<std::string::const_iterator> iterator_type;
|
||||
iterator_type first(storage.begin(), storage.end(), filein_);
|
||||
iterator_type last(storage.end(), storage.end());
|
||||
iterator_type start = first;
|
||||
iterator first(storage.begin(), storage.end(), filein_);
|
||||
iterator last(storage.end(), storage.end());
|
||||
iterator start = first;
|
||||
|
||||
doc_info_grammar<iterator, actions> l(actor);
|
||||
bool success = parse(first, last, l);
|
||||
@@ -80,14 +79,14 @@ namespace quickbook
|
||||
}
|
||||
}
|
||||
else {
|
||||
classic::file_position const pos = first.get_position();
|
||||
file_position const pos = first.get_position();
|
||||
detail::outerr(pos.file,pos.line)
|
||||
<< "Doc Info error near column " << pos.column << ".\n";
|
||||
}
|
||||
|
||||
if (!success || first != last)
|
||||
{
|
||||
classic::file_position const pos = first.get_position();
|
||||
file_position const pos = first.get_position();
|
||||
detail::outerr(pos.file,pos.line)
|
||||
<< "Syntax Error near column " << pos.column << ".\n";
|
||||
++actor.error_count;
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace ph = boost::phoenix;
|
||||
|
||||
template <typename Iterator, typename Actions>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
|
||||
template <typename Iterator, typename Actions>
|
||||
struct phrase_grammar : qi::grammar<Iterator>
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
namespace ph = boost::phoenix;
|
||||
|
||||
template <typename Rule, typename Action>
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
|
||||
namespace quickbook
|
||||
{
|
||||
using namespace boost::spirit;
|
||||
namespace qi = boost::spirit::qi;
|
||||
using boost::spirit::unused_type;
|
||||
|
||||
template <class Iterator, class EscapeActions>
|
||||
struct parse_escaped_impl
|
||||
|
||||
Reference in New Issue
Block a user