User Profile

Collapse

Profile Sidebar

Collapse
ivotron
ivotron
Last Activity: Dec 7 '06, 08:26 AM
Joined: Dec 7 '06
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • did you copy/pasted your code? Because you have an extra space:

    Code:
    template <class T> T Bar<T>::bar_func() {
    list < Foo<T> >:: iterator iter;
    ....             |
                     |
                    here
    }
    See more | Go to post

    Leave a comment:


  • Hi, there are several ways to communicate two processes: pipes, shared memory, messages, etc... More info here: http://www.cs.cf.ac.uk/Dave/C/node23.html
    See more | Go to post

    Leave a comment:


  • ivotron
    replied to debug daemon ?
    in C
    Did the compilation ended? When you compiled with -ggdb, did compile succesfully? If yes you can use:

    gdb <program_name >

    then you'll get a command prompt:

    (gdb)

    you can start tracing your program there. the help command is very useful. Hope this helps, good luck.
    See more | Go to post

    Leave a comment:


  • ivotron
    replied to problem with fstream
    in C
    Hi,

    Still trying to solve this... I've printed the put pointer, to know if its moving:

    Code:
    int main()
    {
       std::ifstream file("file.txt");
       unsigned long oldval;
       unsigned long newval;
    
       while(!file.eof()) {
          file >> oldval;
          file >> newval;
          std::cout << oldval << " " << newval <<
    ...
    See more | Go to post

    Leave a comment:


  • ivotron
    replied to problem with fstream
    in C
    Hi,

    Still trying to solve this. I'm trying reading each line and then, with std::stringstre am, pass

    Code:
    int main()
    {
       std::ifstream file("file.txt");
       unsigned long oldval;
       unsigned long newval;
       std::string line;
    
       while(!file.eof()) {
          std::getline(file, line);
          std::stringstream linestream(line);
          linestream >>
    ...
    See more | Go to post

    Leave a comment:


  • ivotron
    started a topic problem with fstream
    in C

    problem with fstream

    Hi,

    I have very strange problem with std::fstream. I want to read a simple two-column space-separated file with the following code:

    #include <iostream>
    #include <fstream>

    Code:
    int main()
    {
       std::ifstream file("file.txt");
       unsigned long oldval;
       unsigned long newval;
    
       while(!file.eof()) {
          file >> oldval;
    ...
    See more | Go to post
No activity results to display
Show More
Working...