Update of /cvsroot/boost-sandbox/boost-sandbox/libs/units/example
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv10335/example
Modified Files:
unit_example_4.cpp
Log Message:
improve SI compliance
Index: unit_example_4.cpp
===================================================================
RCS file: /cvsroot/boost-sandbox/boost-sandbox/libs/units/example/unit_example_4.cpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- unit_example_4.cpp 3 Apr 2007 14:50:19 -0000 1.5
+++ unit_example_4.cpp 3 Apr 2007 17:12:57 -0000 1.6
@@ -156,7 +156,7 @@
/// sin takes a quantity and returns a dimensionless quantity
template<class System,class Y>
quantity<unit<dimensionless_type,System>,Y>
-sin(const quantity<unit<angle_type,System>,Y>& theta)
+sin(const quantity<unit<plane_angle_type,System>,Y>& theta)
{
return quantity<unit<dimensionless_type,System>,Y>(std::sin(theta.value()));
}
@@ -165,10 +165,10 @@
//[unit_example_4_function_snippet_2
/// asin takes a dimensionless quantity and returns a quantity
template<class System,class Y>
-quantity<unit<angle_type,System>,Y>
+quantity<unit<plane_angle_type,System>,Y>
asin(const quantity<unit<dimensionless_type,System>,Y>& val)
{
- typedef quantity<unit<angle_type,System>,Y> quantity_type;
+ typedef quantity<unit<plane_angle_type,System>,Y> quantity_type;
return quantity_type::from_value(std::asin(val.value()));
}
|