We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 640b5c8 commit 85e294bCopy full SHA for 85e294b
src/types.jl
@@ -351,7 +351,7 @@ function show_term(io::IO, t)
351
352
if i != length(args)
353
if fname == :*
354
- if i == 1 && args[1] isa Number && !paren_scalar
+ if i == 1 && args[1] isa Number && !(args[2] isa Number) && !paren_scalar
355
# skip
356
# do not show * if it's a scalar times something
357
else
test/basics.jl
@@ -101,4 +101,5 @@ end
101
@test repr((2a)^(-2a)) == "(2a)^(-2a)"
102
@test repr(1/2a) == "(1//2)*(a^-1)"
103
@test repr(2/(2*a)) == "a^-1"
104
+ @test repr(Term(*, [1, 1])) == "1*1"
105
end
0 commit comments