【问题标题】:Put arguments on separate lines PyCharm将参数放在单独的行上 PyCharm
【发布时间】:2021-08-14 15:55:16
【问题描述】:

我一直在寻找高低,我似乎无法找到一种方法来启用/在 PyCharm 中创建意图以将函数参数放在单独的行上。

在 MacO 上使用 context action -> Alt + Enter,代码如下

package main

import "fmt"

func sumThree(a int, b int, c int) int {
    return a + b + c
}

func main() {
    sumOfThee := sumThree(1, 2, 3)
    fmt.Println(sumOfThee)
}

我可以在 GoLand 中做到这一点:

但是如何在 PyCharm 中执行相同的操作,即使用Alt + Enter

使用此代码,没有这样的操作:

def sum_three(a: int, b: int, c: int):
    return a + b + c


sum_of_three = sum_three(a=1, b=2, c=3)

我明白了:

我已经搜索了选项,但似乎没有可用于 Python:

【问题讨论】:

    标签: python intellij-idea pycharm


    【解决方案1】:

    PyCharm 中尚不可用,请查看并关注相应问题:PY-45729 加相关部分。

    【讨论】:

      猜你喜欢
      • 2019-01-08
      • 1970-01-01
      • 1970-01-01
      • 2020-02-25
      • 1970-01-01
      • 1970-01-01
      • 2010-11-10
      • 2021-01-28
      • 2018-11-14
      相关资源
      最近更新 更多