DCPUTeam / DCPUToolchain

[ARCHIVED] The code repository for the DCPU-16 Toolchain.
http://dcputoolcha.in/
MIT License
97 stars 14 forks source link

Preprocessor comments #131

Closed patflick closed 12 years ago

patflick commented 12 years ago

the preprocessor does not notice C style comments:

if the c file has

// #include "screen.m"

the preprocessor still tries to include

can't include 'screen.m'.
Mause commented 12 years ago

Quick side note, the compiled was being run from outside its root directory, so did not have access to the screen.m file

hach-que commented 12 years ago

It would be worse if it did; that would mean only the first line of screen.m would be commented out....

EDIT: I've just tested this and I can't seem to reproduce it. It's one of the things we have fixed previously so it might be a case of using an old build. Re-open if it isn't.

Mause commented 12 years ago

Diregard: Uh, do you mean to say that the comment would carry through to screen.m?

EDIT: Oh, right, yeah. Sorry. I'm using the release build, i just get complaints about $end on the other builds, but thats probably my fault :P

patflick commented 12 years ago

@Mause can you reproduce the $end error? Please try this :)

Mause commented 12 years ago

For one, it might be worth mentioning somewhere that if you're not getting very helpful error messages,you should run your code through dtpp so you can figure out where the error actually is, and in which file. I should probably add an issue, so that the toolchain tells you which file the error is in :P

EDIT: now i'm not so sure, actually :P the pre-processor doesn't show any errors but when i try to use the compiler it does. Mind you, im using the latest buildable version of the toolchain, so i might have to fix windows compilation before i make any more claims.

EDIT2: these are the files im trying to compile. they are put into a a subdirectory called DoSH, and the build.bat file is in the root toolchain directory. http://dl.dropbox.com/u/17607607/DoSH.rar