Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2018-05

"End of source not found" error in Trunk.

11 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Sergey Bodrov

I got annoing "End of source not found" when use autocompletion (Ctrl-Space) on random places of code. After adding/removing empty line in such place, autocompletion works, but over some time error repeats again. What's wrong? It's Codetools bug or some incorrect options setting? I not sure, but maybe that's begins after installing LAMW and laz4android modules from fpcupdeluxe.

*Bodrov Sergey* software development, IT consulting http://www.serbod.com *Phone (Belarus):* +375(25)794-21-58 *Skype:* sergey.bodrov1 *e-mail:* , -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180522/cfe11c8d/attachment.html>

Reply by email

Mattias Gaertner
to Sergey Bodrov
Show quoted text 6 lines
I got annoing "End of source not found" when use autocompletion (Ctrl-Space) on random places of code. After adding/removing empty line in such place, autocompletion works, but over some time error repeats again. What's wrong? It's Codetools bug or some incorrect options setting? I not sure, but maybe that's begins after installing LAMW and laz4android modules from fpcupdeluxe.

Can you reproduce it?

Mattias

Reply by email

Sergey Bodrov
to Mattias Gaertner
Can you reproduce it?

Sure. Windows 10 (x64) under VirtualBox 5.2.6

1. download and run "fpcupdeluxe"
2. install FPC+Lazarus trunk
3. install arm-android crosscompiler
4. start Lazarus, open random project, test autocompletion (Ctrl-Space), it works.
5. run "fpcupdeluxe", install LAMW module
6. start Lazarus, open random project, test autocompletion (Ctrl-Space), it fail with message:
-----------------------------------
Codetools, Errors: 1
mainform.pas(86,4) Error: End of source not found. -----------------------------------

JDK, SDK, NDK, and other Android stuff was not installed, paths not set. But same error present when all paths properly set and project succesfully compiles and run on Android device.

*Bodrov Sergey* software development, IT consulting http://www.serbod.com *Phone (Belarus):* +375(25)794-21-58 *Skype:* sergey.bodrov1 *e-mail:* , -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180523/4ee6f940/attachment.html>

Reply by email

Mattias Gaertner
to Sergey Bodrov
Show quoted text 12 lines
[...] 1. download and run "fpcupdeluxe" 2. install FPC+Lazarus trunk 3. install arm-android crosscompiler 4. start Lazarus, open random project, test autocompletion (Ctrl-Space), it works. 5. run "fpcupdeluxe", install LAMW module 6. start Lazarus, open random project, test autocompletion (Ctrl-Space), it fail with message: ----------------------------------- Codetools, Errors: 1 mainform.pas(86,4) Error: End of source not found.

In any unit?
Even in classes.pp?

Mattias

Reply by email

Sergey Bodrov
to Mattias Gaertner
In any unit? Even in classes.pp?

No, I can't reproduce it inside classes.pp. But it occurs inside one of components code.

*Bodrov Sergey* software development, IT consulting http://www.serbod.com *Phone (Belarus):* +375(25)794-21-58 *Skype:* sergey.bodrov1 *e-mail:* , -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180523/2d967ed3/attachment.html>

Reply by email

Sergey Bodrov
to Mattias Gaertner
Show quoted text 8 lines
> > In any unit? > > Even in classes.pp? > > No, I can't reproduce it inside classes.pp. But it occurs inside one of > components code. Please be more specific.

I installed module "synapse" from fpcupdeluxe, then open my project, that uses "blcksock" unit. Then I open blcksock.pas in editor, go to TUDPBlockSocket.SetMulticastTTL() implementation (line 3730), type "synsock." and press Ctrl-Space for autocompletion. Error occur at line 3720, at last line of previous method implementation.

*Bodrov Sergey* software development, IT consulting http://www.serbod.com *Phone (Belarus):* +375(25)794-21-58 *Skype:* sergey.bodrov1 *e-mail:* , -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180523/64822af1/attachment-0001.html>

Reply by email

Ondrej Pokorny
to Mattias Gaertner: On Tue, 22 May 2018 16:57:19 +0300 Can you reproduce it? Mattias
Mattias Gaertner wrote 10 lines
On Tue, 22 May 2018 16:57:19 +0300 Sergey Bodrov via Lazarus wrote: > I got annoing "End of source not found" when use autocompletion > (Ctrl-Space) on random places of code. After adding/removing empty line in > such place, autocompletion works, but over some time error repeats again. > What's wrong? It's Codetools bug or some incorrect options setting? I not > sure, but maybe that's begins after installing LAMW and laz4android modules > from fpcupdeluxe. Can you reproduce it?

I get this error massively as well after I updated trunk. Closing/reopening the file helps for some time but then the error is back again.

I don't remember it happened before.

Ondrej

Reply by email

Sergey Bodrov
to Mattias Gaertner: On Tue, 22 May 2018 16:57:19 +0300 Can you reproduce it? Mattias
Can you reproduce it?

Upd: after some identifier edited (added-removed single character) pressing Ctrl-Space cause different line number in error message. On repeat, that number is decreased (points to other code block), and after some attempts error not occured. But on next try, error appear again with big line number.

*Bodrov Sergey* software development, IT consulting http://www.serbod.com *Phone (Belarus):* +375(25)794-21-58 *Skype:* sergey.bodrov1 *e-mail:* , -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180531/876f12e0/attachment.html>

Reply by email

LazUser
to Sergey Bodrov

Finally found a work-around for this obnoxious bug. This code-completion bug has appeared in every source file that DID NOT HAVE a "uses" clause in the implementation section. To stop the "end of source not found" simply place a uses clause in the implementation section of the source file and move one of your units in the interface section (that isn't needed in the interface) down to the uses clause in the implementation section. This has worked every time I've encountered this issue. Where is doesn't work however, is in the project source file...probably since it doesn't have an implementation section. Hopefully, this works for the rest of you...and will help others locate and fix the issue...

Reply by email