Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: globos
  • Content: Threads
  • Order by date
  1. globos

    Mixed columns design problem

    Hi all, I have a table design problem with the modeling of the dimensions of a work piece (mechanical part). A work piece can be cylindrical (radius, height) or cuboid (width, length, height). Actually this is modeled like this : table work_piece ( id INTEGER, type INTEGER, -- type = 0...
  2. globos

    Strange compilation error with a template member method

    Hi all, I get a compilation error with this source code (simplified to isolate the problem) : struct VirtualTable { template<typename _FUNC_> void add() { } }; // struct VirtualTable template<typename _T_> struct functor { private: VirtualTable* _vtable; public...
  3. globos

    POSIX routines

    Does someone know the rules for the C POSIX library? I mean what headers, routines are always availables for C/C++ compilers? For example <dirent.h> is a POSIX header but is not present in Visual C++ 2005. Another example is stricmp() for which Visual C++ 2005 complains about deprecation(it says...
  4. globos

    Shared Singleton across DLLs

    Hello, I would like to have a Singleton class that ensures to have only one instance wherever the code flow is in a DLL or in the main program. My Singleton class is like this: template<class G> class Singleton { public: // Unique instance of type G. static G* instance () {...
  5. globos

    Operator[ ] with two arguments

    Hello there, I have defined a generic class for two-dimensional arrays, called Grid<G>. I would like to define the operator[] with two arguments, ie the row and the column that define the coordinates of the item to access : template<class G> class Grid : public Array<G> { // All other...
  6. globos

    Problem with templates and inheritance

    Hi, Please try to compile this code : template<class G, class H> class Table { public: virtual const G& item (const H& k) const = 0; }; template<class G> class Indexable : public Table<G, int> { public: //virtual const G& item (const int& k) const = 0; virtual const G& i_th (int i)...
  7. globos

    Error with generics, pointers and const

    Hi, I have a problem with the compilation of some code. It appears when mixing generics with pointers and const. Here is a dummy sample : class Object//Our dummy data class {}; template<class G>//A generic class defining a request class A { public: bool has (const G& v) const {...
  8. globos

    Partial specialization with MS C++ compiler

    I want to know if a type is a pointer during execution. I know the mechanism to use is partial specialization, I have found this source code : #include <assert.h> #include <iostream> using namespace std; template<class G> struct is_pointer_type { static const bool value = false; }...
  9. globos

    Can programs compiled with VC7 cmd line tools be debugged with VC6 ?

    Hi, I have not tested it yet. Have someone already done this? i.e. compile a C++ program with VC++ 7 command lines tool(or from the IDE) and try to debug it in VC++ 6. -- Globos
  10. globos

    Tools for memory leak detection

    Hi, Currently I am detecting memory leaks with a very basic mechanism which consists of the VC++ debugger and the C runtime debug heap functions. I have to put these lines : #define CRTDBG_MAP_ALLOC #include <stdlib.h> #include <crtdbg.h> at the begining of the file containing the main...
  11. globos

    Using COleDispatchDriver class outside MS Visual Studio.

    Hi, I'm stuck with using an ActiveX control outside MS Visual Studio (I use command line tools). The ActiveX Container I use is QAxContainer (a Qt module). Wrapping the control with Qt is ok. But I need to query the IDispatch interface of the control, because they are calls to the ActiveX...
  12. globos

    Listing files with their location information

    Hi, I would like to list the files of a directory recursively. I want the output format to be like this example (listing current directory) : foo.hh foo.cpp sub-dir1/stuff.hh sub-dir1/other-stuff.hh sub-dir1/sub-dir11/ooo.hh sub-dir2/bar.hh sub-dir2/other-bar.hh One file per line, and...
  13. globos

    Reduce compilation times

    Hi, I don't follow the recommended C++ practice that consists to separate header files and implementation files. Most of my classes are fully defined in their header files. The well-known drawback is that it makes compilation slow. By now I feel the need to really reduce compilation times, I...
  14. globos

    Emulating &quot;implies&quot; logical operator

    Hi, I want to emulate the 'implies' (=>) logical operator in C++. There's no built-in support for it. For this purpose, I firstly defined a macro : # define implies(a, b) !(a) || (b) And it works fine, especially if a is false then b is not evaluated. But syntactically speaking, this is...
  15. globos

    Get the keys of a std::hash_map object

    Hi, I've taken a look at the STL documentation and found no means to get the defined keys of hash_map objects. How to get these keys? Thanks. -- Globos
  16. globos

    Free web-based collaboration tool

    Hi all, I'm working on a software project with a person belonging to another firm than mine. Currently, we exchange our work(documents, test cases, etc.) via emails. For the moment it's ok, but I'm looking for a tool that can centralize the work done, and can feature project management. I...
  17. globos

    Executable crashes when optimization was enabled during compilation

    Hi, I have a strange problem. When I compile my code with option -O1 or -O2(respectively creates the smallest code, creates the fastest code) and then I try to run it, it crashes. If the code was compiled with this optimization disabled, execution is ok. Does someone ever meet the same problem...
  18. globos

    HTML source editor

    Hi, Can someone advise me for a free HTML source editor(more powerful than notepad, please)? expected basic features: -syntax highlighting -javascript code edition -some automation tools(array generation, etc.) Thanks. -- Globos
  19. globos

    How to tell the compiler to use another STL version?

    Hi, I've installed STL headers from sgi in a path like : $(LIBDIR)\STL\include I want the Microsoft compiler to use these headers instead of those located in ...\VC98\include. I'm using Visual C++ 6.0, how to do this? Thanks. -- Globos
  20. globos

    Multiple inheritance

    Consider the following basic code: class A { public: virtual void proc () = 0;//deferred procedure }; class B : public A { }; class C : public A { public: virtual void proc ()//basic implementation { } }; class D : public B, public C { }; int main () { D d; return 0; } As you...

Part and Inventory Search

Back
Top