I'm learning C++ by modifying an existing application. It's so frustrating because everytime I change just one line...

I'm learning C++ by modifying an existing application. It's so frustrating because everytime I change just one line, the whole thing takes about 10 minutes to compile. This is a problem if you need to compile after writing each line. Sometimes you need to compile multiple times to correct just one line.

How the hell does anyone get anything done if it takes 10 minutes per line of code?

Attached: 1527545486106s.jpg (250x228, 5K)

wtf do you compile? tried incremental compilation or -O0?

You know thats highly based on your computers cpu speed and ram, right?....

>wtf do you compile?
It's a VoIP application.

>Incremental compilation
I think Visual Studio does that automatically.

This is why I prefer Python. I can edit the code and run it right away. I don't have to wait for an extra compilation step to tell me if I fucked up.

Yes, but still 10 minutes is way too long to compile a single line change.

Either it's a huge code base or it's just terribly designed.
It should just recompile the files that have changed and then link them to the ones compiled previously.
Are you changing header files that a lot of .cpp files then use?

Yes, I am changing the header to change a function to accept an additional variable.

I've been experimenting with char, char*, *char, const *char, const * char, *const char, *const *char and all combinations like that to see which works. Only problem is each time I change it, it takes forever to compile.

Why don't you use make?

Actually disk speed matters too, try to set compile destination to /tmp, it will compile in the memory and reduce disk usage.

It has nothing to do with how many lines you change.
Every time you change that header file all the .cpp files that includes that header get recompiled.
So even if you changed one header, if 100 files includes it then 100 files needs to be recompiled.
Also experimenting like that tells me you don't have a clue what you're doing or what a pointer or char is.
If it's C++ you should use std::string most likely.

It's a Visual Studio project written by somebody else. I don't see any wizard for creating make files. If I do it manually, I don't know what's the benefit.

It says Visual Studio has to run as Administrator in order to have permission to write to C:\Windows\Temp

Yeah I don't know what a pointer is and all the different types of chars with a * and & and other characters. I just want to pass a few letters through a function like I do in Python. I'll look into std::string, thanks.

When I was young there was this ongoing joke at my first company that C++ was invented for one single purpose only: to give programmers jobs and secure a stable stream of revenue.

Except it wasn't a joke.

Attached: eternal monika.png (393x337, 194K)

Or maybe skiddies should just stay away from real languages.

Switch to common lisp where you can compile individual functions into a running program with a simple key shortcut

Wait until you try to write a kernel patch and you have to reboot every time you want to test a change.

Can't you just virtualize

>Yeah I don't know what a pointer is and all the different types of chars with a * and & and other characters.
READ A BOOK AND MAKE UR OWN SHIT INSTEAD

Debug exists for a reason

I would recommend reading a book instead of just trying shit out without knowing anything about pointers.

I started learning programming by changing stuff in source code too, but that was java. a little bit more manageable than fucking c++.

It is compiled in Debug mode already. That just brings up a DOS window printing a lot of things unrelated to what I'm doing. I am trying to std::count

you don't need to fuck with a full existing application to learn such basic stuff as pointers and chars

just make a 10 line one with standard input and output for yourself and change stuff there to learn, like everybody else

I'm modifying this application for a specific purpose by adding a custom feature.

I already know how to write a commandline application.

> I'm learning C++ by modifying an existing program

>Not sure why I need to read a whole book just to pass some letters to a function. I am not writing a full C++ application.

lol pick one, you're using Visual Studio, avoiding features you don't know, and expecting everything to be like Python, then expecting to learn something.

To answer your question, people do shit in C++ because they took more than 10 minutes to learn the concepts, and understand how the compiler looks at their code.

Mind if I take apart your house bro? I want to learn how to build my own.