|
Boost Users : |
Subject: [Boost-users] namespace question
From: Dan (dbdavidson_at_[hidden])
Date: 2010-12-10 22:01:52
Sorry if this is a basic c++ misunderstanding on my part, but why does this
compile, since there is no using in this code and to_iso_string is in namespace
boost::gregorian?
#include <boost/date_time/gregorian/formatters.hpp>
#include <iostream>
int main(int argc, char** argv) {
boost::gregorian::date d(2010, 1, 1);
std::cout << to_iso_string(d) << std::endl;
std::cout << to_iso_extended_string(d) << std::endl;
std::cout << to_simple_string(d) << std::endl;
return 0;
}
------------------------------
g++ to_iso_string.cpp -I../boost_1_44_0/include -L../boost_1_44_0/lib -
lboost_date_time-mt
Thanks
Dan
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net