-
Notifications
You must be signed in to change notification settings - Fork 148
Relax the statement order for symbol/$-variable declarations #296
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
In issue #188 you mention wanting to put |
|
Maybe I just forgot to add On the other hand, if in one module both |
|
Can we simply allow all |
|
Maybe it would not be a problem if we give warnings/errors for inconsistent use of |
|
What is actually inconsistent about using both |
|
Yes, you are right. But this potentially indicates a performance issue (parallel part and no-parallel part in a module mistakenly), which is easily found if one has to write |
|
I think it would be interesting to resurrect this for v5? |
|
Actually, which ordering relaxations should we include in version 5? Do we have consensus? |
|
Certainly the dollar-related moduleoptions were a request at the workshop. What does your code comment mean by "mixed statements"? |
|
My suggestion would be the declarations and moduleoptions only. The declarations should occur in the input before their first use.
In the past (version 1 and 2) also definitions could be anywhere in the module, but would be executed first. That was too confusing. Hence they should still be the first executable statements. The moduleoptions can in principle be anywhere, but the main problem is there, that a later moduleoption may overwrite an earlier one. That may either merit a warning, or be forbidden. Prefer to hear your opinion about that.
… On 20 Jun 2025, at 10:33, Takahiro Ueda ***@***.***> wrote:
tueda
left a comment
(form-dev/form#296)
<#296 (comment)>
Actually, which ordering relaxations should we include in version 5? Do we have consensus?
—
Reply to this email directly, view it on GitHub <#296 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABJPCERVRH25SVTW6YNDMO33EPBORAVCNFSM6AAAAABRK2VHUGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSOJQGI3TGNJSGI>.
You are receiving this because you are subscribed to this thread.
|
|
@jodavies, by "mixed statements", I meant statements with the @vermaseren, you mean all declarations and all moduleoptions are free to be relocated?? Or are exceptions only between declarations and moduleoptions? (But it is not so useful...) |
|
OK, so this means only |
|
Yes. So the question is the purpose of MIXED2. Maybe it was created for these declarations and module options? |
From a forgotten Issue #188. We don't need to follow the FORTRAN style for symbol/$-variable declaration: