NO

Author Topic: Pelles c version 10  (Read 827 times)

Offline risanchez

  • Member
  • *
  • Posts: 5
Pelles c version 10
« on: December 01, 2020, 11:06:43 pm »
In version 10 of Pelles c I can not return a function from within another function, always get this:
fatal error: Internal error: 'Access violation' at 0x00007ff7b3897b6a.

This did not happen in version 9. Also I run my program in Visual Studio and compile and run ok.
Anybody, please kown how to solve this problem, if smobody face the same problem?
Thanks

Offline frankie

  • Global Moderator
  • Member
  • *****
  • Posts: 1789
Re: Pelles c version 10
« Reply #1 on: December 02, 2020, 12:54:00 am »
Not clear what you mean.
The error is from the compiler or from your code?
Post your code, a small sample that shows the problem.
« Last Edit: December 02, 2020, 12:55:54 am by frankie »

Offline Grincheux

  • Member
  • *
  • Posts: 83
  • Never be pleased, always improve
    • Arachne
Re: Pelles c version 10
« Reply #2 on: December 05, 2020, 06:58:38 pm »
I never met this problem.
-------------------------
Kenavo / Bye

Offline MrBcx

  • Global Moderator
  • Member
  • *****
  • Posts: 71
    • Bcx Basic to C/C++ Translator
Re: Pelles c version 10
« Reply #3 on: December 05, 2020, 07:45:08 pm »
In version 10 of Pelles c I can not return a function from within another function, always get this:
fatal error: Internal error: 'Access violation' at 0x00007ff7b3897b6a.

This did not happen in version 9. Also I run my program in Visual Studio and compile and run ok.
Anybody, please kown how to solve this problem, if [somebody] face the same problem?
Thanks

You need to post a small example that demonstrates the error.  Otherwise, it is impossible to know
what problem needs to be solved. 

Offline Grincheux

  • Member
  • *
  • Posts: 83
  • Never be pleased, always improve
    • Arachne
Re: Pelles c version 10
« Reply #4 on: December 05, 2020, 08:27:09 pm »
Is it like this :

Code: [Select]
lstrcpyA(szStringC,lstrcpyA(szStringA,szStringB)) ;
or

Code: [Select]
UpdateWindow(CreateWindowA(szProgramClass,szProgramTitle,
      WS_BORDER|WS_CAPTION|WS_SYSMENU|WS_POPUP,
      0,0,800,400,NULL,NULL,hInstance,NULL)) ;
-------------------------
Kenavo / Bye

Offline John Z

  • Member
  • *
  • Posts: 154
Re: Pelles c version 10
« Reply #5 on: December 05, 2020, 09:17:44 pm »
Hi,

Quite possibly this is related to this bug report:
https://forum.pellesc.de/index.php?topic=9770.msg32753#msg32753

To see if it is, try adding some additional parenthesis like

Code: [Select]
lstrcpyA(szStringC,(lstrcpyA(szStringA,szStringB))) ;

see if that helps. 
Otherwise you need to breakout the internal result into a variable and use that in the function.

John Z

Offline frankie

  • Global Moderator
  • Member
  • *****
  • Posts: 1789