CKTIS / C#
global: praktična referenca
global: praktična referenca: global:: izbere koren namespace ter obide krajevni alias ali istoimenski tip.
Različica: C# language; verified against C# 14 reference
Sintaksa
global /* grammar-specific form */global:: izbere koren namespace ter obide krajevni alias ali istoimenski tip.
Uporabite v generatorjih in kodi z možnimi spori imen.
Ne pomeni globalnega stanja ali vidnosti public.
global using pomeni nekaj drugega: uvoz velja za celotno prevajanje projekta.
Celoten program dejansko uporabi global; natančno pričakovani stdout je global.
Primeri
using System;
using System.Buffers;
using System.Collections.Concurrent;
using System.Collections.Frozen;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Diagnostics;
using System.Globalization;
using System.IO;
using System.Linq;
using System.Linq.Expressions;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Text;
using System.Text.Json;
using System.Text.Json.Nodes;
using System.Text.Json.Serialization;
using System.Text.RegularExpressions;
using System.Threading;
using System.Threading.Channels;
using System.Threading.Tasks;
using Number = System.Int32;
global::System.Console.WriteLine("global");
Rezultat
global
Celoten program dejansko uporabi `global`; natančno pričakovani stdout je `global`.