Search Results - CodeGuru Forums
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: Lindley

Page 1 of 80 1 2 3 4

Search: Search took 0.29 seconds.

  1. Replies
    3
    Views
    307

    Re: Pass value from one function to another

    Note that <string> and <cstring> are not the same.

    <cstring> is C++'s name for the old C <string.h>. It contains functions to operate on char*-style strings, like strcat, strcpy, etc.

    <string>...
  2. Replies
    1
    Views
    149

    Detect protected destructor?

    Is there a way to detect whether or not a template type has a protected destructor?

    I see there is std::is_destructible in C++11, but I can't tell if this will return true or false for the...
  3. Re: Inheriting one variadic class from another

    I believe I've worked it out. I did need a helper class to do the majority of the logic and keep the extra type hidden from the main interface.
  4. Re: Inheriting one variadic class from another

    I may have generalized my example code too much....in my case, the parameter pack is a list of values, not types. This is good in that it allows me to pass an additional type as the first argument,...
  5. Inheriting one variadic class from another

    Let's say I have a variadic base class with a pure-virtual function per type:



    template <typename ... Types>
    class Base;

    template <typename T, typename ... Types>
    class Base<T,Types...>:...
  6. Replies
    2
    Views
    303

    Re: Variadic templates and type composition

    Thanks, that's exactly what I needed!
  7. Replies
    2
    Views
    303

    Variadic templates and type composition

    Here's an interesting question I encountered. This isn't critical, but it would be "cool" to know how to accomplish it....

    Let's say I have a variadic type A and a non-variadic type B:

    ...
  8. Replies
    4
    Views
    227

    Re: Pure virtuals and construction order

    I don't really like base_from_member much, although I can see how it could occasionally save the day. In this case, though, it's a matter of completely inverting the normal construction/destruction...
  9. Replies
    4
    Views
    227

    Pure virtuals and construction order

    I have an AbstractAgent base class that manages a background thread. The actual work done in the background thread is accomplished through a pure virtual function call.

    Here's the problem: because...
  10. Re: Templates, multiple inheritance, and ambiguous overloads

    I suspect I need to add these to Derived:


    using Consumer<A>::consume;
    using Consumer<B>::consume;


    After reviewing what I'm actually trying to do, though, I'm going to make Consumer a...
  11. Templates, multiple inheritance, and ambiguous overloads

    Let's say I have a templated base class:


    template <typename Input>
    class Consumer
    {
    public:
    void consume(Input input)
    {
    // do something
  12. Re: Termination of namespaces with a closing brace only ...

    That's just what the rule is, I've never thought too hard about it.

    I suppose one *could* argue that a namespace is merely a scope, and like all scopes it doesn't require a closing semicolon,...
  13. Re: Variadic templates and overload resolution

    the same thing that's going on here:


    So what you're saying is that during overload resolution, exact matches are preferred over template matches, but template matches are preferred over base...
  14. Variadic templates and overload resolution

    I'm trying to learn how to use variadic templates, and I decided a great example would be serializing a series of types into a stringstream:



    // Send a fully constructed message.
    ...
  15. Replies
    6
    Views
    596

    Re: C Compiler for bare metal

    gcc will do what you need.

    I suggest you learn about virtualization environments such as qemu. They can greatly simplify the process of experimenting with OS-level functionality without...
  16. Replies
    8
    Views
    414

    Re: Memory allocation for the array

    Let's be careful not to confuse the issue. Even though that last example works, there is a semantic difference between a pointer and an array, and that example mixes their syntax. It should be...
  17. Replies
    7
    Views
    368

    Re: bad side of global variable

    1) Unit testing. A given function should always behave the same way when called with the same arguments; this is the basis of unit testing. If that function relies on global state, then it may not...
  18. Replies
    5
    Views
    363

    Re: Embedding version strings at build time

    Perhaps the fact that I'm finding it difficult to decide which header(s) should include the version header indicates I need to split one of my repos because it has too many unrelated things in it....
  19. Replies
    5
    Views
    363

    Re: Embedding version strings at build time

    My first experience with gitflow taught me that it's a mistake to include completely orthogonal bits of software in a single repo, because bumping the release version reflects on the entire repo, not...
  20. Replies
    5
    Views
    363

    Embedding version strings at build time

    This is sort of a C++ question, but also sort of a build-system question.

    I have a set of projects. Each one builds either a static library or an executable. What I'd like to do, is at build time...
  21. Replies
    3
    Views
    625

    Avoiding template parameter creep

    Let's say you decide you want a std::array as a member of your class.

    std::array takes its size and type as template parameters. Therefore, the outer class must either determine these explicitly,...
  22. Replies
    3
    Views
    395

    Re: Latency-critical networking library

    I don't need any reliability guarantees per se, but I would like the ability to *decrease* packet loss rates if possible. That's really the only reason I don't just use straight-up UDP.
  23. Replies
    3
    Views
    395

    Latency-critical networking library

    I am looking for a C++ networking library that emphasizes minimum latency at the expense of all else. I like the design of ZeroMQ, but I'm concerned that it doesn't provide an unreliable transport,...
  24. Replies
    1
    Views
    272

    Version string best practices

    I have a question that I know must have been solved a thousand times before, but I'd like to get the community's opinion on best practices.

    In short: how should I manage the version string of my...
  25. Detecting send failures in a SocketChannel

    Hello,

    I have a connected non-blocking SocketChannel. When I call write(), I would like to know whether or not the bytes were successfully transmitted all the way to the server. However, it...
Results 1 to 25 of 2000
Page 1 of 80 1 2 3 4


Azure Activities Information Page

Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center