github.com/cheshirekow/buildtools@v0.0.0-20200224190056-5d637702fe81/build/testdata/024.in (about)

     1  # Test that single-line calls with no named arguments use the compact form.
     2  # Single-line tuples are also okay.
     3  
     4  str.rewrite(".", "/")
     5  str.rewrite(before=".", after="/")
     6  
     7  x = (1,2,3)
     8  x = (1,'2',-3,[],{},(),not b)
     9  
    10  y = (1, [2])
    11  y = (1, {2: 3})
    12  y = (1, (2, 3))
    13  y = (1, -(a + b))
    14  y = (1, not (a or b))
    15  
    16  x = (
    17      1,
    18      2,
    19      3,
    20  )
    21  
    22  x = (1,2,
    23  3, 4)
    24  
    25  d.get(key, [])
    26  
    27  myfunc(1, 2, foo(x, key = y))
    28  myfunc(
    29    1, 2, foo(x, key = y))
    30  myfunc(1, 2, foo(x, key = y)
    31  )
    32  myfunc(1, 2, foo(x,
    33                   key = y))