C++: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
m (→Hashmap) |
||
Line 9: | Line 9: | ||
* [http://www.boost.org/doc/libs/release/libs/ptr_container Pointer containers] (vector, list, deque...) | * [http://www.boost.org/doc/libs/release/libs/ptr_container Pointer containers] (vector, list, deque...) | ||
== | ==Miscellaneous== | ||
* [[Using a hashmap]] | * [[Using a hashmap]] | ||
* [http://wwwasd.web.cern.ch/wwwasd/cernlib/cfortran.html Interfacing C/C++ and Fortran] | |||
---- | ---- |
Revision as of 08:27, 12 May 2011
Reference websites
Pointers handling
pointers are not always easy to handle, particularly for destruction, memory management... There exists some solutions provided by boost
- Smart pointers (shared_ptr,...)
- Pointer containers (vector, list, deque...)
Miscellaneous
quick example of c++ source display: <source lang="cpp"> template<typename T> class B { private:
T t;
public:
B(T const& _t) : t(_t) {}; T value() const {return t;};
};
int main() {
B<int> b(2);
} </source>