Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[perl #41637] [PATCH] SMOP; won't compile on MSVC due to declarations not at top of block

6 views
Skip to first unread message

Klaas-Jan Stol

unread,
Feb 28, 2007, 6:39:07 AM2/28/07
to bugs-bi...@rt.perl.org
# New Ticket Created by Klaas-Jan Stol
# Please include the string: [perl #41637]
# in the subject line of all future correspondence about this issue.
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=41637 >


hi,

SMOP_class.pmc and smop_attribute.pmc won't compile on microsoft visual
studio, because some declarations are not at the top of the block (which
is demanded by MSVC, not by gcc).

this patch fixes that. (although I'm still having problems making:

"Compiling with:"
xx.c
cl -I.\include -nologo -GF -W3 -MD -Zi -DNDEBUG -DWIN32 -D_CONSOLE
-DNO_STRICT -DNO_HASH_SEED -DUSE_SITECUSTOMIZE -D_CRT
_SECURE_NO_DEPRECATE -Zi -DHAS_JIT -DI386 -I. -Fo xx.obj -c xx.c
C:\Perl\bin\perl.exe tools\build\pmc2c.pl --dump
src\pmc\smop_class.pmc
C:\Perl\bin\perl.exe tools\build\pmc2c.pl --c src\pmc\smop_class.pmc
C:\Perl\bin\perl.exe tools\build\c2str.pl src\pmc\smop_class.c >
src\pmc\smop_class.str
C:\Perl\bin\perl.exe tools\build\c2str.pl --all
src\string.c
src\pmc\smop_class.c
C:/parrot4/tools/build/../../lib/Parrot/Pmc2c/PMETHODs.pm(433) : warning
C4102: 'name_returns' : unreferenced label
C:/parrot4/tools/build/../../lib/Parrot/Pmc2c/PMETHODs.pm(525) : error
C2275: 'STRING' : illegal use of this type as an
expression
C:\parrot4\include\parrot/string.h(55) : see declaration of 'STRING'
C:/parrot4/tools/build/../../lib/Parrot/Pmc2c/PMETHODs.pm(510) : error
C2059: syntax error : '}'
NMAKE : fatal error U1077: 'C:\Perl\bin\perl.exe' : return code '0x2'

Stop.

==========

So there seems to be something wrong in the PMETHODs.pm file...

regards,
kjs

smop_fixes.patch
0 new messages