It is currently Mon Sep 23, 2019 7:23 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: No Autocomplete - Include in module
PostPosted: Thu Feb 07, 2019 4:55 pm 
Offline
User
User
User avatar

Joined: Wed Mar 15, 2006 1:47 pm
Posts: 62
Location: Munich
Autocomplete does not trigger when an include is used in a module declaration
(Compiling works fine)

Example
Save as include.pbi
Code:
Global Autocompletemeplease.i


Save as main.pb
Code:
Module testAutocomplete
  Declare.i dummy()
EndModule

DeclareModule testAutocomplete
  IncludeFile "include.pbi"
 
  Procedure dummy()
    autocom
  EndProcedure
EndDeclareModule


Type the "p" after "autocom".

Expected behaviour: Autocomplete is offered if options in the preferences are set accordingly.
Observed behaviour: No autocomplete window opens.


Top
 Profile  
Reply with quote  
 Post subject: Re: No Autocomplete - Include in module
PostPosted: Thu Feb 07, 2019 10:51 pm 
Offline
Enthusiast
Enthusiast

Joined: Sat Apr 26, 2003 2:49 pm
Posts: 610
It is by design, the autocomplete does not parse include files, only project files. And inside a module you have to convert the include to module, include it outside the module, add it to the project and 'usemodule' for the autocomplete to trigger.

It was requested among other things to improve modules but not implemented.


Top
 Profile  
Reply with quote  
 Post subject: Re: No Autocomplete - Include in module
PostPosted: Thu Feb 07, 2019 11:04 pm 
Offline
User
User
User avatar

Joined: Wed Mar 15, 2006 1:47 pm
Posts: 62
Location: Munich
The include file is parsed for autocomplete if I place it outside a DeclareModule.

For now I used the workaround of copying the relevant declarations into the Module Header till I have finished writing it.
I cannot convert the include to a module, it contains numerous constant and prototype declarations and no executed code.
Well I could do it, but it would be silly, having a empty DeclareModule body. For now my workaround works too.

This should be an easy fix as includes in normal code work, so I hope it is implemented soon.


Top
 Profile  
Reply with quote  
 Post subject: Re: No Autocomplete - Include in module
PostPosted: Wed Mar 13, 2019 3:34 pm 
Offline
User
User
User avatar

Joined: Wed Mar 15, 2006 1:47 pm
Posts: 62
Location: Munich
Because this currently drives me crazy I am placing a bug bounty of 30€ on this.
Will donate it as soon as I get my hands on a PB version where this works.

Feel free to message me when one is available.


Top
 Profile  
Reply with quote  
 Post subject: Re: No Autocomplete - Include in module
PostPosted: Sun Jul 07, 2019 6:10 am 
Offline
Enthusiast
Enthusiast

Joined: Wed Mar 11, 2009 4:06 pm
Posts: 130
Location: NL
This is a big oversight... autocomplete must parse include files too. Otherwise it becomes quite bothersome to split code in multiple files... We're all used to autocomplete.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye