[ create a new paste ] login | about

pyrtsa_

Name:
Email:
Site/Blog:
Location:
Default language:
Favorite languages:
About:

Saved pastes by pyrtsa_:

C++, pasted on Nov 14:
1
2
3
4
5
#include <boost/bind.hpp>
#include <boost/function.hpp>
#include <iostream>

struct X {
...
view (17 lines, 2 lines of output)
C++, pasted on Jul 7:
1
2
3
4
5
#include <iostream>
#include <boost/shared_ptr.hpp>

struct base {
    int i;
...
view (20 lines, 2 lines of output)
C++, pasted on May 21:
1
2
3
4
5
#include <boost/foreach.hpp>
#include <boost/ptr_container/ptr_set.hpp>
#include <iostream>

struct listener {
...
view (31 lines, 2 lines of output)
C++, pasted on Dec 16:
1
2
3
4
5
#include <boost/static_assert.hpp>
template <typename To, typename From>
inline To bitwise_cast(From const & from) {
    BOOST_STATIC_ASSERT(sizeof(To) == sizeof(From));
    union { To to; From from; } u;
...
view (18 lines, 5 lines of output)
C++, pasted on Oct 17:
1
2
3
4
5
#include <vector>    // std::vector
#include <iostream>  // std::cout
#include <algorithm> // std::for_each

// a function object calculating the sum of floats
...
view (27 lines, 1 line of output)
C++, pasted on Oct 12:
1
2
3
4
5
#include <limits>

template <typename T> T clamp(T x, T lower, T upper) {
    if (x < lower) return lower;
    if (x > upper) return upper;
...
view (27 lines, 9 lines of output)