小编bmi*_*itc的帖子

如何在 Python 中记录使用“type”定义的类型别名?

Python 3.12有这样type的说法。如何正确记录类型别名?

我试过:

type Number = int | float
"""Represents a scalar number that is either an integer or float"""
Run Code Online (Sandbox Code Playgroud)

但这似乎没有将文档字符串与别名关联起来。我尝试将文档字符串放在=别名定义之后和之前,但这生成了错误。

python docstring type-hinting type-alias python-3.12

6
推荐指数
0
解决办法
208
查看次数

How do I properly build a .NET 7 application using SkiaSharp on Linux? Getting a segmentation fault when creating GRGlInterface

I have a test application written in F# on .NET 7 that opens a window using GLFW and draws to it using SkiaSharp. This application works on Windows, and now I am testing support on Linux. Right now, I am testing on a fresh install of Linux Mint, but the same exit code described here also happens on Ubuntu through WSL2.

However, my application crashes, and the only response is an exit code of 139, which apparently means there's …

.net opengl f# skia skiasharp

5
推荐指数
0
解决办法
736
查看次数