mirror of
https://codeberg.org/andyscott/ziglings.git
synced 2024-12-22 06:03:09 -05:00
Merge pull request 'Global scope is container-level scope' (#2) from rofrol/ziglings--exercises:rofrol-container-level into main
Reviewed-on: https://codeberg.org/ziglings/exercises/pulls/2
This commit is contained in:
commit
7c50bd1e47
1 changed files with 2 additions and 2 deletions
|
@ -6,7 +6,7 @@
|
||||||
// compile time, and adding the 'comptime' keyword would be
|
// compile time, and adding the 'comptime' keyword would be
|
||||||
// superfluous, redundant, and smelly:
|
// superfluous, redundant, and smelly:
|
||||||
//
|
//
|
||||||
// * The global scope (outside of any function in a source file)
|
// * The container-level scope (outside of any function in a source file)
|
||||||
// * Type declarations of:
|
// * Type declarations of:
|
||||||
// * Variables
|
// * Variables
|
||||||
// * Functions (types of parameters and return values)
|
// * Functions (types of parameters and return values)
|
||||||
|
@ -28,7 +28,7 @@
|
||||||
//
|
//
|
||||||
const print = @import("std").debug.print;
|
const print = @import("std").debug.print;
|
||||||
|
|
||||||
// Being in the global scope, everything about this value is
|
// Being in the container-level scope, everything about this value is
|
||||||
// implicitly required to be known compile time.
|
// implicitly required to be known compile time.
|
||||||
const llama_count = 5;
|
const llama_count = 5;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue