VisualStudio is unable to compile mathplot
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 68/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Quiet
- Tech stack
- cpp
- Domain
- build-system
Research direction
Start at mplot/VisualOwnable.cppm around line 1067, inside savegltf(const std::string&), where fout is declared: MSVC says std::basic_ofstream is undefined, so check whether <fstream> is included (directly or via a module unit that Windows compilation does not inherit). Compare with how other save/export functions in the same file obtain their stream types, and check the GitHub Actions Windows runners' build logs for anneal_asa.vcxproj to reproduce. Done means the Windows 2022 and 2025 runners build the examples cleanly while Linux/macOS builds stay green.
Written by the indexing model from the issue text.
Description
VisualStudio (both the "Windows 2022" github runner version and the "Windows 2025" github runner version) chokes on some code that I believe to be valid C++.
The file is VisualOwnable.cppm and the error message is:
D:\a\mathplot\mathplot\mplot\VisualOwnable.cppm(1067,27): error C2079: 'fout' uses undefined class 'std::basic_ofstream<char,std::char_traits<char>>' [D:\a\mathplot\mathplot\build\examples\anneal_asa.vcxproj]
(compiling source file '../../examples/anneal_asa.cpp')
D:\a\mathplot\mathplot\mplot\VisualOwnable.cppm(1067,27):
the template instantiation context (the oldest one first) is
D:\a\mathplot\mathplot\examples\anneal_asa.cpp(101,21):
see reference to class template instantiation 'mplot::Visual<262145>' being compiled
D:\a\mathplot\mathplot\mplot\Visual.cppm(59,34):
see reference to class template instantiation 'mplot::VisualOwnable<262145>' being compiled
D:\a\mathplot\mathplot\mplot\VisualOwnable.cppm(1065,22):
while compiling class template member function 'void mplot::VisualOwnable<262145>::savegltf(const std::string &)'
I've yet to try to make a report on this to Microsoft.
- Dominant language
- C++
- Stars
- 66
- Forks
- 13
- Avg merge
- 13h 58m
- Merged PRs (30d)
- 12
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from sebsjames/mathplot
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 20/100
sebsjames/mathplot#148 · 4 comments ·
Maintainers usually reply within 1 day
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
Maintainers usually reply within 1 day
-
Difficulty 4/5 3-5 days Newbie friendliness 43/100
Maintainers usually reply within 1 day
All issues in sebsjames/mathplot
Similar issues
-
bug libcudf
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 2 days
-
level/task module/cloud monitoring type/maintenance
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
LadybirdBrowser/ladybird#13809 ·
Maintainers usually reply within 1 day
-
bug module:nodes tests
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
rocketride-org/rocketride-server#3020 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 9 days