diff --git a/docs/Snow-Lang-Syntax/Snow-Lang-Grammar-Specification.md.md b/docs/Snow-Lang-Syntax/Snow-Lang-Grammar-Specification.md.md index a60b3fd..a529bf4 100644 --- a/docs/Snow-Lang-Syntax/Snow-Lang-Grammar-Specification.md.md +++ b/docs/Snow-Lang-Syntax/Snow-Lang-Grammar-Specification.md.md @@ -298,14 +298,14 @@ end loop Snow-Lang 支持下列**数值类型**,用于声明变量、参数、结构体字段、函数返回等: -| 类型名 | 关键字 | 位数 | 描述 | -|-------------|----------|-------|-----------------------------| -| byte8 | byte | 8 | 8 位有符号整数 | -| short16 | short | 16 | 16 位有符号整数 | -| int32 | int | 32 | 32 位有符号整数(默认整数类型)| -| long64 | long | 64 | 64 位有符号整数 | -| float32 | float | 32 | 32 位 IEEE-754 浮点数 | -| double64 | double | 64 | 64 位 IEEE-754 浮点数(默认浮点类型)| +| 类型名 | 关键字 | 位数 | 描述 | +|----------|--------|----|---------------------------| +| byte8 | byte | 8 | 8 位有符号整数 | +| short16 | short | 16 | 16 位有符号整数 | +| int32 | int | 32 | 32 位有符号整数(默认整数类型) | +| long64 | long | 64 | 64 位有符号整数 | +| float32 | float | 32 | 32 位 IEEE-754 浮点数 | +| double64 | double | 64 | 64 位 IEEE-754 浮点数(默认浮点类型) | **说明** * 没有无符号整型,所有整型均为有符号。 @@ -317,14 +317,14 @@ Snow-Lang 支持下列**数值类型**,用于声明变量、参数、结构体 为指定具体类型,可在数值字面量后加后缀字母(大小写均可): -| 后缀 | 类型 | 例子 | -|------|-----------|-----------| -| b | byte | 7b, -2B | -| s | short | 123s | -| i | int | 100i | -| l | long | 5l, 123L | -| f | float | 3.14f | -| d | double | 1.0d | +| 后缀 | 类型 | 例子 | +|----|--------|----------| +| b | byte | 7b, -2B | +| s | short | 123s | +| i | int | 100i | +| l | long | 5l, 123L | +| f | float | 3.14f | +| d | double | 1.0d | - 没有后缀的整数字面量自动为 `int`。 - 没有后缀的浮点字面量自动为 `double`。