Skip to content

TraditionalForm is replacing square brackets with parenthesis when it should not #1654

@rocky

Description

@rocky

Description

For the parameters of some boxing functions like SuperscriptBox and SubscriptBox, TraditionalForm uses parentheses when it should use square brackets.

How to Reproduce and Output

In[1]:= SuperscriptBox["x", "2"] //TraditionalForm
Out[1]//TraditionalForm= SuperscriptBox(x, 2)

In[2]:= SuberscriptBox["x", "2"] //TraditionalForm
Out[2]//TraditionalForm= SuberscriptBox(x, 2)

Expected behavior

In[1]:= SuperscriptBox["x", "2"] //TraditionalForm
Out[1]//TraditionalForm= SuperscriptBox[x, 2]

In[2]:= SuberscriptBox["x", "2"] //TraditionalForm
Out[2]//TraditionalForm= SuberscriptBox[x, 2]

Context and Workarounds

This is a recent behavior. The 9.0.0 does not have this behavior. Are there other forms that use parentheses where square brackets shoudl be used?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions