VisualGDB can't find iostream in main.h

Sysprogs forums Forums VisualGDB VisualGDB can't find iostream in main.h

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #31305
    GeneM
    Participant

    I have a project with a main.cpp and a main.h and several classes.  Each class gets its own .cpp and .hpp file.  I’ve been using

    #include <iostream >

    in  a couple of class header files without issue.  However, now I’d like to add it to main.h and I get this error:

    iostream: No such file or directory

    I didn’t think the extension for header files and source files matter but I’ve tried main.hpp and main.c anyhow and that didn’t seem to help.  Here’s my main.h.

    #ifndef __MAIN_H
    #define __MAIN_H

    #include <stdint.h>
    #include<iostream>
    #include "stm32h7xx_hal.h"
    #include "stm32h7b3i_discovery_sd.h"
    #include "stm32h7b3i_discovery.h"

    #include "FatFsErrorCodes.h"

    void Error_Handler(void);

    #endif /* __MAIN_H */

    I’ve tried various ways to get around this but nothing has worked so far.  Any suggestions will be greatly appreciated.

    Thanks

    • This topic was modified 3 years, 2 months ago by GeneM.
    • This topic was modified 3 years, 2 months ago by GeneM.
    • This topic was modified 3 years, 2 months ago by GeneM.
    • This topic was modified 3 years, 2 months ago by GeneM.
    • This topic was modified 3 years, 2 months ago by GeneM.
    • This topic was modified 3 years, 2 months ago by GeneM.
    #31318
    support
    Keymaster

    Hi,

    This looks like a generic programming issue and not something VisualGDB-specific. If you believe VisualGDB is not working as expected, please try reproducing the problem from scratch (on a cleanly created empty project) and let us know the steps to reproduce it per our problem reporting guidelines.

    If the problem only happens on a specific project, please try comparing this project to a cleanly created project until you can pinpoint a specific setting that is causing this. If you believe this setting is not working as expected, please let us know more and we will investigate it further.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.