10-20-2023, 05:41 PM
Posts merge if you double post within just a minute or two, as long as no one else has posted after you. It basically treats a double post as an edit to the first post.
"WITH" keyword
|
10-20-2023, 05:41 PM
Posts merge if you double post within just a minute or two, as long as no one else has posted after you. It basically treats a double post as an edit to the first post.
(10-20-2023, 05:41 PM)SMcNeill Wrote: Posts merge if you double post within just a minute or two, as long as no one else has posted after you. It basically treats a double post as an edit to the first post. I was going for a triple maybe later ;-)) Maybe now! With this!!!
b = b + ...
10-20-2023, 09:24 PM
(10-20-2023, 04:18 PM)RhoSigma Wrote: The only thing I've to say about: QB64 is already well on its way of faking other languages. With the sort-of preprocessor it has. That was my proposal. Then it would be the programmer's choice if he/she wants to dress up BASIC like Python or something else. `ALIAS` might have to become `$ALIAS` instead. Otherwise the name is confusing. Another BASIC straight out uses `TYPE` but it's not reasoned as part of preprocessing, which is interesting. (10-19-2023, 07:17 PM)SpriggsySpriggs Wrote: Have there been any thoughts on making a "WITH" keyword for QB64 for assigning values to UDT members? I would not be opposed to WITH, if and only if, the QB64PE IDE included a command to auto-fill in the explicit variable name in a selected code block. Because I personally don't like reading through code inside a WITH - it's easier for my brain to visualize what's happening by seeing the actual variable name. I like Steve's alias suggestion, as long as we don't go crazy with it, and start adding all kinds of complicated things (aliased types, etc.) Just my own personal preference!
10-27-2023, 04:01 PM
Just don't make it so long or shorten it when you are working in a sub or function where the work gets done.
Type areallyridiculosulylongUDTthathasaridiculouslynamedtype_type x as long y as long end type dim thevariabelewithareallyridiculosulylongUDTthathasaridiculouslynamedtype(100) as areallyridiculosulylongUDTthathasaridiculouslynamedtype_type .... addtoX 12, thevariabelewithareallyridiculosulylongUDTthathasaridiculouslynamedtype(i) ... sub addtoX(N as long,v as areallyridiculosulylongUDTthathasaridiculouslynamedtype_type) v.x=v.x+N end sub
10-27-2023, 10:50 PM
(10-27-2023, 04:01 PM)James D Jarvis Wrote: Just don't make it so long or shorten it when you are working in a sub or function where the work gets done.That'll work too! :-D |
« Next Oldest | Next Newest »
|