-
Notifications
You must be signed in to change notification settings - Fork 161
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
Read lib/transatl.g before reading gap.ini #3010
Read lib/transatl.g before reading gap.ini #3010
Conversation
Currently, if a package is autoloaded from `gap.ini` and uses a name declared in `lib/transatl.g`, then an `unbound global variable` warning is given. Closes gap-system#2828. Closes gap-system#2996.
Can you please edit the issue message to say |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To me this seems very sensible and plausible.
AFAICT, @hulpke originally wrote this code, so he might have additional insights. And perhaps some of the other people who've been around longer, such as @stevelinton @frankluebeck @ThomasBreuer ? |
@fingolfin Ah, sorry, I used |
Oh wait, no, there is no separate notion of closed or resolved. Is it okay how it is @fingolfin? |
The consideration could be that e.g. before calling |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Originally GAP had the convention that US spelling was used.
This bothered some users, who felt that if Stabiliser was good enough for her Majesty, it should be good enough for GAP. transatl.g
simply does this renaming in bulk, rather than add a synonym in each declaration. As it only does so for library declared operations, it is fine to have it be used before reading in gap.ini
.
The only reason I can see for loading it after gap.ini
would be to enforce that packages should use the declared name and not synonyms. I can't see a good reason for doing so, and it would be a fight against windmills in any case.
@wilfwilson it is OK as it is -- I didn't see that you have the |
I have no strong preferences about this topic, but since I have been asked:
|
Thanks @wilfwilson. I agree with you. That said, I am happy to change any "Stabiliser" to "Stabilizer" for the next release of GRAPE. |
I have made this PR as a result of what I think would be the best solution to #2828 and #2996.
Currently,
lib/transatl.g
is read ininit.g
a bit later thangap.ini
. This means that if a package is autoloaded fromgap.ini
and the package uses a name declared inlib/transatl.g
, then anunbound global variable
warning is given. This happens with GRAPE 4.8.1 in particular.This PR moves the reading of
lib/transatl.g
to the point directly before readinggap.ini
.Anyway, I've created this PR as a discussion point. There might be very good reasons for why this is a bad idea; in this case, I will be keen to hear about them!