How to get a different color for a non existing variable ?

APL-related discussions - a stream of APL consciousness.
Not sure where to start a discussion ? Here's the place to be
Forum rules
This forum is for discussing APL-related issues. If you think that the subject is off-topic, then the Chat forum is probably a better place for your thoughts !

How to get a different color for a non existing variable ?

Postby PGilbert on Sat Jun 26, 2021 10:09 pm

While typing the name of a global variable that does not exist (because it is misspelled or nonexisting) in a function, is it possible to change the color of that variable name to another color so we know that it is misspelled or nonexisting?

I see in the color scheme that there is the color for a global variable but what about a global variable that does not exist? Exist or does not exist seems to be the same color.

Thanks in advance.
User avatar
PGilbert
 
Posts: 436
Joined: Sun Dec 13, 2009 8:46 pm
Location: Montréal, Québec, Canada

Re: How to get a different color for a non existing variable

Postby Phil Last on Sun Jun 27, 2021 10:58 am

Only a guess but it seems most likely that the designer has chosen to lump everything not locally defined or a global function, operator or script together and decided to call them "global variable" rather than "undefined". A matter of taste. If a new type were defined without extending the list being consulted by autocomplete it would probably fall into the same catchall.
User avatar
Phil Last
 
Posts: 624
Joined: Thu Jun 18, 2009 6:29 pm
Location: Wessex

Re: How to get a different color for a non existing variable

Postby PGilbert on Sun Jun 27, 2021 1:45 pm

Thanks Phil for your thoughts. Coming from APL2000 I miss that feature that we had, it is useful when you look at an already written function and the global variable name does not exist anymore, you can catch it right away. The programmer is more productive with such a feature.

Hopefully, we will have it one day with Dyalog also.
User avatar
PGilbert
 
Posts: 436
Joined: Sun Dec 13, 2009 8:46 pm
Location: Montréal, Québec, Canada

Re: How to get a different color for a non existing variable

Postby Vince|Dyalog on Wed Jul 07, 2021 1:20 pm

Hi Pierre,

I have logged your request as RFE 19207.

Regards,

Vince
Vince|Dyalog
 
Posts: 408
Joined: Wed Oct 01, 2008 9:39 am

Re: How to get a different color for a non existing variable

Postby PGilbert on Wed Jul 07, 2021 1:30 pm

Many thanks Vince.
User avatar
PGilbert
 
Posts: 436
Joined: Sun Dec 13, 2009 8:46 pm
Location: Montréal, Québec, Canada

Re: How to get a different color for a non existing variable

Postby ArrayMacNB on Mon Jul 12, 2021 2:21 pm

This color would save the need to glance down at the 'CurObj:' line at the bottom, yes. Given it does not seem to be a big effort to glance down, I am not sure that the savings justify an interpreter change. YMMV (or VMPV?), of course.
ArrayMacNB
 
Posts: 9
Joined: Tue Sep 01, 2020 3:03 pm

Re: How to get a different color for a non existing variable

Postby kai on Mon Jul 12, 2021 5:52 pm

This is about spotting anything undefined with a single glance no matter how many variables there are. CurObj does not help then.

I am strongly in favour of this feature request.
User avatar
kai
 
Posts: 137
Joined: Thu Jun 18, 2009 5:10 pm
Location: Hillesheim / Germany


Return to APL Chat

Who is online

Users browsing this forum: No registered users and 1 guest