bigstumpy

u/bigstumpy



r/cpp_questions•

I'm code generating C++ structs from another codebase in Haskell. The structs are all templated and contain elements of type T, or other similar structs containing T, but sometimes are empty so I can't cast the struct to an array of T.

What is the most elegant way to write an iterator over the Ts? It's OK if it's a bit of code to get it done, since I'm automatically generating it, but the more generic the solution the better.

template <typename T>
struct V2 {
  T x;
  T y;
};

template <typename T>
struct V3 {
  V2<T> u;
  V2<V2<T> > v;  // this sort of thing makes it harder
  T w;
};

Even suggesting key

05




r/Surface•

I live in Germany but want to get a US Surface Pro 3. I contacted Microsoft a few times, and it seems that I can only get a German version with a German keyboard-cover. I feel like I have 2 options:

  • Get the German one, import a US keyboard, try to change OS language and maybe deal with problems like this. Have a totally valid warranty and return options.
  • Import a US one including US keyboard. Possibly not have a warranty or be able to return it.

Do you have any insight into this? Do you foresee major problems either way? Thanks for the help.

22

r/PipeTobacco•

I'm a brand new pipe smoker. Thanks to this community for being kind and helpful!

I heard Lane 1Q is very nice and has that "delicious pipe tobacco" smell and taste. My local tabac (tabakmeier.com) seems to carry about 10 major brands but no Lane 1Q, is that because 1Q is not as "high end" as others?

Does anyone know a place to order pipe tobacco online with shipping to Germany? Many places will ship to Germany but it gets stuck in customs and you have to go to this place on the outskirts of town and pay the extra tax, and they treat you like a criminal. I'm looking for a shop which handles the tax for you.

I'm also looking for some tobacco recommendations. Brows

811

r/PipeTobacco•

I smoked pipe tobacco a few times years ago and I want to get my own pipe now, but I'm really overwhelmed by the options. I'd appreciate recommendations of good all-around first pipes and a few varied tobacco selections in the 100 euro price range. Bonus points if the pipe looks like a hobbit pipe. Thanks!

010