junrushao opened a new pull request, #14452:
URL: https://github.com/apache/tvm/pull/14452

   This PR fixes a bug in TVMScript printer handling tuples on the RHS of an 
assignment, i.e.:
   
   ```python
   ... = (a, b, c)
         ^^^^^^^^^
   ```
   
   The existing  sugar removes the brackets surrounding `(a, b, c)`, which 
makes it slightly more readable as:
   
   ```python
   ... = a, b, c
   ```
   
   However, it overlooks a possibility where the tuple could be empty or has 
only one element, i.e.
   
   ```python
   ... = (a, ) // Case 1: The tuple has only one element
   ... = ()    // Case 2: The tuple is empty
   ```
   
   In both cases, removing brackets may lead to wrong outcome.
   
   This patch fixes this bug.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to