| Instance | Branch |
|---|
| # Xcode 4.3.3 | |
| Apple clang version 3.1 (tags/Apple/clang-318.0.61) (based on LLVM 3.1svn) | |
| Target: x86_64-apple-darwin11.4.0 | |
| Thread model: posix | |
| # Xcode 4.3.2 | |
| Apple clang version 3.1 (tags/Apple/clang-318.0.58) (based on LLVM 3.1svn) | |
| Target: x86_64-apple-darwin11.4.0 | |
| Thread model: posix |
| // This is example from | |
| // http://vitiy.info/c11-functional-decomposition-easy-way-to-do-aop/ | |
| // by Victor Laskin | |
| #include <iostream> | |
| #include <functional> | |
| #include <map> | |
| #include <vector> | |
| #include <memory> | |
| #include <chrono> |
Free O'Reilly books and convenient script to just download them.
Thanks /u/FallenAege/ and /u/ShPavel/ from this Reddit post
How to use:
- Take the
download.shfile and put it into a directory where you want the files to be saved. cdinto the directory and make sure that it has executable permissions (chmod +x download.shshould do it)- Run
./download.shand wee there it goes. Also if you do not want all the files, just simply comment the ones you do not want.
For a brief user-level introduction to CMake, watch C++ Weekly, Episode 78, Intro to CMake by Jason Turner. LLVM’s CMake Primer provides a good high-level introduction to the CMake syntax. Go read it now.
After that, watch Mathieu Ropert’s CppCon 2017 talk Using Modern CMake Patterns to Enforce a Good Modular Design (slides). It provides a thorough explanation of what modern CMake is and why it is so much better than “old school” CMake. The modular design ideas in this talk are based on the book [Large-Scale C++ Software Design](https://www.amazon.de/Large-Scale-Soft
What is strict aliasing? First we will describe what is aliasing and then we can learn what being strict about it means.
In C and C++ aliasing has to do with what expression types we are allowed to access stored values through. In both C and C++ the standard specifies which expression types are allowed to alias which types. The compiler and optimizer are allowed to assume we follow the aliasing rules strictly, hence the term strict aliasing rule. If we attempt to access a value using a type not allowed it is classified as undefined behavior(UB). Once we have undefined behavior all bets are off, the results of our program are no longer reliable.
Unfortunately with strict aliasing violations, we will often obtain the results we expect, leaving the possibility the a future version of a compiler with a new optimization will break code we th
| /* Copyright (c) 2018 Arvid Gerstmann. */ | |
| /* This code is licensed under MIT license. */ | |
| #ifndef AG_RANDOM_H | |
| #define AG_RANDOM_H | |
| class splitmix | |
| { | |
| public: | |
| using result_type = uint32_t; | |
| static constexpr result_type (min)() { return 0; } |
| // make_vector.hpp | |
| // | |
| // Copyright (c) 2019 Tristan Brindle (tcbrindle at gmail dot com) | |
| // Distributed under the Boost Software License, Version 1.0. (See | |
| // http://www.boost.org/LICENSE_1_0.txt) | |
| #include <type_traits> | |
| #include <vector> | |
| namespace tcb { |
| // N4317 "New Safer Functions to Advance Iterators" paper can be found at | |
| // http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n4317.pdf | |
| namespace detail { | |
| template<class InputIter> | |
| inline void do_advance(InputIter& it, InputIter end, typename std::iterator_traits<InputIter>::difference_type n, std::input_iterator_tag) | |
| { | |
| assert(n >= 0); | |
| for (; (n > 0) && (it != end); --n) | |
| ++it; |
This is a collection of the things I believe about software development. I have worked for years building backend and data processing systems, so read the below within that context.
Agree? Disagree? Feel free to let me know at @JanStette.
Keep it simple, stupid. You ain't gonna need it.