Skip to content

Instantly share code, notes, and snippets.

View mloskot's full-sized avatar
🏠
Working from home

Mateusz Łoskot mloskot

🏠
Working from home
View GitHub Profile
@mloskot
mloskot / boost_geometry_status-20141103.md
Last active August 29, 2015 14:08
Quick report of the Boost.Geoemtry implementation support status in plain text format, with modified code for text_outputter.hpp to pretty-print with geometry names included.
@mloskot
mloskot / soci-3.2.3-github-changelog.md
Created April 8, 2015 21:26
SOCI 3.2.3 release changelog
  1. 30c02f3 - Merge branch 'master' of git://github.com/Alex-Vo/lsoci into hotfix/3.2.3-PR263
  2. 5577606 - Improve readability of ODBC error message Closes #229
  3. 8e14c5b - Improve error message when an odbc error occurs
  4. 8a50af6 - Merge branch 'hotfix/3.2.3' of https://github.com/SOCI/soci into hotfix/3.2.3
  5. a948ab3 - Remove unused HAVE_XXX defines
  6. 2c85be1 - Fix missing strtoll on Cygwin and MinGW
  7. d9c059e - Clarify documenation and examples on bulk operati
@mloskot
mloskot / image_read_iterator-blueprint.hpp
Created November 7, 2011 11:36
Christian brainstorming image_read_iterator for Boost.GIL
// Christian Henning's original: http://pastebin.com/Qk3ssZc8
namespace boost { namespace gil {
template< typename Reader
, typename View
>
class image_read_iterator
{
public:
@mloskot
mloskot / moveable_base_animal.cpp
Created January 13, 2012 16:00
Moveable semantic fun
#include <iostream>
#include <string>
#include <utility>
#include <boost/noncopyable.hpp>
struct animal : private boost::noncopyable
{
animal() {}
animal(char const* name) : name(name) {}
@mloskot
mloskot / empty_equals_empty.cs
Created January 14, 2012 00:15
Check equality of EMPTY geometries using SqlGeometry from SQL Server CLR Types
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Microsoft.SqlServer.Types;
namespace csharp
{
class Program
@mloskot
mloskot / spirit_fusion_vector_optional.cpp
Created March 29, 2012 10:37
Boost.Spirit - fusion::vector as attribute with optional elements
// Version fixed by VeXocide
// Test case based on solution discussed here:
// http://thread.gmane.org/gmane.comp.parsers.spirit.general/24684/focus=24688
#include <boost/config/warning_disable.hpp>
#include <boost/spirit/include/qi.hpp>
#include <boost/fusion/include/vector.hpp>
namespace qi = boost::spirit::qi;
@mloskot
mloskot / smart_ptr_bad_bool_conversion.cpp
Created April 18, 2012 11:21
Smart pointer example with mis-use of bool conversion
// Interesting issue about conversion operators in C++
//http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2004/n1592.pdf
#include <iostream>
template <class T>
class Ptr
{
// stuff
public:
/* For NAN */
#ifdef __GNUC__
#define _GNU_SOURCE
#endif
#include <math.h>
@mloskot
mloskot / bobp-python.md
Created November 25, 2015 23:18 — forked from sloria/bobp-python.md
A "Best of the Best Practices" (BOBP) guide to developing in Python.

The Best of the Best Practices (BOBP) Guide for Python

A "Best of the Best Practices" (BOBP) guide to developing in Python.

In General

Values

  • "Build tools for others that you want to be built for you." - Kenneth Reitz
  • "Simplicity is alway better than functionality." - Pieter Hintjens