Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Using periods in sub and function names?
#11
Hi
@TerryRitchie 
I have never used "." out of UDT, but this is  a my limit.

I'm glad to know and learn other ways to code and to create solution for specified problems!

@SMcNeill
this historical view of QB64 is interesting but also scaring in the thought that it is hard to have a complete clear view of QB64 code, a codemap that let correct or modify the code to get new or enpowered functions at sure shot!
Surely my hobbistic or inexpert point of view let you smile, but this is my reaction when I get those hiitorical informations about QB64.
Reply
#12
(02-09-2023, 01:24 PM)CharlieJV Wrote: To me, periods are visual cues that I'm dealing with a variable that is of a compound type.

If I were working with a program with sub/function names that had periods in them, I would be immediately annoyed by the "semantic-meaning-overloading" of the period mark.

BTW:  If you like to use period marks in your identifier names, then you should use period marks in your identifier names.

As if I'm going to turn my nose up when presented with a gift of sample code ...
Reply
#13
(02-09-2023, 03:29 PM)TerryRitchie Wrote: Yes, they do resemble UDTs and that would get confusing to someone viewing the code. I'll stick with either camel case or underscores then.

I agree - let's not try to make things any more confusing!
Reply
#14
I often use periods in variables, such as:

  Color.Code = 14
  Color Color.Code, 0

without any difficulty except when in a udt:

  Type ColorCode
    Code As Integer
  End Type
  Dim ColorStruct As ColorCode
  ColorStruct.Code=14

Erik.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Star Suggestion for new REPLACE$() function zaadstra 3 264 01-26-2026, 05:11 PM
Last Post: grymmjack
  Is there a menu function? Mad Axeman 17 1,125 12-17-2025, 04:43 AM
Last Post: SMcNeill
  error on function returning _mem Herve 5 698 07-05-2025, 08:06 PM
Last Post: hsiangch_ong
Question Can a function return a custom TYPE? 12centuries 3 1,330 06-13-2024, 09:19 PM
Last Post: 12centuries
  SUB & FUNCTION when declaring dynamic library TerryRitchie 9 1,783 06-11-2024, 11:28 AM
Last Post: SpriggsySpriggs

Forum Jump:


Users browsing this thread: 1 Guest(s)