The Zig Programming Language 0.1.1 Documentationdeclaration, makes `error.ArgNotFound` available error ArgNotFound; pub fn main() -> %void { // integers const one_plus_one: i32 = 1 + 1; %%io.stdout.printf("1 + 1 = {}\n", one_plus_one); unreachable, and while (true) {} type (none) the type of types error (none) an error code See also: Integers Floats void Errors Primitive Values Name Description true and false bool values null used to undefined; x = 1; assert(x == 1); } $ zig test test.zig Test 1/1 init with undefined...OK Integers Integer Literals const decimal_int = 98222; const hex_int = 0xff; const another_hex_int = 0xFF;0 码力 | 82 页 | 2.67 MB | 1 年前3
The Zig Programming Language 0.2.0 Documentationstd.debug.warn; const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; warn("1 + 1 = {}\n", one_plus_one); // floats unreachable, and while (true) {} type (none) the type of types error (none) an error code See also: Integers Floats void Errors Primitive Values Name Description true and false bool values null used to undefined; x = 1; assert(x == 1); } $ zig test test.zig Test 1/1 init with undefined...OK Integers Integer Literals const decimal_int = 98222; const hex_int = 0xff; const another_hex_int = 0xFF;0 码力 | 117 页 | 2.84 MB | 1 年前3
The Zig Programming Language 0.7.1 Documentation@import("std"); const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; print("1 + 1 = {}\n", .{one_plus_one}); // floats values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier to a signed 7-bit integer. The maximum allowed bit-width of an integer type is 65535. See also: Integers Floats void Errors @Type Primitive Values Name Description true and false bool values null used0 码力 | 225 页 | 5.74 MB | 1 年前3
The Zig Programming Language 0.6.0 Documentation@import("std"); const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; warn("1 + 1 = {}\n", .{one_plus_one}); // floats values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier to a signed 7-bit integer. The maximum allowed bit-width of an integer type is 65535. See also: Integers Floats void Errors @Type Primitive Values Name Description true and false bool values null used0 码力 | 214 页 | 5.37 MB | 1 年前3
The Zig Programming Language 0.5.0 DocumentationLiterals Assignment undefined Variables Global Variables Thread Local Variables Local Variables Integers Integer Literals Runtime Integer Values Floats Float Literals Floating Point Operations Operators @import("std"); const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; warn("1 + 1 = {}\n", one_plus_one); // floats values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier0 码力 | 224 页 | 5.80 MB | 1 年前3
The Zig Programming Language 0.4.0 DocumentationLiterals Assignment undefined Variables Global Variables Thread Local Variables Local Variables Integers Integer Literals Runtime Integer Values Floats Float Literals Floating Point Operations Operators @import("std"); const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; warn("1 + 1 = {}\n", one_plus_one); // floats values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier0 码力 | 207 页 | 5.29 MB | 1 年前3
The Zig Programming Language 0.12.0 Documentation@import("std"); const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; print("1 + 1 = {}\n", .{one_plus_one}); // floats values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier a signed 7- bit integer. The maximum allowed bit-width of an integer type is 65535 . See also: Integers Floats void Errors @Type Primitive Values Primitive Values Name Description true and false0 码力 | 241 页 | 7.37 MB | 1 年前3
The Zig Programming Language 0.8.1 Documentation@import("std"); const os = std.os; const assert = std.debug.assert; pub fn main() void { // integers const one_plus_one: i32 = 1 + 1; print("1 + 1 = {}\n", .{one_plus_one}); // floats values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier to a signed 7-bit integer. The maximum allowed bit-width of an integer type is 65535. See also: Integers Floats void Errors @Type Primitive Values Name Description true and false bool values null used0 码力 | 234 页 | 6.01 MB | 1 年前3
The Zig Programming Language 0.9.1 Documentation@import("std"); 4 const os = std.os; 5 const assert = std.debug.assert; 6 7 pub fn main() void { 8 // integers 9 const one_plus_one: i32 = 1 + 1; 10 print("1 + 1 = {}\n", .{one_plus_one}); 11 12 values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier a signed 7- bit integer. The maximum allowed bit-width of an integer type is 65535 . See also: Integers Floats void Errors @Type Primitive Values Primitive Values Name Description true and false0 码力 | 234 页 | 7.90 MB | 1 年前3
The Zig Programming Language 0.11.0 Documentation@import("std"); 4 const os = std.os; 5 const assert = std.debug.assert; 6 7 pub fn main() void { 8 // integers 9 const one_plus_one: i32 = 1 + 1; 10 print("1 + 1 = {}\n", .{one_plus_one}); 11 12 values. The type of float literals. In addition to the integer types above, arbitrary bit-width integers can be referenced by using an identifier of i or u followed by digits. For example, the identifier a signed 7- bit integer. The maximum allowed bit-width of an integer type is 65535 . See also: Integers Floats void Errors @Type 5.2. Primitive Values Primitive Values Name Description true and false0 码力 | 238 页 | 7.80 MB | 1 年前3
共 1000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 100













