Why compile in visual c++?
Results 1 to 4 of 4

Thread: Why compile in visual c++?

  1. #1
    Junior Member
    Join Date
    Aug 2004
    Posts
    25

    Question Why compile in visual c++?

    Hi there,

    I have started to write c and c++ programs using the visual c++ IDE, although I have no idea why visual c++ offers users the ability to build and/or compile a piece of code, when building the code in-order to debug the code creates an executable in the Debug folder.

    I am fairly sure that there must be a reason for offering users the ability to compile and/or build a piece of code, and not just offering the build operation. Therefore if anyone could inform me as to the use of having both operations available in this IDE I would be grateful.

    Thanx in advance,
    L8R, TTAYO

  2. #2
    Senior Member
    Join Date
    Dec 2003
    Location
    LA, CA
    Posts
    292
    If I understand your question correctly you are asking why the software creates chunks of compiled code in addition to the full exe's it can create?

    This allows you to create reusable code. An example would be a class def. for a security layer object. When the object is created it's constructor accepts information about the systems database location and login info. Then your system calls functions in the security object for login, authencation, ect..

    You can also build projects with different sections written in different languages.
    A mind full of questions has no room for answers

  3. #3
    Junior Member
    Join Date
    Aug 2004
    Posts
    25
    No, I don't mean that visual c++ creates reusable code, such as header files or functions.

    When you use visual c++, to debug code you have to "build" the code first and this creates and executable in the Debug folder. In addition to the build option the user of this IDE also has the option the compile the code to create and executable.

    Therefore my question is, when using visual c++, what does the compile operation do that the build operation does not?

  4. #4
    Senior Member
    Join Date
    Dec 2003
    Location
    LA, CA
    Posts
    292
    Sorry for misunderstanding you
    this link might help you out
    http://msdn.microsoft.com/library/de...nd_linking.asp
    A mind full of questions has no room for answers

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •