Skip to content
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

improve expression printing #540

Closed
StefanKarpinski opened this issue Mar 7, 2012 · 6 comments
Closed

improve expression printing #540

StefanKarpinski opened this issue Mar 7, 2012 · 6 comments

Comments

@StefanKarpinski
Copy link
Member

Things to improve when printing expressions:

  • print strings quoted
  • print symbols with as :foo if the symbol name is an identifier or as symbol("123") if not
  • don't show line(123)
@JeffBezanson
Copy link
Member

Do you really want :(x+y) printed as +(:x,:y)?

@StefanKarpinski
Copy link
Member Author

No. But we can print :x as :x and :(x+y) as :(+(x,y)).

@JeffBezanson
Copy link
Member

If the result of string(:x) is ":x", I suspect it will cause a world of pain.

@StefanKarpinski
Copy link
Member Author

That's what show is for :-)

@JeffBezanson
Copy link
Member

I believe strings are already printed quoted in expressions. Do you have an example where they aren't?

@StefanKarpinski
Copy link
Member Author

julia> :(x=="foo")
x==foo

JeffBezanson added a commit that referenced this issue Mar 10, 2012
Keno pushed a commit that referenced this issue Oct 9, 2023
* Re-impose "no double lookup" for invoke

This was added in #442 and inadvertently removed in #532.
However, the test in #442 was not stringent enough; the test added here
comes from #535.

Fixes #535
Fixes timholy/Revise.jl#695
ViralBShah pushed a commit that referenced this issue Jun 25, 2024
Stdlib: SparseArrays
URL: https://github.com/JuliaSparse/SparseArrays.jl.git
Stdlib branch: main
Julia branch: master
Old commit: 82b385f
New commit: e61663a
Julia version: 1.12.0-DEV
SparseArrays version: 1.12.0
Bump invoked by: @ViralBShah
Powered by:
[BumpStdlibs.jl](https://github.com/JuliaLang/BumpStdlibs.jl)

Diff:
JuliaSparse/SparseArrays.jl@82b385f...e61663a

```
$ git log --oneline 82b385f..e61663a
e61663a Update to SuiteSparse 7.7 (#545)
4141e8a Update gen/README.md (#544)
45dfe45 Update ci.yml to ot fail if codecov fails (#541)
0888db6 Bump julia-actions/cache from 1 to 2 (#540)
740b82a test: Don't use GPL module when Base.USE_GPL_LIBS=false (#535)
```

Co-authored-by: Dilum Aluthge <[email protected]>
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

No branches or pull requests

2 participants