Highlighted
Absent Member.
Absent Member.
1357 views

Inline declaration

Very often I've been using code construction like

declare x as type <some_type> = self::GetSomething

That's really cool. But what makes me upset that in this inline declaration the editor doesn't offer possibilitites when the cursor is just behind the

self::

I must remember what I want to write. Or - and that's the key problem - when I even don't know the method or property name and I'm just looking for its name, then first of all I must declare the "x" item separately in local-storage and then I can start finding name of the requested method or name. It looks like the editor doesn't work correctly in that case.

Tags (1)
0 Likes
4 Replies
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Inline declaration

Which product version are you using? I am using 2.3 Update 2 and intellisense does provide me with a list of class names or methods in the declaration.

If I enter

  declare x as type string =

the list does not appear but if I enter a character such as 's' then the list will appear showing all matches. If I don't know what it starts with and I press Ctrl+space then the full list of available classes will appear.

Intellisense always displays a list of available method names after entering the ':' character.

I believe that the behavior you are describing occurred in versions prior to the current version.

Thanks.

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Inline declaration

We are using 2.3 Update 1, so we are downloading Update 2 and we will see if it is the reason.

Thanks

0 Likes
Highlighted
Absent Member.
Absent Member.

RE: Inline declaration

So we downloaded and installed Update 2 but nothing has changed. I do not know if it is neccesary to activate the update by any way ? I do not suppose so but I do not know. I can "live without it" but it is unpleasant.

0 Likes
Highlighted
Micro Focus Expert
Micro Focus Expert

RE: Inline declaration

There are some options that you can set that control how intellisense works within the editor.

Navigate to Tools-->Options-->Text Editor-->Micro Focus COBOL-->Intellisense and check the options that are selected.

If it isn't working the way you think it should be then please open up a support incident and we will research the behavior and RPI it (bug report) if necessary.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.