Skip to content

Change NAMESPACE_SEPARATOR to . #1169

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

Closed
wants to merge 1 commit into from
Closed

Change NAMESPACE_SEPARATOR to . #1169

wants to merge 1 commit into from

Conversation

YingboMa
Copy link
Member

No description provided.

@YingboMa YingboMa closed this Jun 12, 2024
@YingboMa YingboMa deleted the myb/ns branch June 12, 2024 19:27
@hersle
Copy link
Contributor

hersle commented Feb 24, 2025

What is the state of this? Is it possible to go through with? Is it regarded as breaking, and should wait for MTK v10?

It's a small thing, but everyone who sees my MTK code/plots thinks that a₊b means a+b, so I have to explain it is a namespace separator.

cc @AayushSabharwal @ChrisRackauckas

@AayushSabharwal
Copy link
Member

It is breaking so we can't change it without a breaking release of Symbolics and then one for MTK. The more annoying part of making the namespace separator . is the fact that . isn't a "normal" identifier name in Julia. So for example if you try accessing sys.subsys.foo instead of printing as subsys₊foo it'll print as var"subsys.foo" and I'm still not convinced that that is good user API. If we instead expose a lower level API for getting the "display name" of a variable, we can make that have . instead of and thus have better plots.

@ChrisRackauckas
Copy link
Member

Yes. We can change how we print without changing the internal symbol representation, that's probably a more reasonable solution.

@hersle
Copy link
Contributor

hersle commented Feb 26, 2025

Ok, I see. I agree that we should strive for something better than var"subsys.foo".

Latexified expressions are already shown with ., so I guess doing it also for the plot recipes would only be more consistent as well. I can have a look. Where do the symbolic plot recipes live?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants