Joel Parker wrote:
Bug 4527
From 205f7fdd9a63409014a322318aba3fd77ec90f47 Mon Sep 17 00:00:00 2001
From: Joel Parker <joeljkp@joel-laptop.(none)> Date: Fri, 12 Jan 2007 17:26:47 -0600 Subject: remove redundant semicolons for ANSI compat.
@@ -636,17 +636,17 @@ #define DEFINE_SMapLS(n) \ "movl " #n "(%ebp),%eax\n\t" \ "call " __ASM_NAME("SMapLS") "\n\t" \ "movl %edx," #n "(%ebp)\n\t" \
"ret" );
"ret" )
-DEFINE_SMapLS(8); -DEFINE_SMapLS(12); -DEFINE_SMapLS(16); -DEFINE_SMapLS(20); -DEFINE_SMapLS(24); -DEFINE_SMapLS(28); -DEFINE_SMapLS(32); -DEFINE_SMapLS(36); -DEFINE_SMapLS(40); +DEFINE_SMapLS(8) +DEFINE_SMapLS(12) +DEFINE_SMapLS(16) +DEFINE_SMapLS(20) +DEFINE_SMapLS(24) +DEFINE_SMapLS(28) +DEFINE_SMapLS(32) +DEFINE_SMapLS(36) +DEFINE_SMapLS(40)
Are you sure this compiles? You removed the semicolon in the macro definition and when it is used. And even if it compiles the code needs to look like C code.
bye michael
On Sat, 2007-01-13 at 21:19 +0100, Michael Stefaniuc wrote:
Joel Parker wrote:
Bug 4527
From 205f7fdd9a63409014a322318aba3fd77ec90f47 Mon Sep 17 00:00:00 2001
From: Joel Parker <joeljkp@joel-laptop.(none)> Date: Fri, 12 Jan 2007 17:26:47 -0600 Subject: remove redundant semicolons for ANSI compat.
@@ -636,17 +636,17 @@ #define DEFINE_SMapLS(n) \ "movl " #n "(%ebp),%eax\n\t" \ "call " __ASM_NAME("SMapLS") "\n\t" \ "movl %edx," #n "(%ebp)\n\t" \
"ret" );
"ret" )
-DEFINE_SMapLS(8); -DEFINE_SMapLS(12); -DEFINE_SMapLS(16); -DEFINE_SMapLS(20); -DEFINE_SMapLS(24); -DEFINE_SMapLS(28); -DEFINE_SMapLS(32); -DEFINE_SMapLS(36); -DEFINE_SMapLS(40); +DEFINE_SMapLS(8) +DEFINE_SMapLS(12) +DEFINE_SMapLS(16) +DEFINE_SMapLS(20) +DEFINE_SMapLS(24) +DEFINE_SMapLS(28) +DEFINE_SMapLS(32) +DEFINE_SMapLS(36) +DEFINE_SMapLS(40)
Are you sure this compiles? You removed the semicolon in the macro definition and when it is used. And even if it compiles the code needs to look like C code.
Yes, it compiles. For some reason there's a missing line of context in the diff. If you look at this link: http://source.winehq.org/source/dlls/kernel32/selector.c#L634
you'll see that it actually goes like this:
#define DEFINE_SUnMapLS(n) \ __ASM_GLOBAL_FUNC( SUnMapLS_IP_EBP_ ## n, \ "pushl %eax\n\t" /* preserve eax */ \ "pushl " #n "(%ebp)\n\t" \ "call " __ASM_NAME("UnMapLS") "\n\t" \ "movl $0," #n "(%ebp)\n\t" \ "popl %eax\n\t" \ "ret" )
DEFINE_SUnMapLS(8); DEFINE_SUnMapLS(12); DEFINE_SUnMapLS(16); etc.
I'm removing the semicolons from these last lines. The _ASM_GLOBAL_FUNC needs different semicolon terminators depending on the version being used, so they just carry through.
bye michael