Declaration grouping uses braces rather than parentheses

This commit is contained in:
Ginger Bill
2017-06-13 15:04:23 +01:00
parent 6b464e3558
commit 6a88dc322a
27 changed files with 184 additions and 200 deletions
+4 -4
View File
@@ -1,4 +1,4 @@
const (
const {
RUNE_ERROR = '\ufffd';
RUNE_SELF = 0x80;
RUNE_BOM = 0xfeff;
@@ -28,11 +28,11 @@ const (
// The default lowest and highest continuation byte.
LOCB = 0b1000_0000;
HICB = 0b1011_1111;
)
}
type AcceptRange struct { lo, hi: u8 }
let (
let {
accept_ranges = [5]AcceptRange{
{0x80, 0xbf},
{0xa0, 0xbf},
@@ -60,7 +60,7 @@ let (
0x13, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x03, 0x23, 0x03, 0x03, // 0xe0-0xef
0x34, 0x04, 0x04, 0x04, 0x44, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, 0xf1, // 0xf0-0xff
};
)
}
proc encode_rune(r: rune) -> ([4]u8, int) {
var buf: [4]u8;