comparison dmd/root.c @ 305:2b72433d5c8c trunk

[svn r326] Fixed a bunch of issues with printf's that MinGW32 did not support. Fixed problems with label collisions when using labels inside inline asm. LabelStatement is now easily reached given its Identifier, which should be useful elsewhere too. Enabled inline asm for building the lib/compiler/llvmdc runtime code, fixing branches out of asm makes this possible.
author lindquist
date Fri, 27 Jun 2008 22:04:35 +0200
parents 297690b5d4a5
children aaade6ded589
comparison
equal deleted inserted replaced
304:3ebc136702dd 305:2b72433d5c8c
34 34
35 #include "port.h" 35 #include "port.h"
36 #include "root.h" 36 #include "root.h"
37 #include "dchar.h" 37 #include "dchar.h"
38 #include "mem.h" 38 #include "mem.h"
39 #include "mars.h"
39 40
40 #if 0 //__SC__ //def DEBUG 41 #if 0 //__SC__ //def DEBUG
41 extern "C" void __cdecl _assert(void *e, void *f, unsigned line) 42 extern "C" void __cdecl _assert(void *e, void *f, unsigned line)
42 { 43 {
43 printf("Assert('%s','%s',%d)\n",e,f,line); 44 printf("Assert('%s','%s',%d)\n",e,f,line);
1323 } 1324 }
1324 1325
1325 void File::checkoffset(size_t offset, size_t nbytes) 1326 void File::checkoffset(size_t offset, size_t nbytes)
1326 { 1327 {
1327 if (offset > len || offset + nbytes > len) 1328 if (offset > len || offset + nbytes > len)
1328 error("Corrupt file '%s': offset x%zx off end of file",toChars(),offset); 1329 error("Corrupt file '%s': offset x%"PRIxSIZE" off end of file",toChars(),offset);
1329 } 1330 }
1330 1331
1331 char *File::toChars() 1332 char *File::toChars()
1332 { 1333 {
1333 return name->toChars(); 1334 return name->toChars();