|
View:
New views
6 Messages
—
Rating Filter:
Alert me
|
|
|
SWI-Prolog with C Interface: Debug errorHello!
I have a great problem with SWI Prolog. So I need some help ![]() At first, I opened Visual Studio 2008 Command Prompt and entered: plld -o program.exe source.c source.pl Then two files have appeared: program.exe and program.exe.manifest Then I started program.exe. So, I have error "Unhandled exception at 0x1000c8f0 in program.exe: 0xC0000005" Debugging information: crt0dat.c "pfbegin: 0x00000001 CXX0030 Error expression cannot be evaluated" Where did I make bad a break? ![]() Below I add the code of both files: source.c source.pl |
||
|
|
Re: SWI-Prolog with C Interface: Debug errorOn Sun, 2009-11-01 at 05:19 -0800, Elf_XP wrote:
> Hello! > I have a great problem with SWI Prolog. So I need some help :working: > At first, I opened Visual Studio 2008 Command Prompt and entered: > plld -o program.exe source.c source.pl > Then two files have appeared: program.exe and program.exe.manifest > Then I started program.exe. > So, I have error "Unhandled exception at 0x1000c8f0 in program.exe: > 0xC0000005" > Debugging information: > crt0dat.c > "pfbegin: 0x00000001 CXX0030 Error expression cannot be evaluated" This seems some Windows error. No idea. Maybe something with manifests? In addition though, term_t must be declared locally and must be initialised using PL_new_term_ref() before it can be used. PL_new_term_ref() can only be called after initializing Prolog. In 99% of the cases I see it, embedding Prolog in C/C++/... is not a good idea anyway ... If your really must, you can create an executable from Prolog. If you need something Prolog cannot do, create a DLL/shared object that provides the missing bits. --- Jan > Where did I make bad a break? :confused: > > Below I add the code of both files: > http://old.nabble.com/file/p26148892/source.c source.c > http://old.nabble.com/file/p26148892/source.pl source.pl _______________________________________________ SWI-Prolog mailing list SWI-Prolog@... https://mailbox.iai.uni-bonn.de/mailman/listinfo.cgi/swi-prolog |
||
|
|
Re: SWI-Prolog with C Interface: Debug error2009/11/1 Jan Wielemaker <J.Wielemaker@...>
|
![]() | Gratuite, garantie à vie et déjà utilisée par des millions d'internautes... |
| Free embeddable forum powered by Nabble | Forum Help |