101291 lines
4.6 MiB
101291 lines
4.6 MiB
#define V_COMMIT_HASH "e9aca1256"
|
||
|
||
#ifndef V_COMMIT_HASH
|
||
#define V_COMMIT_HASH "460c2ee77"
|
||
#endif
|
||
|
||
#ifndef V_CURRENT_COMMIT_HASH
|
||
#define V_CURRENT_COMMIT_HASH "e9aca12"
|
||
#endif
|
||
|
||
#define V_USE_SIGNAL_H
|
||
|
||
// V comptime_definitions:
|
||
#define __VTHREADS__ (1)
|
||
#define _VAUTOFREE (0)
|
||
|
||
// V typedefs:
|
||
typedef struct IError IError;
|
||
typedef struct rand__PRNG rand__PRNG;
|
||
typedef struct hash__Hasher hash__Hasher;
|
||
typedef struct hash__Hash32er hash__Hash32er;
|
||
typedef struct hash__Hash64er hash__Hash64er;
|
||
typedef struct v__ast__walker__Visitor v__ast__walker__Visitor;
|
||
typedef struct none none;
|
||
typedef struct v__ast__TypeDecl v__ast__TypeDecl;
|
||
typedef struct v__ast__Expr v__ast__Expr;
|
||
typedef struct v__ast__Stmt v__ast__Stmt;
|
||
typedef struct v__ast__ScopeObject v__ast__ScopeObject;
|
||
typedef struct v__ast__Node v__ast__Node;
|
||
typedef struct v__ast__ComptTimeConstValue v__ast__ComptTimeConstValue;
|
||
typedef struct v__ast__IdentInfo v__ast__IdentInfo;
|
||
typedef struct v__ast__AsmArg v__ast__AsmArg;
|
||
typedef struct v__ast__TypeInfo v__ast__TypeInfo;
|
||
|
||
// BEGIN_multi_return_typedefs
|
||
typedef struct multi_return_u32_u32 multi_return_u32_u32;
|
||
typedef struct multi_return_u32_u32_u32 multi_return_u32_u32_u32;
|
||
typedef struct multi_return_strconv__ParserState_strconv__PrepNumber multi_return_strconv__ParserState_strconv__PrepNumber;
|
||
typedef struct multi_return_u64_int multi_return_u64_int;
|
||
typedef struct multi_return_strconv__Dec32_bool multi_return_strconv__Dec32_bool;
|
||
typedef struct multi_return_strconv__Dec64_bool multi_return_strconv__Dec64_bool;
|
||
typedef struct multi_return_string_int multi_return_string_int;
|
||
typedef struct multi_return_int_bool multi_return_int_bool;
|
||
typedef struct multi_return_int_int multi_return_int_int;
|
||
typedef struct multi_return_ref_v__pref__Preferences_string multi_return_ref_v__pref__Preferences_string;
|
||
typedef struct multi_return_string_string multi_return_string_string;
|
||
typedef struct multi_return_u64_u64 multi_return_u64_u64;
|
||
typedef struct multi_return_f64_int multi_return_f64_int;
|
||
typedef struct multi_return_f64_f64 multi_return_f64_f64;
|
||
typedef struct multi_return_int_int_int multi_return_int_int_int;
|
||
typedef struct multi_return_int_int_int_int_i64_bool multi_return_int_int_int_int_i64_bool;
|
||
typedef struct multi_return_Array_string_int multi_return_Array_string_int;
|
||
typedef struct multi_return_Array_string_v__vmod__ModFileAndFolder multi_return_Array_string_v__vmod__ModFileAndFolder;
|
||
typedef struct multi_return_string_bool multi_return_string_bool;
|
||
typedef struct multi_return_v__ast__Fn_Array_v__ast__Type multi_return_v__ast__Fn_Array_v__ast__Type;
|
||
typedef struct multi_return_v__ast__StructField_Array_v__ast__Type multi_return_v__ast__StructField_Array_v__ast__Type;
|
||
typedef struct multi_return_ref_v__ast__TypeSymbol_int multi_return_ref_v__ast__TypeSymbol_int;
|
||
typedef struct multi_return_bool_bool_int multi_return_bool_bool_int;
|
||
typedef struct multi_return_string_v__token__Pos multi_return_string_v__token__Pos;
|
||
typedef struct multi_return_bool_int_int multi_return_bool_int_int;
|
||
typedef struct multi_return_Array_v__ast__Param_bool_bool multi_return_Array_v__ast__Param_bool_bool;
|
||
typedef struct multi_return_Array_v__ast__Expr_Array_v__ast__Comment multi_return_Array_v__ast__Expr_Array_v__ast__Comment;
|
||
typedef struct multi_return_ref_v__ast__File_Array_v__vet__Error multi_return_ref_v__ast__File_Array_v__vet__Error;
|
||
typedef struct multi_return_Array_v__ast__Type_Array_string multi_return_Array_v__ast__Type_Array_string;
|
||
typedef struct multi_return_Map_string_v__ast__FnDecl_Map_string_v__ast__ConstField_Map_string_v__ast__GlobalField multi_return_Map_string_v__ast__FnDecl_Map_string_v__ast__ConstField_Map_string_v__ast__GlobalField;
|
||
typedef struct multi_return_bool_Array_string multi_return_bool_Array_string;
|
||
typedef struct multi_return_Array_string_Array_string_Array_string multi_return_Array_string_Array_string_Array_string;
|
||
typedef struct multi_return_string_string_string_string multi_return_string_string_string_string;
|
||
typedef struct multi_return_int_string_string_string multi_return_int_string_string_string;
|
||
typedef struct multi_return_Array_string_Array_string_Array_bool multi_return_Array_string_Array_string_Array_bool;
|
||
typedef struct multi_return_u64_string multi_return_u64_string;
|
||
// END_multi_return_typedefs
|
||
|
||
typedef struct strconv__BF_param strconv__BF_param;
|
||
typedef struct strconv__PrepNumber strconv__PrepNumber;
|
||
typedef struct strconv__Dec32 strconv__Dec32;
|
||
typedef struct strconv__Dec64 strconv__Dec64;
|
||
typedef struct strconv__Uint128 strconv__Uint128;
|
||
typedef union strconv__Uf32 strconv__Uf32;
|
||
typedef union strconv__Uf64 strconv__Uf64;
|
||
typedef union strconv__Float64u strconv__Float64u;
|
||
typedef union strconv__Float32u strconv__Float32u;
|
||
typedef struct array array;
|
||
typedef struct VCastTypeIndexName VCastTypeIndexName;
|
||
typedef struct VAssertMetaInfo VAssertMetaInfo;
|
||
typedef struct MethodArgs MethodArgs;
|
||
typedef struct FunctionData FunctionData;
|
||
typedef struct FieldData FieldData;
|
||
typedef struct StructAttribute StructAttribute;
|
||
typedef struct DenseArray DenseArray;
|
||
typedef struct map map;
|
||
typedef struct Error Error;
|
||
typedef struct MessageError MessageError;
|
||
typedef struct None__ None__;
|
||
typedef struct Option Option;
|
||
typedef struct _option _option;
|
||
typedef struct _result _result;
|
||
typedef struct VMemoryBlock VMemoryBlock;
|
||
typedef struct SortedMap SortedMap;
|
||
typedef struct mapnode mapnode;
|
||
typedef struct string string;
|
||
typedef struct RepIndex RepIndex;
|
||
typedef union StrIntpMem StrIntpMem;
|
||
typedef struct StrIntpCgenData StrIntpCgenData;
|
||
typedef struct StrIntpData StrIntpData;
|
||
typedef struct strings__textscanner__TextScanner strings__textscanner__TextScanner;
|
||
typedef struct v__token__KeywordsMatcher v__token__KeywordsMatcher;
|
||
typedef struct v__token__WIndex v__token__WIndex;
|
||
typedef struct v__token__Pos v__token__Pos;
|
||
typedef struct v__token__Token v__token__Token;
|
||
typedef struct time__TimeParseError time__TimeParseError;
|
||
typedef struct time__StopWatchOptions time__StopWatchOptions;
|
||
typedef struct time__StopWatch time__StopWatch;
|
||
typedef struct time__Time time__Time;
|
||
typedef struct v__dotgraph__DotGraph v__dotgraph__DotGraph;
|
||
typedef struct v__dotgraph__NewNodeConfig v__dotgraph__NewNodeConfig;
|
||
typedef struct v__dotgraph__NewEdgeConfig v__dotgraph__NewEdgeConfig;
|
||
typedef struct rand__buffer__PRNGBuffer rand__buffer__PRNGBuffer;
|
||
typedef struct flag__Flag flag__Flag;
|
||
typedef struct flag__UnkownFlagError flag__UnkownFlagError;
|
||
typedef struct flag__ArgsCountError flag__ArgsCountError;
|
||
typedef struct flag__FlagParser flag__FlagParser;
|
||
typedef struct semver__RawVersion semver__RawVersion;
|
||
typedef struct semver__Comparator semver__Comparator;
|
||
typedef struct semver__ComparatorSet semver__ComparatorSet;
|
||
typedef struct semver__Range semver__Range;
|
||
typedef struct semver__InvalidComparatorFormatError semver__InvalidComparatorFormatError;
|
||
typedef struct semver__Version semver__Version;
|
||
typedef struct semver__EmptyInputError semver__EmptyInputError;
|
||
typedef struct semver__InvalidVersionFormatError semver__InvalidVersionFormatError;
|
||
typedef struct os__File os__File;
|
||
typedef struct os__FileInfo os__FileInfo;
|
||
typedef struct os__FileNotOpenedError os__FileNotOpenedError;
|
||
typedef struct os__SizeOfTypeIs0Error os__SizeOfTypeIs0Error;
|
||
typedef struct os__FilePermission os__FilePermission;
|
||
typedef struct os__FileMode os__FileMode;
|
||
typedef struct os__Result os__Result;
|
||
typedef struct os__Command os__Command;
|
||
typedef struct os__ExecutableNotFoundError os__ExecutableNotFoundError;
|
||
typedef struct os__Uname os__Uname;
|
||
typedef struct os__Process os__Process;
|
||
typedef struct v__errors__Error v__errors__Error;
|
||
typedef struct v__errors__Warning v__errors__Warning;
|
||
typedef struct v__errors__Notice v__errors__Notice;
|
||
typedef struct v__depgraph__DepGraphNode v__depgraph__DepGraphNode;
|
||
typedef struct v__depgraph__DepGraph v__depgraph__DepGraph;
|
||
typedef struct v__depgraph__OrderedDepMap v__depgraph__OrderedDepMap;
|
||
typedef struct v__depgraph__NodeNames v__depgraph__NodeNames;
|
||
typedef struct v__vet__Error v__vet__Error;
|
||
typedef struct term__Coord term__Coord;
|
||
typedef struct v__vcache__CacheManager v__vcache__CacheManager;
|
||
typedef struct v__vmod__Manifest v__vmod__Manifest;
|
||
typedef struct v__vmod__Scanner v__vmod__Scanner;
|
||
typedef struct v__vmod__Parser v__vmod__Parser;
|
||
typedef struct v__vmod__Token v__vmod__Token;
|
||
typedef struct v__vmod__ModFileAndFolder v__vmod__ModFileAndFolder;
|
||
typedef struct v__vmod__ModFileCacher v__vmod__ModFileCacher;
|
||
typedef struct v__cflag__CFlag v__cflag__CFlag;
|
||
typedef struct rand__config__PRNGConfigStruct rand__config__PRNGConfigStruct;
|
||
typedef struct rand__config__NormalConfigStruct rand__config__NormalConfigStruct;
|
||
typedef struct rand__config__ShuffleConfigStruct rand__config__ShuffleConfigStruct;
|
||
typedef struct rand__wyrand__WyRandRNG rand__wyrand__WyRandRNG;
|
||
typedef struct v__pkgconfig__Main v__pkgconfig__Main;
|
||
typedef struct v__pkgconfig__MainOptions v__pkgconfig__MainOptions;
|
||
typedef struct v__pkgconfig__Options v__pkgconfig__Options;
|
||
typedef struct v__pkgconfig__PkgConfig v__pkgconfig__PkgConfig;
|
||
typedef struct v__pref__Preferences v__pref__Preferences;
|
||
typedef struct sync__Subscription sync__Subscription;
|
||
typedef struct sync__Channel sync__Channel;
|
||
typedef struct sync__ManyTimes sync__ManyTimes;
|
||
typedef struct sync__Once sync__Once;
|
||
typedef struct sync__WaitGroup sync__WaitGroup;
|
||
typedef struct sync__Mutex sync__Mutex;
|
||
typedef struct sync__RwMutex sync__RwMutex;
|
||
typedef struct sync__RwMutexAttr sync__RwMutexAttr;
|
||
typedef struct sync__Semaphore sync__Semaphore;
|
||
typedef struct v__util__EManager v__util__EManager;
|
||
typedef struct v__util__LinesCache v__util__LinesCache;
|
||
typedef struct v__util__Possibility v__util__Possibility;
|
||
typedef struct v__util__Suggestion v__util__Suggestion;
|
||
typedef struct v__util__Surrounder v__util__Surrounder;
|
||
typedef struct v__util__Timers v__util__Timers;
|
||
typedef struct v__util__TimerParams v__util__TimerParams;
|
||
typedef struct v__util__SourceCache v__util__SourceCache;
|
||
typedef struct sync__pool__PoolProcessor sync__pool__PoolProcessor;
|
||
typedef struct sync__pool__PoolProcessorConfig sync__pool__PoolProcessorConfig;
|
||
typedef struct v__ast__TypeNode v__ast__TypeNode;
|
||
typedef struct v__ast__ComptimeType v__ast__ComptimeType;
|
||
typedef struct v__ast__EmptyExpr v__ast__EmptyExpr;
|
||
typedef struct v__ast__EmptyStmt v__ast__EmptyStmt;
|
||
typedef struct v__ast__EmptyNode v__ast__EmptyNode;
|
||
typedef struct v__ast__Block v__ast__Block;
|
||
typedef struct v__ast__ExprStmt v__ast__ExprStmt;
|
||
typedef struct v__ast__IntegerLiteral v__ast__IntegerLiteral;
|
||
typedef struct v__ast__FloatLiteral v__ast__FloatLiteral;
|
||
typedef struct v__ast__StringLiteral v__ast__StringLiteral;
|
||
typedef struct v__ast__StringInterLiteral v__ast__StringInterLiteral;
|
||
typedef struct v__ast__CharLiteral v__ast__CharLiteral;
|
||
typedef struct v__ast__BoolLiteral v__ast__BoolLiteral;
|
||
typedef struct v__ast__SelectorExpr v__ast__SelectorExpr;
|
||
typedef struct v__ast__Module v__ast__Module;
|
||
typedef struct v__ast__StructField v__ast__StructField;
|
||
typedef struct v__ast__ConstField v__ast__ConstField;
|
||
typedef struct v__ast__ConstDecl v__ast__ConstDecl;
|
||
typedef struct v__ast__StructDecl v__ast__StructDecl;
|
||
typedef struct v__ast__Embed v__ast__Embed;
|
||
typedef struct v__ast__InterfaceEmbedding v__ast__InterfaceEmbedding;
|
||
typedef struct v__ast__InterfaceDecl v__ast__InterfaceDecl;
|
||
typedef struct v__ast__StructInitField v__ast__StructInitField;
|
||
typedef struct v__ast__StructInitEmbed v__ast__StructInitEmbed;
|
||
typedef struct v__ast__StructInit v__ast__StructInit;
|
||
typedef struct v__ast__Import v__ast__Import;
|
||
typedef struct v__ast__ImportSymbol v__ast__ImportSymbol;
|
||
typedef struct v__ast__AnonFn v__ast__AnonFn;
|
||
typedef struct v__ast__FnDecl v__ast__FnDecl;
|
||
typedef struct v__ast__BranchStmt v__ast__BranchStmt;
|
||
typedef struct v__ast__CallExpr v__ast__CallExpr;
|
||
typedef struct v__ast__CallArg v__ast__CallArg;
|
||
typedef struct v__ast__Return v__ast__Return;
|
||
typedef struct v__ast__Var v__ast__Var;
|
||
typedef struct v__ast__ScopeStructField v__ast__ScopeStructField;
|
||
typedef struct v__ast__GlobalField v__ast__GlobalField;
|
||
typedef struct v__ast__GlobalDecl v__ast__GlobalDecl;
|
||
typedef struct v__ast__EmbeddedFile v__ast__EmbeddedFile;
|
||
typedef struct v__ast__File v__ast__File;
|
||
typedef struct v__ast__IdentFn v__ast__IdentFn;
|
||
typedef struct v__ast__IdentVar v__ast__IdentVar;
|
||
typedef struct v__ast__Ident v__ast__Ident;
|
||
typedef struct v__ast__InfixExpr v__ast__InfixExpr;
|
||
typedef struct v__ast__PostfixExpr v__ast__PostfixExpr;
|
||
typedef struct v__ast__PrefixExpr v__ast__PrefixExpr;
|
||
typedef struct v__ast__IndexExpr v__ast__IndexExpr;
|
||
typedef struct v__ast__IfExpr v__ast__IfExpr;
|
||
typedef struct v__ast__IfBranch v__ast__IfBranch;
|
||
typedef struct v__ast__UnsafeExpr v__ast__UnsafeExpr;
|
||
typedef struct v__ast__LockExpr v__ast__LockExpr;
|
||
typedef struct v__ast__MatchExpr v__ast__MatchExpr;
|
||
typedef struct v__ast__MatchBranch v__ast__MatchBranch;
|
||
typedef struct v__ast__SelectExpr v__ast__SelectExpr;
|
||
typedef struct v__ast__SelectBranch v__ast__SelectBranch;
|
||
typedef struct v__ast__ComptimeFor v__ast__ComptimeFor;
|
||
typedef struct v__ast__ForStmt v__ast__ForStmt;
|
||
typedef struct v__ast__ForInStmt v__ast__ForInStmt;
|
||
typedef struct v__ast__ForCStmt v__ast__ForCStmt;
|
||
typedef struct v__ast__HashStmt v__ast__HashStmt;
|
||
typedef struct v__ast__AssignStmt v__ast__AssignStmt;
|
||
typedef struct v__ast__AsCast v__ast__AsCast;
|
||
typedef struct v__ast__EnumVal v__ast__EnumVal;
|
||
typedef struct v__ast__EnumField v__ast__EnumField;
|
||
typedef struct v__ast__EnumDecl v__ast__EnumDecl;
|
||
typedef struct v__ast__AliasTypeDecl v__ast__AliasTypeDecl;
|
||
typedef struct v__ast__SumTypeDecl v__ast__SumTypeDecl;
|
||
typedef struct v__ast__FnTypeDecl v__ast__FnTypeDecl;
|
||
typedef struct v__ast__DeferStmt v__ast__DeferStmt;
|
||
typedef struct v__ast__ParExpr v__ast__ParExpr;
|
||
typedef struct v__ast__GoExpr v__ast__GoExpr;
|
||
typedef struct v__ast__GotoLabel v__ast__GotoLabel;
|
||
typedef struct v__ast__GotoStmt v__ast__GotoStmt;
|
||
typedef struct v__ast__ArrayInit v__ast__ArrayInit;
|
||
typedef struct v__ast__ArrayDecompose v__ast__ArrayDecompose;
|
||
typedef struct v__ast__ChanInit v__ast__ChanInit;
|
||
typedef struct v__ast__MapInit v__ast__MapInit;
|
||
typedef struct v__ast__RangeExpr v__ast__RangeExpr;
|
||
typedef struct v__ast__CastExpr v__ast__CastExpr;
|
||
typedef struct v__ast__AsmStmt v__ast__AsmStmt;
|
||
typedef struct v__ast__AsmTemplate v__ast__AsmTemplate;
|
||
typedef struct v__ast__AsmRegister v__ast__AsmRegister;
|
||
typedef struct v__ast__AsmDisp v__ast__AsmDisp;
|
||
typedef struct v__ast__AsmAlias v__ast__AsmAlias;
|
||
typedef struct v__ast__AsmAddressing v__ast__AsmAddressing;
|
||
typedef struct v__ast__AsmClobbered v__ast__AsmClobbered;
|
||
typedef struct v__ast__AsmIO v__ast__AsmIO;
|
||
typedef struct v__ast__AssertStmt v__ast__AssertStmt;
|
||
typedef struct v__ast__IfGuardVar v__ast__IfGuardVar;
|
||
typedef struct v__ast__IfGuardExpr v__ast__IfGuardExpr;
|
||
typedef struct v__ast__OrExpr v__ast__OrExpr;
|
||
typedef struct v__ast__Assoc v__ast__Assoc;
|
||
typedef struct v__ast__SizeOf v__ast__SizeOf;
|
||
typedef struct v__ast__IsRefType v__ast__IsRefType;
|
||
typedef struct v__ast__OffsetOf v__ast__OffsetOf;
|
||
typedef struct v__ast__Likely v__ast__Likely;
|
||
typedef struct v__ast__TypeOf v__ast__TypeOf;
|
||
typedef struct v__ast__DumpExpr v__ast__DumpExpr;
|
||
typedef struct v__ast__Comment v__ast__Comment;
|
||
typedef struct v__ast__ConcatExpr v__ast__ConcatExpr;
|
||
typedef struct v__ast__AtExpr v__ast__AtExpr;
|
||
typedef struct v__ast__ComptimeSelector v__ast__ComptimeSelector;
|
||
typedef struct v__ast__ComptimeCall v__ast__ComptimeCall;
|
||
typedef struct v__ast__None v__ast__None;
|
||
typedef struct v__ast__SqlStmt v__ast__SqlStmt;
|
||
typedef struct v__ast__SqlStmtLine v__ast__SqlStmtLine;
|
||
typedef struct v__ast__SqlExpr v__ast__SqlExpr;
|
||
typedef struct v__ast__NodeError v__ast__NodeError;
|
||
typedef struct v__ast__CTempVar v__ast__CTempVar;
|
||
typedef struct v__ast__Attr v__ast__Attr;
|
||
typedef struct v__ast__Scope v__ast__Scope;
|
||
typedef struct v__ast__Table v__ast__Table;
|
||
typedef struct v__ast__Fn v__ast__Fn;
|
||
typedef struct v__ast__Param v__ast__Param;
|
||
typedef struct v__ast__GetEmbedsOptions v__ast__GetEmbedsOptions;
|
||
typedef struct v__ast__TypeSymbol v__ast__TypeSymbol;
|
||
typedef struct v__ast__MultiReturn v__ast__MultiReturn;
|
||
typedef struct v__ast__FnType v__ast__FnType;
|
||
typedef struct v__ast__Struct v__ast__Struct;
|
||
typedef struct v__ast__GenericInst v__ast__GenericInst;
|
||
typedef struct v__ast__Interface v__ast__Interface;
|
||
typedef struct v__ast__Enum v__ast__Enum;
|
||
typedef struct v__ast__Alias v__ast__Alias;
|
||
typedef struct v__ast__Aggregate v__ast__Aggregate;
|
||
typedef struct v__ast__Array v__ast__Array;
|
||
typedef struct v__ast__ArrayFixed v__ast__ArrayFixed;
|
||
typedef struct v__ast__Chan v__ast__Chan;
|
||
typedef struct v__ast__Thread v__ast__Thread;
|
||
typedef struct v__ast__Map v__ast__Map;
|
||
typedef struct v__ast__SumType v__ast__SumType;
|
||
typedef struct v__ast__FnSignatureOpts v__ast__FnSignatureOpts;
|
||
typedef struct v__checker__Checker v__checker__Checker;
|
||
typedef struct v__transformer__KeyVal v__transformer__KeyVal;
|
||
typedef struct v__transformer__IndexState v__transformer__IndexState;
|
||
typedef struct v__transformer__Transformer v__transformer__Transformer;
|
||
typedef struct v__markused__Walker v__markused__Walker;
|
||
typedef struct v__gen__c__UnsupportedAssertCtempTransform v__gen__c__UnsupportedAssertCtempTransform;
|
||
typedef struct v__gen__c__StrType v__gen__c__StrType;
|
||
typedef struct v__gen__c__Gen v__gen__c__Gen;
|
||
typedef struct v__gen__c__GlobalConstDef v__gen__c__GlobalConstDef;
|
||
typedef struct v__gen__c__SumtypeCastingFn v__gen__c__SumtypeCastingFn;
|
||
typedef struct v__gen__c__GenSafeIntegerCfg v__gen__c__GenSafeIntegerCfg;
|
||
typedef struct v__gen__c__ProfileCounterMeta v__gen__c__ProfileCounterMeta;
|
||
typedef struct v__gen__c__Type v__gen__c__Type;
|
||
typedef struct v__scanner__Scanner v__scanner__Scanner;
|
||
typedef struct v__ast__walker__Inspector v__ast__walker__Inspector;
|
||
typedef struct v__parser__ReceiverParsingInfo v__parser__ReceiverParsingInfo;
|
||
typedef struct v__parser__Parser v__parser__Parser;
|
||
typedef struct v__parser__EatCommentsConfig v__parser__EatCommentsConfig;
|
||
typedef struct v__callgraph__Mapper v__callgraph__Mapper;
|
||
typedef struct v__builder__Builder v__builder__Builder;
|
||
typedef struct v__builder__FunctionRedefinition v__builder__FunctionRedefinition;
|
||
typedef struct v__builder__CcompilerOptions v__builder__CcompilerOptions;
|
||
typedef struct v__builder__MsvcResult v__builder__MsvcResult;
|
||
typedef struct v__builder__WindowsKit v__builder__WindowsKit;
|
||
typedef struct v__builder__VsInstallation v__builder__VsInstallation;
|
||
typedef struct v__builder__MsvcStringFlags v__builder__MsvcStringFlags;
|
||
typedef struct _option_int _option_int;
|
||
typedef struct _option_f64 _option_f64;
|
||
typedef struct _option_u64 _option_u64;
|
||
typedef struct _option_i64 _option_i64;
|
||
typedef struct _option_rune _option_rune;
|
||
typedef struct _option_string _option_string;
|
||
typedef struct _option_u8 _option_u8;
|
||
typedef struct _option_v__token__Kind _option_v__token__Kind;
|
||
typedef struct _option_time__Time _option_time__Time;
|
||
typedef struct _option_multi_return_int_int_int _option_multi_return_int_int_int;
|
||
typedef struct _option_multi_return_int_int_int_int_i64_bool _option_multi_return_int_int_int_int_i64_bool;
|
||
typedef struct _option_bool _option_bool;
|
||
typedef struct _option_void _option_void;
|
||
typedef struct _option_flag__Flag _option_flag__Flag;
|
||
typedef struct _option_Array_string _option_Array_string;
|
||
typedef struct _option_semver__Range _option_semver__Range;
|
||
typedef struct _option_semver__Version _option_semver__Version;
|
||
typedef struct _option_semver__ComparatorSet _option_semver__ComparatorSet;
|
||
typedef struct _option_semver__Comparator _option_semver__Comparator;
|
||
typedef struct _option_os__File _option_os__File;
|
||
typedef struct _option_FILE_ptr _option_FILE_ptr;
|
||
typedef struct _option_Array_u8 _option_Array_u8;
|
||
typedef struct _option_os__SignalHandler _option_os__SignalHandler;
|
||
typedef struct _option_term__Coord _option_term__Coord;
|
||
typedef struct _option_v__vmod__Manifest _option_v__vmod__Manifest;
|
||
typedef struct _option_multi_return_Array_string_int _option_multi_return_Array_string_int;
|
||
typedef struct _option_v__pkgconfig__PkgConfig_ptr _option_v__pkgconfig__PkgConfig_ptr;
|
||
typedef struct _option_v__pkgconfig__Main_ptr _option_v__pkgconfig__Main_ptr;
|
||
typedef struct _option_u32 _option_u32;
|
||
typedef struct _option_f32 _option_f32;
|
||
typedef struct _option_multi_return_f64_f64 _option_multi_return_f64_f64;
|
||
typedef struct _option_v__pref__OS _option_v__pref__OS;
|
||
typedef struct _option_v__pref__Arch _option_v__pref__Arch;
|
||
typedef struct _option_v__pref__Backend _option_v__pref__Backend;
|
||
typedef struct _option_time__StopWatch _option_time__StopWatch;
|
||
typedef struct _option_v__ast__Ident _option_v__ast__Ident;
|
||
typedef struct _option_v__ast__Attr _option_v__ast__Attr;
|
||
typedef struct _option_i8 _option_i8;
|
||
typedef struct _option_i16 _option_i16;
|
||
typedef struct _option_u16 _option_u16;
|
||
typedef struct _option_v__ast__ComptTimeConstValue _option_v__ast__ComptTimeConstValue;
|
||
typedef struct _option_v__ast__ScopeObject _option_v__ast__ScopeObject;
|
||
typedef struct _option_v__ast__ScopeStructField _option_v__ast__ScopeStructField;
|
||
typedef struct _option_v__ast__Var_ptr _option_v__ast__Var_ptr;
|
||
typedef struct _option_v__ast__GlobalField_ptr _option_v__ast__GlobalField_ptr;
|
||
typedef struct _option_v__ast__ConstField_ptr _option_v__ast__ConstField_ptr;
|
||
typedef struct _option_v__ast__Fn _option_v__ast__Fn;
|
||
typedef struct _option_multi_return_v__ast__Fn_Array_v__ast__Type _option_multi_return_v__ast__Fn_Array_v__ast__Type;
|
||
typedef struct _option_v__ast__StructField _option_v__ast__StructField;
|
||
typedef struct _option_multi_return_v__ast__StructField_Array_v__ast__Type _option_multi_return_v__ast__StructField_Array_v__ast__Type;
|
||
typedef struct _option_v__ast__TypeSymbol_ptr _option_v__ast__TypeSymbol_ptr;
|
||
typedef struct _option_Array_Array_v__ast__Type _option_Array_Array_v__ast__Type;
|
||
typedef struct _option_v__ast__Type _option_v__ast__Type;
|
||
typedef struct _option_v__ast__InterfaceDecl _option_v__ast__InterfaceDecl;
|
||
typedef struct _option_v__ast__EnumDecl _option_v__ast__EnumDecl;
|
||
typedef struct _option_v__ast__Expr _option_v__ast__Expr;
|
||
typedef struct _option_v__ast__Param _option_v__ast__Param;
|
||
typedef struct _option_Array_v__ast__Type _option_Array_v__ast__Type;
|
||
typedef struct _option_v__ast__ConstField _option_v__ast__ConstField;
|
||
typedef struct _option_v__ast__GlobalField _option_v__ast__GlobalField;
|
||
typedef struct _option_v__ast__FnDecl _option_v__ast__FnDecl;
|
||
typedef struct _option_v__gen__c__GlobalConstDef _option_v__gen__c__GlobalConstDef;
|
||
typedef struct _option_v__ast__Stmt_ptr _option_v__ast__Stmt_ptr;
|
||
typedef struct _option_v__scanner__Scanner_ptr _option_v__scanner__Scanner_ptr;
|
||
typedef struct _option_v__builder__MsvcResult _option_v__builder__MsvcResult;
|
||
typedef struct _option_v__builder__WindowsKit _option_v__builder__WindowsKit;
|
||
typedef struct _option_v__builder__VsInstallation _option_v__builder__VsInstallation;
|
||
typedef struct __shared__Array_string __shared__Array_string;
|
||
typedef struct __shared__Map_string_bool __shared__Map_string_bool;
|
||
|
||
// V cheaders:
|
||
// Generated by the V compiler
|
||
|
||
#if defined(__TINYC__) && defined(__has_include)
|
||
// tcc does not support has_include properly yet, turn it off completely
|
||
#undef __has_include
|
||
#endif
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<inttypes.h>)
|
||
#include <inttypes.h>
|
||
#else
|
||
#error VERROR_MESSAGE The C compiler can not find <inttypes.h>. Please install build-essentials
|
||
#endif
|
||
|
||
#else
|
||
#include <inttypes.h>
|
||
#endif
|
||
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<stddef.h>)
|
||
#include <stddef.h>
|
||
#else
|
||
#error VERROR_MESSAGE The C compiler can not find <stddef.h>. Please install build-essentials
|
||
#endif
|
||
|
||
#else
|
||
#include <stddef.h>
|
||
#endif
|
||
|
||
|
||
//================================== builtin types ================================*/
|
||
typedef int64_t i64;
|
||
typedef int16_t i16;
|
||
typedef int8_t i8;
|
||
typedef uint64_t u64;
|
||
typedef uint32_t u32;
|
||
typedef uint8_t u8;
|
||
typedef uint16_t u16;
|
||
//typedef uint8_t byte;
|
||
typedef uint32_t rune;
|
||
typedef size_t usize;
|
||
typedef ptrdiff_t isize;
|
||
#ifndef VNOFLOAT
|
||
typedef float f32;
|
||
typedef double f64;
|
||
#else
|
||
typedef int32_t f32;
|
||
typedef int64_t f64;
|
||
#endif
|
||
typedef int64_t int_literal;
|
||
#ifndef VNOFLOAT
|
||
typedef double float_literal;
|
||
#else
|
||
typedef int64_t float_literal;
|
||
#endif
|
||
typedef unsigned char* byteptr;
|
||
typedef void* voidptr;
|
||
typedef char* charptr;
|
||
typedef u8 array_fixed_byte_300 [300];
|
||
|
||
typedef struct sync__Channel* chan;
|
||
|
||
#ifndef __cplusplus
|
||
#ifndef bool
|
||
#ifdef CUSTOM_DEFINE_4bytebool
|
||
typedef int bool;
|
||
#else
|
||
typedef u8 bool;
|
||
#endif
|
||
#define true 1
|
||
#define false 0
|
||
#endif
|
||
#endif
|
||
|
||
typedef u64 (*MapHashFn)(voidptr);
|
||
typedef bool (*MapEqFn)(voidptr, voidptr);
|
||
typedef void (*MapCloneFn)(voidptr, voidptr);
|
||
typedef void (*MapFreeFn)(voidptr);
|
||
|
||
//============================== HELPER C MACROS =============================*/
|
||
// _SLIT0 is used as NULL string for literal arguments
|
||
// `"" s` is used to enforce a string literal argument
|
||
#define _SLIT0 (string){.str=(byteptr)(""), .len=0, .is_lit=1}
|
||
#define _SLIT(s) ((string){.str=(byteptr)("" s), .len=(sizeof(s)-1), .is_lit=1})
|
||
#define _SLEN(s, n) ((string){.str=(byteptr)("" s), .len=n, .is_lit=1})
|
||
|
||
// take the address of an rvalue
|
||
#define ADDR(type, expr) (&((type[]){expr}[0]))
|
||
|
||
// copy something to the heap
|
||
#define HEAP(type, expr) ((type*)memdup((void*)&((type[]){expr}[0]), sizeof(type)))
|
||
#define HEAP_noscan(type, expr) ((type*)memdup_noscan((void*)&((type[]){expr}[0]), sizeof(type)))
|
||
|
||
#define _PUSH_MANY(arr, val, tmp, tmp_typ) {tmp_typ tmp = (val); array_push_many(arr, tmp.data, tmp.len);}
|
||
#define _PUSH_MANY_noscan(arr, val, tmp, tmp_typ) {tmp_typ tmp = (val); array_push_many_noscan(arr, tmp.data, tmp.len);}
|
||
|
||
// unsigned/signed comparisons
|
||
static inline bool _us32_gt(uint32_t a, int32_t b) { return a > INT32_MAX || (int32_t)a > b; }
|
||
static inline bool _us32_ge(uint32_t a, int32_t b) { return a >= INT32_MAX || (int32_t)a >= b; }
|
||
static inline bool _us32_eq(uint32_t a, int32_t b) { return a <= INT32_MAX && (int32_t)a == b; }
|
||
static inline bool _us32_ne(uint32_t a, int32_t b) { return a > INT32_MAX || (int32_t)a != b; }
|
||
static inline bool _us32_le(uint32_t a, int32_t b) { return a <= INT32_MAX && (int32_t)a <= b; }
|
||
static inline bool _us32_lt(uint32_t a, int32_t b) { return a < INT32_MAX && (int32_t)a < b; }
|
||
static inline bool _us64_gt(uint64_t a, int64_t b) { return a > INT64_MAX || (int64_t)a > b; }
|
||
static inline bool _us64_ge(uint64_t a, int64_t b) { return a >= INT64_MAX || (int64_t)a >= b; }
|
||
static inline bool _us64_eq(uint64_t a, int64_t b) { return a <= INT64_MAX && (int64_t)a == b; }
|
||
static inline bool _us64_ne(uint64_t a, int64_t b) { return a > INT64_MAX || (int64_t)a != b; }
|
||
static inline bool _us64_le(uint64_t a, int64_t b) { return a <= INT64_MAX && (int64_t)a <= b; }
|
||
static inline bool _us64_lt(uint64_t a, int64_t b) { return a < INT64_MAX && (int64_t)a < b; }
|
||
|
||
#define EMPTY_VARG_INITIALIZATION 0
|
||
#define EMPTY_STRUCT_INITIALIZATION 0
|
||
#define EMPTY_STRUCT_DECLARATION voidptr _dummy_pad
|
||
// Due to a tcc bug, the length of an array needs to be specified, but GCC crashes if it is...
|
||
#define EMPTY_ARRAY_OF_ELEMS(x,n) (x[])
|
||
#define TCCSKIP(x) x
|
||
|
||
#define __NOINLINE __attribute__((noinline))
|
||
#define __IRQHANDLER __attribute__((interrupt))
|
||
|
||
#define __V_architecture 0
|
||
#if defined(__x86_64__) || defined(_M_AMD64)
|
||
#define __V_amd64 1
|
||
#undef __V_architecture
|
||
#define __V_architecture 1
|
||
#endif
|
||
|
||
#if defined(__aarch64__) || defined(__arm64__) || defined(_M_ARM64)
|
||
#define __V_arm64 1
|
||
#undef __V_architecture
|
||
#define __V_architecture 2
|
||
#endif
|
||
|
||
#if defined(__arm__) || defined(_M_ARM)
|
||
#define __V_arm32 1
|
||
#undef __V_architecture
|
||
#define __V_architecture 3
|
||
#endif
|
||
|
||
#if defined(__i386__) || defined(_M_IX86)
|
||
#define __V_x86 1
|
||
#undef __V_architecture
|
||
#define __V_architecture 6
|
||
#endif
|
||
|
||
// Using just __GNUC__ for detecting gcc, is not reliable because other compilers define it too:
|
||
#ifdef __GNUC__
|
||
#define __V_GCC__
|
||
#endif
|
||
#ifdef __TINYC__
|
||
#undef __V_GCC__
|
||
#endif
|
||
#ifdef __cplusplus
|
||
#undef __V_GCC__
|
||
#endif
|
||
#ifdef __clang__
|
||
#undef __V_GCC__
|
||
#endif
|
||
#ifdef _MSC_VER
|
||
#undef __V_GCC__
|
||
#undef EMPTY_STRUCT_INITIALIZATION
|
||
#define EMPTY_STRUCT_INITIALIZATION 0
|
||
#endif
|
||
|
||
#ifdef __TINYC__
|
||
#define _Atomic volatile
|
||
#undef EMPTY_STRUCT_DECLARATION
|
||
#define EMPTY_STRUCT_DECLARATION voidptr _dummy_pad
|
||
#undef EMPTY_ARRAY_OF_ELEMS
|
||
#define EMPTY_ARRAY_OF_ELEMS(x,n) (x[n])
|
||
#undef __NOINLINE
|
||
#undef __IRQHANDLER
|
||
// tcc does not support inlining at all
|
||
#define __NOINLINE
|
||
#define __IRQHANDLER
|
||
#undef TCCSKIP
|
||
#define TCCSKIP(x)
|
||
// #include <byteswap.h>
|
||
#ifndef _WIN32
|
||
#include <execinfo.h>
|
||
int tcc_backtrace(const char *fmt, ...);
|
||
#endif
|
||
#endif
|
||
|
||
// Use __offsetof_ptr instead of __offset_of, when you *do* have a valid pointer, to avoid UB:
|
||
#ifndef __offsetof_ptr
|
||
#define __offsetof_ptr(ptr,PTYPE,FIELDNAME) ((size_t)((byte *)&((PTYPE *)ptr)->FIELDNAME - (byte *)ptr))
|
||
#endif
|
||
|
||
// for __offset_of
|
||
#ifndef __offsetof
|
||
#define __offsetof(PTYPE,FIELDNAME) ((size_t)((char *)&((PTYPE *)0)->FIELDNAME - (char *)0))
|
||
#endif
|
||
|
||
#define OPTION_CAST(x) (x)
|
||
|
||
#ifndef V64_PRINTFORMAT
|
||
#ifdef PRIx64
|
||
#define V64_PRINTFORMAT "0x%"PRIx64
|
||
#elif defined(__WIN32__)
|
||
#define V64_PRINTFORMAT "0x%I64x"
|
||
#elif defined(__linux__) && defined(__LP64__)
|
||
#define V64_PRINTFORMAT "0x%lx"
|
||
#else
|
||
#define V64_PRINTFORMAT "0x%llx"
|
||
#endif
|
||
#endif
|
||
|
||
#if defined(_WIN32) || defined(__CYGWIN__)
|
||
#define VV_EXPORTED_SYMBOL extern __declspec(dllexport)
|
||
#define VV_LOCAL_SYMBOL static
|
||
#else
|
||
// 4 < gcc < 5 is used by some older Ubuntu LTS and Centos versions,
|
||
// and does not support __has_attribute(visibility) ...
|
||
#ifndef __has_attribute
|
||
#define __has_attribute(x) 0 // Compatibility with non-clang compilers.
|
||
#endif
|
||
#if (defined(__GNUC__) && (__GNUC__ >= 4)) || (defined(__clang__) && __has_attribute(visibility))
|
||
#ifdef ARM
|
||
#define VV_EXPORTED_SYMBOL extern __attribute__((externally_visible,visibility("default")))
|
||
#else
|
||
#define VV_EXPORTED_SYMBOL extern __attribute__((visibility("default")))
|
||
#endif
|
||
#if defined(__clang__) && (defined(_VUSECACHE) || defined(_VBUILDMODULE))
|
||
#define VV_LOCAL_SYMBOL static
|
||
#else
|
||
#define VV_LOCAL_SYMBOL __attribute__ ((visibility ("hidden")))
|
||
#endif
|
||
#else
|
||
#define VV_EXPORTED_SYMBOL extern
|
||
#define VV_LOCAL_SYMBOL static
|
||
#endif
|
||
#endif
|
||
|
||
#ifdef __cplusplus
|
||
#include <utility>
|
||
#define _MOV std::move
|
||
#else
|
||
#define _MOV
|
||
#endif
|
||
|
||
// tcc does not support has_include properly yet, turn it off completely
|
||
#if defined(__TINYC__) && defined(__has_include)
|
||
#undef __has_include
|
||
#endif
|
||
|
||
|
||
#if !defined(VWEAK)
|
||
#define VWEAK __attribute__((weak))
|
||
#ifdef _MSC_VER
|
||
#undef VWEAK
|
||
#define VWEAK
|
||
#endif
|
||
#if defined(__MINGW32__) || defined(__MINGW64__)
|
||
#undef VWEAK
|
||
#define VWEAK
|
||
#endif
|
||
#endif
|
||
|
||
#if !defined(VNORETURN)
|
||
#if defined(__TINYC__)
|
||
#include <stdnoreturn.h>
|
||
#define VNORETURN noreturn
|
||
#endif
|
||
# if !defined(__TINYC__) && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
|
||
# define VNORETURN _Noreturn
|
||
# elif defined(__GNUC__) && __GNUC__ >= 2
|
||
# define VNORETURN __attribute__((noreturn))
|
||
# endif
|
||
#ifndef VNORETURN
|
||
#define VNORETURN
|
||
#endif
|
||
#endif
|
||
|
||
#if !defined(VUNREACHABLE)
|
||
#if defined(__GNUC__) && !defined(__clang__)
|
||
#define V_GCC_VERSION (__GNUC__ * 10000L + __GNUC_MINOR__ * 100L + __GNUC_PATCHLEVEL__)
|
||
#if (V_GCC_VERSION >= 40500L)
|
||
#define VUNREACHABLE() do { __builtin_unreachable(); } while (0)
|
||
#endif
|
||
#endif
|
||
#if defined(__clang__) && defined(__has_builtin)
|
||
#if __has_builtin(__builtin_unreachable)
|
||
#define VUNREACHABLE() do { __builtin_unreachable(); } while (0)
|
||
#endif
|
||
#endif
|
||
#ifndef VUNREACHABLE
|
||
#define VUNREACHABLE() do { } while (0)
|
||
#endif
|
||
#if defined(__FreeBSD__) && defined(__TINYC__)
|
||
#define VUNREACHABLE() do { } while (0)
|
||
#endif
|
||
#endif
|
||
|
||
//likely and unlikely macros
|
||
#if defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__clang__)
|
||
#define _likely_(x) __builtin_expect(x,1)
|
||
#define _unlikely_(x) __builtin_expect(x,0)
|
||
#else
|
||
#define _likely_(x) (x)
|
||
#define _unlikely_(x) (x)
|
||
#endif
|
||
|
||
|
||
// c_headers
|
||
typedef int (*qsort_callback_func)(const void*, const void*);
|
||
#include <stdio.h> // TODO remove all these includes, define all function signatures and types manually
|
||
#include <stdlib.h>
|
||
#include <string.h>
|
||
|
||
#ifndef _WIN32
|
||
#if defined __has_include
|
||
#if __has_include (<execinfo.h>)
|
||
#include <execinfo.h>
|
||
#endif
|
||
#endif
|
||
#endif
|
||
|
||
#include <stdarg.h> // for va_list
|
||
|
||
//================================== GLOBALS =================================*/
|
||
int load_so(byteptr);
|
||
void _vinit(int ___argc, voidptr ___argv);
|
||
void _vcleanup(void);
|
||
#define sigaction_size sizeof(sigaction);
|
||
#define _ARR_LEN(a) ( (sizeof(a)) / (sizeof(a[0])) )
|
||
|
||
void v_free(voidptr ptr);
|
||
voidptr memdup(voidptr src, int sz);
|
||
|
||
#if INTPTR_MAX == INT32_MAX
|
||
#define TARGET_IS_32BIT 1
|
||
#elif INTPTR_MAX == INT64_MAX
|
||
#define TARGET_IS_64BIT 1
|
||
#else
|
||
#error "The environment is not 32 or 64-bit."
|
||
#endif
|
||
|
||
#if defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__ || defined(__BYTE_ORDER) && __BYTE_ORDER == __BIG_ENDIAN || defined(__BIG_ENDIAN__) || defined(__ARMEB__) || defined(__THUMBEB__) || defined(__AARCH64EB__) || defined(_MIBSEB) || defined(__MIBSEB) || defined(__MIBSEB__)
|
||
#define TARGET_ORDER_IS_BIG 1
|
||
#elif defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__ || defined(__BYTE_ORDER) && __BYTE_ORDER == __LITTLE_ENDIAN || defined(__LITTLE_ENDIAN__) || defined(__ARMEL__) || defined(__THUMBEL__) || defined(__AARCH64EL__) || defined(_MIPSEL) || defined(__MIPSEL) || defined(__MIPSEL__) || defined(_M_AMD64) || defined(_M_X64) || defined(_M_IX86)
|
||
#define TARGET_ORDER_IS_LITTLE 1
|
||
#else
|
||
#error "Unknown architecture endianness"
|
||
#endif
|
||
|
||
#ifndef _WIN32
|
||
#include <ctype.h>
|
||
#include <locale.h> // tolower
|
||
#include <sys/time.h>
|
||
#include <unistd.h> // sleep
|
||
extern char **environ;
|
||
#endif
|
||
|
||
#if defined(__CYGWIN__) && !defined(_WIN32)
|
||
#error Cygwin is not supported, please use MinGW or Visual Studio.
|
||
#endif
|
||
|
||
#if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__) || defined(__vinix__) || defined(__serenity__) || defined(__sun)
|
||
#include <sys/types.h>
|
||
#include <sys/wait.h> // os__wait uses wait on nix
|
||
#endif
|
||
|
||
#ifdef __OpenBSD__
|
||
#include <sys/types.h>
|
||
#include <sys/resource.h>
|
||
#include <sys/wait.h> // os__wait uses wait on nix
|
||
#endif
|
||
|
||
#ifdef __NetBSD__
|
||
#include <sys/wait.h> // os__wait uses wait on nix
|
||
#endif
|
||
|
||
#ifdef _WIN32
|
||
#define WINVER 0x0600
|
||
#ifdef _WIN32_WINNT
|
||
#undef _WIN32_WINNT
|
||
#endif
|
||
#define _WIN32_WINNT 0x0600
|
||
#ifndef WIN32_FULL
|
||
#define WIN32_LEAN_AND_MEAN
|
||
#endif
|
||
#ifndef _UNICODE
|
||
#define _UNICODE
|
||
#endif
|
||
#ifndef UNICODE
|
||
#define UNICODE
|
||
#endif
|
||
#include <windows.h>
|
||
|
||
#include <io.h> // _waccess
|
||
#include <direct.h> // _wgetcwd
|
||
#ifdef V_USE_SIGNAL_H
|
||
#include <signal.h> // signal and SIGSEGV for segmentation fault handler
|
||
#endif
|
||
|
||
#ifdef _MSC_VER
|
||
// On MSVC these are the same (as long as /volatile:ms is passed)
|
||
#define _Atomic volatile
|
||
|
||
// MSVC cannot parse some things properly
|
||
#undef EMPTY_STRUCT_DECLARATION
|
||
#undef OPTION_CAST
|
||
|
||
#define EMPTY_STRUCT_DECLARATION voidptr _dummy_pad
|
||
#define OPTION_CAST(x)
|
||
#undef __NOINLINE
|
||
#undef __IRQHANDLER
|
||
#define __NOINLINE __declspec(noinline)
|
||
#define __IRQHANDLER __declspec(naked)
|
||
|
||
#include <dbghelp.h>
|
||
#pragma comment(lib, "Dbghelp")
|
||
#endif
|
||
#else
|
||
#include <pthread.h>
|
||
#ifndef PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP
|
||
// musl does not have that
|
||
#define pthread_rwlockattr_setkind_np(a, b)
|
||
#endif
|
||
#endif
|
||
|
||
// g_live_info is used by live.info()
|
||
static void* g_live_info = NULL;
|
||
|
||
#if defined(__MINGW32__) || defined(__MINGW64__) || (defined(_WIN32) && defined(__TINYC__))
|
||
#undef PRId64
|
||
#undef PRIi64
|
||
#undef PRIo64
|
||
#undef PRIu64
|
||
#undef PRIx64
|
||
#undef PRIX64
|
||
#define PRId64 "lld"
|
||
#define PRIi64 "lli"
|
||
#define PRIo64 "llo"
|
||
#define PRIu64 "llu"
|
||
#define PRIx64 "llx"
|
||
#define PRIX64 "llX"
|
||
#endif
|
||
|
||
#ifdef _VFREESTANDING
|
||
#undef _VFREESTANDING
|
||
#endif
|
||
|
||
|
||
// ============== wyhash ==============
|
||
#ifndef wyhash_final_version_3
|
||
#define wyhash_final_version_3
|
||
|
||
#ifndef WYHASH_CONDOM
|
||
// protections that produce different results:
|
||
// 1: normal valid behavior
|
||
// 2: extra protection against entropy loss (probability=2^-63), aka. "blind multiplication"
|
||
#define WYHASH_CONDOM 1
|
||
#endif
|
||
|
||
#ifndef WYHASH_32BIT_MUM
|
||
// 0: normal version, slow on 32 bit systems
|
||
// 1: faster on 32 bit systems but produces different results, incompatible with wy2u0k function
|
||
#define WYHASH_32BIT_MUM 0
|
||
#endif
|
||
|
||
// includes
|
||
#include <stdint.h>
|
||
#if defined(_MSC_VER) && defined(_M_X64)
|
||
#include <intrin.h>
|
||
#pragma intrinsic(_umul128)
|
||
#endif
|
||
|
||
// 128bit multiply function
|
||
static inline uint64_t _wyrot(uint64_t x) { return (x>>32)|(x<<32); }
|
||
static inline void _wymum(uint64_t *A, uint64_t *B){
|
||
#if(WYHASH_32BIT_MUM)
|
||
uint64_t hh=(*A>>32)*(*B>>32), hl=(*A>>32)*(uint32_t)*B, lh=(uint32_t)*A*(*B>>32), ll=(uint64_t)(uint32_t)*A*(uint32_t)*B;
|
||
#if(WYHASH_CONDOM>1)
|
||
*A^=_wyrot(hl)^hh; *B^=_wyrot(lh)^ll;
|
||
#else
|
||
*A=_wyrot(hl)^hh; *B=_wyrot(lh)^ll;
|
||
#endif
|
||
#elif defined(__SIZEOF_INT128__) && !defined(VWASM)
|
||
__uint128_t r=*A; r*=*B;
|
||
#if(WYHASH_CONDOM>1)
|
||
*A^=(uint64_t)r; *B^=(uint64_t)(r>>64);
|
||
#else
|
||
*A=(uint64_t)r; *B=(uint64_t)(r>>64);
|
||
#endif
|
||
#elif defined(_MSC_VER) && defined(_M_X64)
|
||
#if(WYHASH_CONDOM>1)
|
||
uint64_t a, b;
|
||
a=_umul128(*A,*B,&b);
|
||
*A^=a; *B^=b;
|
||
#else
|
||
*A=_umul128(*A,*B,B);
|
||
#endif
|
||
#else
|
||
uint64_t ha=*A>>32, hb=*B>>32, la=(uint32_t)*A, lb=(uint32_t)*B, hi, lo;
|
||
uint64_t rh=ha*hb, rm0=ha*lb, rm1=hb*la, rl=la*lb, t=rl+(rm0<<32), c=t<rl;
|
||
lo=t+(rm1<<32); c+=lo<t; hi=rh+(rm0>>32)+(rm1>>32)+c;
|
||
#if(WYHASH_CONDOM>1)
|
||
*A^=lo; *B^=hi;
|
||
#else
|
||
*A=lo; *B=hi;
|
||
#endif
|
||
#endif
|
||
}
|
||
|
||
// multiply and xor mix function, aka MUM
|
||
static inline uint64_t _wymix(uint64_t A, uint64_t B){ _wymum(&A,&B); return A^B; }
|
||
|
||
// endian macros
|
||
#ifndef WYHASH_LITTLE_ENDIAN
|
||
#ifdef TARGET_ORDER_IS_LITTLE
|
||
#define WYHASH_LITTLE_ENDIAN 1
|
||
#else
|
||
#define WYHASH_LITTLE_ENDIAN 0
|
||
#endif
|
||
#endif
|
||
|
||
// read functions
|
||
#if (WYHASH_LITTLE_ENDIAN)
|
||
static inline uint64_t _wyr8(const uint8_t *p) { uint64_t v; memcpy(&v, p, 8); return v;}
|
||
static inline uint64_t _wyr4(const uint8_t *p) { uint32_t v; memcpy(&v, p, 4); return v;}
|
||
#elif defined(__GNUC__) || defined(__INTEL_COMPILER) || defined(__clang__)
|
||
static inline uint64_t _wyr8(const uint8_t *p) { uint64_t v; memcpy(&v, p, 8); return __builtin_bswap64(v);}
|
||
static inline uint64_t _wyr4(const uint8_t *p) { uint32_t v; memcpy(&v, p, 4); return __builtin_bswap32(v);}
|
||
#elif defined(_MSC_VER)
|
||
static inline uint64_t _wyr8(const uint8_t *p) { uint64_t v; memcpy(&v, p, 8); return _byteswap_uint64(v);}
|
||
static inline uint64_t _wyr4(const uint8_t *p) { uint32_t v; memcpy(&v, p, 4); return _byteswap_ulong(v);}
|
||
#else
|
||
static inline uint64_t _wyr8(const uint8_t *p) {
|
||
uint64_t v; memcpy(&v, p, 8);
|
||
return (((v >> 56) & 0xff)| ((v >> 40) & 0xff00)| ((v >> 24) & 0xff0000)| ((v >> 8) & 0xff000000)| ((v << 8) & 0xff00000000)| ((v << 24) & 0xff0000000000)| ((v << 40) & 0xff000000000000)| ((v << 56) & 0xff00000000000000));
|
||
}
|
||
static inline uint64_t _wyr4(const uint8_t *p) {
|
||
uint32_t v; memcpy(&v, p, 4);
|
||
return (((v >> 24) & 0xff)| ((v >> 8) & 0xff00)| ((v << 8) & 0xff0000)| ((v << 24) & 0xff000000));
|
||
}
|
||
#endif
|
||
static inline uint64_t _wyr3(const uint8_t *p, size_t k) { return (((uint64_t)p[0])<<16)|(((uint64_t)p[k>>1])<<8)|p[k-1];}
|
||
// wyhash main function
|
||
static inline uint64_t wyhash(const void *key, size_t len, uint64_t seed, const uint64_t *secret){
|
||
const uint8_t *p=(const uint8_t *)key; seed^=*secret; uint64_t a, b;
|
||
if (_likely_(len<=16)) {
|
||
if (_likely_(len>=4)) { a=(_wyr4(p)<<32)|_wyr4(p+((len>>3)<<2)); b=(_wyr4(p+len-4)<<32)|_wyr4(p+len-4-((len>>3)<<2)); }
|
||
else if (_likely_(len>0)) { a=_wyr3(p,len); b=0; }
|
||
else a=b=0;
|
||
} else {
|
||
size_t i=len;
|
||
if (_unlikely_(i>48)) {
|
||
uint64_t see1=seed, see2=seed;
|
||
do {
|
||
seed=_wymix(_wyr8(p)^secret[1],_wyr8(p+8)^seed);
|
||
see1=_wymix(_wyr8(p+16)^secret[2],_wyr8(p+24)^see1);
|
||
see2=_wymix(_wyr8(p+32)^secret[3],_wyr8(p+40)^see2);
|
||
p+=48; i-=48;
|
||
} while(_likely_(i>48));
|
||
seed^=see1^see2;
|
||
}
|
||
while(_unlikely_(i>16)) { seed=_wymix(_wyr8(p)^secret[1],_wyr8(p+8)^seed); i-=16; p+=16; }
|
||
a=_wyr8(p+i-16); b=_wyr8(p+i-8);
|
||
}
|
||
return _wymix(secret[1]^len,_wymix(a^secret[1],b^seed));
|
||
}
|
||
// the default secret parameters
|
||
static const uint64_t _wyp[4] = {0xa0761d6478bd642full, 0xe7037ed1a0b428dbull, 0x8ebc6af09c88c6e3ull, 0x589965cc75374cc3ull};
|
||
|
||
// a useful 64bit-64bit mix function to produce deterministic pseudo random numbers that can pass BigCrush and PractRand
|
||
static inline uint64_t wyhash64(uint64_t A, uint64_t B){ A^=0xa0761d6478bd642full; B^=0xe7037ed1a0b428dbull; _wymum(&A,&B); return _wymix(A^0xa0761d6478bd642full,B^0xe7037ed1a0b428dbull);}
|
||
|
||
// the wyrand PRNG that pass BigCrush and PractRand
|
||
static inline uint64_t wyrand(uint64_t *seed){ *seed+=0xa0761d6478bd642full; return _wymix(*seed,*seed^0xe7037ed1a0b428dbull);}
|
||
|
||
#ifndef __vinix__
|
||
// convert any 64 bit pseudo random numbers to uniform distribution [0,1). It can be combined with wyrand, wyhash64 or wyhash.
|
||
static inline double wy2u01(uint64_t r){ const double _wynorm=1.0/(1ull<<52); return (r>>12)*_wynorm;}
|
||
|
||
// convert any 64 bit pseudo random numbers to APPROXIMATE Gaussian distribution. It can be combined with wyrand, wyhash64 or wyhash.
|
||
static inline double wy2gau(uint64_t r){ const double _wynorm=1.0/(1ull<<20); return ((r&0x1fffff)+((r>>21)&0x1fffff)+((r>>42)&0x1fffff))*_wynorm-3.0;}
|
||
#endif
|
||
|
||
#if(!WYHASH_32BIT_MUM)
|
||
// fast range integer random number generation on [0,k) credit to Daniel Lemire. May not work when WYHASH_32BIT_MUM=1. It can be combined with wyrand, wyhash64 or wyhash.
|
||
static inline uint64_t wy2u0k(uint64_t r, uint64_t k){ _wymum(&r,&k); return k; }
|
||
#endif
|
||
#endif
|
||
|
||
#define _IN_MAP(val, m) map_exists(m, val)
|
||
|
||
|
||
|
||
// V includes:
|
||
|
||
#if defined(__TINYC__) && defined(__has_include)
|
||
// tcc does not support has_include properly yet, turn it off completely
|
||
#undef __has_include
|
||
#endif
|
||
|
||
|
||
// added by module `builtin`, file: float.c.v:9:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<float.h>)
|
||
#include <float.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <float.h>, needed for module `builtin` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <float.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `time`, file: time.c.v:6:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<time.h>)
|
||
#include <time.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <time.h>, needed for module `time` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <time.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `time`, file: time_nix.c.v:6:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<time.h>)
|
||
#include <time.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <time.h>, needed for module `time` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <time.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `time`, file: time_nix.c.v:7:
|
||
#include <errno.h>
|
||
|
||
|
||
#if defined(_WIN32)
|
||
// inserted by module `sync.stdatomic`, file: 1.declarations.c.v:8:
|
||
/*
|
||
* This file is part of FFmpeg.
|
||
*
|
||
* FFmpeg is free software; you can redistribute it and/or
|
||
* modify it under the terms of the GNU Lesser General Public
|
||
* License as published by the Free Software Foundation; either
|
||
* version 2.1 of the License, or (at your option) any later version.
|
||
*
|
||
* FFmpeg is distributed in the hope that it will be useful,
|
||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||
* Lesser General Public License for more details.
|
||
*
|
||
* You should have received a copy of the GNU Lesser General Public
|
||
* License along with FFmpeg; if not, write to the Free Software
|
||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||
*/
|
||
|
||
#ifndef COMPAT_ATOMICS_WIN32_STDATOMIC_H
|
||
#define COMPAT_ATOMICS_WIN32_STDATOMIC_H
|
||
|
||
#define WIN32_LEAN_AND_MEAN
|
||
#include <stddef.h>
|
||
#include <stdint.h>
|
||
#include <windows.h>
|
||
|
||
#ifdef __TINYC__
|
||
#endif
|
||
|
||
#define ATOMIC_FLAG_INIT 0
|
||
|
||
#define ATOMIC_VAR_INIT(value) (value)
|
||
|
||
#define atomic_init(obj, value) \
|
||
do \
|
||
{ \
|
||
*(obj) = (value); \
|
||
} while (0)
|
||
|
||
#define kill_dependency(y) ((void)0)
|
||
|
||
#define atomic_thread_fence(order) \
|
||
MemoryBarrier();
|
||
|
||
#define atomic_signal_fence(order) \
|
||
((void)0)
|
||
|
||
#define atomic_is_lock_free(obj) 0
|
||
|
||
typedef intptr_t atomic_flag;
|
||
typedef intptr_t atomic_bool;
|
||
typedef intptr_t atomic_char;
|
||
typedef intptr_t atomic_schar;
|
||
typedef intptr_t atomic_uchar;
|
||
typedef intptr_t atomic_short;
|
||
typedef intptr_t atomic_ushort;
|
||
typedef intptr_t atomic_int;
|
||
typedef intptr_t atomic_uint;
|
||
typedef intptr_t atomic_long;
|
||
typedef intptr_t atomic_ulong;
|
||
typedef intptr_t atomic_llong;
|
||
typedef intptr_t atomic_ullong;
|
||
typedef intptr_t atomic_wchar_t;
|
||
typedef intptr_t atomic_int_least8_t;
|
||
typedef intptr_t atomic_uint_least8_t;
|
||
typedef intptr_t atomic_int_least16_t;
|
||
typedef intptr_t atomic_uint_least16_t;
|
||
typedef intptr_t atomic_int_least32_t;
|
||
typedef intptr_t atomic_uint_least32_t;
|
||
typedef intptr_t atomic_int_least64_t;
|
||
typedef intptr_t atomic_uint_least64_t;
|
||
typedef intptr_t atomic_int_fast8_t;
|
||
typedef intptr_t atomic_uint_fast8_t;
|
||
typedef intptr_t atomic_int_fast16_t;
|
||
typedef intptr_t atomic_uint_fast16_t;
|
||
typedef intptr_t atomic_int_fast32_t;
|
||
typedef intptr_t atomic_uint_fast32_t;
|
||
typedef intptr_t atomic_int_fast64_t;
|
||
typedef intptr_t atomic_uint_fast64_t;
|
||
typedef intptr_t atomic_intptr_t;
|
||
typedef intptr_t atomic_uintptr_t;
|
||
typedef intptr_t atomic_size_t;
|
||
typedef intptr_t atomic_ptrdiff_t;
|
||
typedef intptr_t atomic_intmax_t;
|
||
typedef intptr_t atomic_uintmax_t;
|
||
|
||
#ifdef __TINYC__
|
||
/*
|
||
For TCC it is missing the x64 version of _InterlockedExchangeAdd64 so we
|
||
fake it (works the same) with InterlockedCompareExchange64 until it
|
||
succeeds
|
||
*/
|
||
__CRT_INLINE LONGLONG _InterlockedExchangeAdd64(LONGLONG volatile *Addend, LONGLONG Value)
|
||
{
|
||
LONGLONG Old;
|
||
do
|
||
{
|
||
Old = *Addend;
|
||
} while (InterlockedCompareExchange64(Addend, Old + Value, Old) != Old);
|
||
return Old;
|
||
}
|
||
|
||
__CRT_INLINE LONG _InterlockedExchangeAdd(LONG volatile *Addend, LONG Value)
|
||
{
|
||
LONG Old;
|
||
do
|
||
{
|
||
Old = *Addend;
|
||
} while (InterlockedCompareExchange(Addend, Old + Value, Old) != Old);
|
||
return Old;
|
||
}
|
||
|
||
__CRT_INLINE SHORT _InterlockedExchangeAdd16(SHORT volatile *Addend, SHORT Value)
|
||
{
|
||
SHORT Old;
|
||
do
|
||
{
|
||
Old = *Addend;
|
||
} while (InterlockedCompareExchange16(Addend, Old + Value, Old) != Old);
|
||
return Old;
|
||
}
|
||
|
||
#define InterlockedIncrement64 _InterlockedExchangeAdd64
|
||
|
||
#endif
|
||
|
||
#define atomic_store(object, desired) \
|
||
do \
|
||
{ \
|
||
*(object) = (desired); \
|
||
MemoryBarrier(); \
|
||
} while (0)
|
||
|
||
#define atomic_store_explicit(object, desired, order) \
|
||
atomic_store(object, desired)
|
||
|
||
#define atomic_load(object) \
|
||
(MemoryBarrier(), *(object))
|
||
|
||
#define atomic_load_explicit(object, order) \
|
||
atomic_load(object)
|
||
|
||
#define atomic_exchange(object, desired) \
|
||
InterlockedExchangePointer(object, desired)
|
||
|
||
#define atomic_exchange_explicit(object, desired, order) \
|
||
atomic_exchange(object, desired)
|
||
|
||
static inline int atomic_compare_exchange_strong(intptr_t *object, intptr_t *expected,
|
||
intptr_t desired)
|
||
{
|
||
intptr_t old = *expected;
|
||
*expected = (intptr_t)InterlockedCompareExchangePointer(
|
||
(PVOID *)object, (PVOID)desired, (PVOID)old);
|
||
return *expected == old;
|
||
}
|
||
|
||
#define atomic_compare_exchange_strong_explicit(object, expected, desired, success, failure) \
|
||
atomic_compare_exchange_strong(object, expected, desired)
|
||
|
||
#define atomic_compare_exchange_weak(object, expected, desired) \
|
||
atomic_compare_exchange_strong(object, expected, desired)
|
||
|
||
#define atomic_compare_exchange_weak_explicit(object, expected, desired, success, failure) \
|
||
atomic_compare_exchange_weak(object, expected, desired)
|
||
|
||
#ifdef _WIN64
|
||
|
||
#define atomic_fetch_add(object, operand) \
|
||
InterlockedExchangeAdd64(object, operand)
|
||
|
||
#define atomic_fetch_sub(object, operand) \
|
||
InterlockedExchangeAdd64(object, -(operand))
|
||
|
||
#define atomic_fetch_or(object, operand) \
|
||
InterlockedOr64(object, operand)
|
||
|
||
#define atomic_fetch_xor(object, operand) \
|
||
InterlockedXor64(object, operand)
|
||
|
||
#define atomic_fetch_and(object, operand) \
|
||
InterlockedAnd64(object, operand)
|
||
#else
|
||
#define atomic_fetch_add(object, operand) \
|
||
InterlockedExchangeAdd(object, operand)
|
||
|
||
#define atomic_fetch_sub(object, operand) \
|
||
InterlockedExchangeAdd(object, -(operand))
|
||
|
||
#define atomic_fetch_or(object, operand) \
|
||
InterlockedOr(object, operand)
|
||
|
||
#define atomic_fetch_xor(object, operand) \
|
||
InterlockedXor(object, operand)
|
||
|
||
#define atomic_fetch_and(object, operand) \
|
||
InterlockedAnd(object, operand)
|
||
#endif /* _WIN64 */
|
||
|
||
/* specialized versions with explicit object size */
|
||
|
||
#define atomic_load_ptr atomic_load
|
||
#define atomic_store_ptr atomic_store
|
||
#define atomic_compare_exchange_weak_ptr atomic_compare_exchange_weak
|
||
#define atomic_compare_exchange_strong_ptr atomic_compare_exchange_strong
|
||
#define atomic_exchange_ptr atomic_exchange
|
||
#define atomic_fetch_add_ptr atomic_fetch_add
|
||
#define atomic_fetch_sub_ptr atomic_fetch_sub
|
||
#define atomic_fetch_and_ptr atomic_fetch_and
|
||
#define atomic_fetch_or_ptr atomic_fetch_or
|
||
#define atomic_fetch_xor_ptr atomic_fetch_xor
|
||
|
||
static inline void atomic_store_u64(unsigned long long* object, unsigned long long desired) {
|
||
do {
|
||
*(object) = (desired);
|
||
MemoryBarrier();
|
||
} while (0);
|
||
}
|
||
|
||
static inline unsigned long long atomic_load_u64(unsigned long long* object) {
|
||
return (MemoryBarrier(), *(object));
|
||
}
|
||
|
||
#define atomic_exchange_u64(object, desired) \
|
||
InterlockedExchange64(object, desired)
|
||
|
||
static inline int atomic_compare_exchange_strong_u64(unsigned long long* object, unsigned long long* expected,
|
||
unsigned long long desired)
|
||
{
|
||
unsigned long long old = *expected;
|
||
*expected = InterlockedCompareExchange64(object, desired, old);
|
||
return *expected == old;
|
||
}
|
||
|
||
#define atomic_compare_exchange_weak_u64(object, expected, desired) \
|
||
atomic_compare_exchange_strong_u64(object, expected, desired)
|
||
|
||
#define atomic_fetch_add_u64(object, operand) \
|
||
InterlockedExchangeAdd64(object, operand)
|
||
|
||
#define atomic_fetch_sub_u64(object, operand) \
|
||
InterlockedExchangeAdd64(object, -(operand))
|
||
|
||
#define atomic_fetch_or_u64(object, operand) \
|
||
InterlockedOr64(object, operand)
|
||
|
||
#define atomic_fetch_xor_u64(object, operand) \
|
||
InterlockedXor64(object, operand)
|
||
|
||
#define atomic_fetch_and_u64(object, operand) \
|
||
InterlockedAnd64(object, operand)
|
||
|
||
|
||
|
||
static inline void atomic_store_u32(unsigned* object, unsigned desired) {
|
||
do {
|
||
*(object) = (desired);
|
||
MemoryBarrier();
|
||
} while (0);
|
||
}
|
||
|
||
static inline unsigned atomic_load_u32(unsigned* object) {
|
||
return (MemoryBarrier(), *(object));
|
||
}
|
||
|
||
#define atomic_exchange_u32(object, desired) \
|
||
InterlockedExchange(object, desired)
|
||
|
||
static inline int atomic_compare_exchange_strong_u32(unsigned* object, unsigned* expected,
|
||
unsigned desired)
|
||
{
|
||
unsigned old = *expected;
|
||
*expected = InterlockedCompareExchange(object, desired, old);
|
||
return *expected == old;
|
||
}
|
||
|
||
#define atomic_compare_exchange_weak_u32(object, expected, desired) \
|
||
atomic_compare_exchange_strong_u32(object, expected, desired)
|
||
|
||
#define atomic_fetch_add_u32(object, operand) \
|
||
InterlockedExchangeAdd(object, operand)
|
||
|
||
#define atomic_fetch_sub_u32(object, operand) \
|
||
InterlockedExchangeAdd(object, -(operand))
|
||
|
||
#define atomic_fetch_or_u32(object, operand) \
|
||
InterlockedOr(object, operand)
|
||
|
||
#define atomic_fetch_xor_u32(object, operand) \
|
||
InterlockedXor(object, operand)
|
||
|
||
#define atomic_fetch_and_u32(object, operand) \
|
||
InterlockedAnd(object, operand)
|
||
|
||
|
||
|
||
static inline void atomic_store_u16(unsigned short* object, unsigned short desired) {
|
||
do {
|
||
*(object) = (desired);
|
||
MemoryBarrier();
|
||
} while (0);
|
||
}
|
||
|
||
static inline unsigned short atomic_load_u16(unsigned short* object) {
|
||
return (MemoryBarrier(), *(object));
|
||
}
|
||
|
||
#define atomic_exchange_u16(object, desired) \
|
||
InterlockedExchange16(object, desired)
|
||
|
||
static inline int atomic_compare_exchange_strong_u16(unsigned short* object, unsigned short* expected,
|
||
unsigned short desired)
|
||
{
|
||
unsigned short old = *expected;
|
||
*expected = InterlockedCompareExchange16(object, desired, old);
|
||
return *expected == old;
|
||
}
|
||
|
||
#define atomic_compare_exchange_weak_u16(object, expected, desired) \
|
||
atomic_compare_exchange_strong_u16(object, expected, desired)
|
||
|
||
#define atomic_fetch_add_u16(object, operand) \
|
||
InterlockedExchangeAdd16(object, operand)
|
||
|
||
#define atomic_fetch_sub_u16(object, operand) \
|
||
InterlockedExchangeAdd16(object, -(operand))
|
||
|
||
#define atomic_fetch_or_u16(object, operand) \
|
||
InterlockedOr16(object, operand)
|
||
|
||
#define atomic_fetch_xor_u16(object, operand) \
|
||
InterlockedXor16(object, operand)
|
||
|
||
#define atomic_fetch_and_u16(object, operand) \
|
||
InterlockedAnd16(object, operand)
|
||
|
||
|
||
|
||
#define atomic_fetch_add_explicit(object, operand, order) \
|
||
atomic_fetch_add(object, operand)
|
||
|
||
#define atomic_fetch_sub_explicit(object, operand, order) \
|
||
atomic_fetch_sub(object, operand)
|
||
|
||
#define atomic_fetch_or_explicit(object, operand, order) \
|
||
atomic_fetch_or(object, operand)
|
||
|
||
#define atomic_fetch_xor_explicit(object, operand, order) \
|
||
atomic_fetch_xor(object, operand)
|
||
|
||
#define atomic_fetch_and_explicit(object, operand, order) \
|
||
atomic_fetch_and(object, operand)
|
||
|
||
#define atomic_flag_test_and_set(object) \
|
||
atomic_exchange(object, 1)
|
||
|
||
#define atomic_flag_test_and_set_explicit(object, order) \
|
||
atomic_flag_test_and_set(object)
|
||
|
||
#define atomic_flag_clear(object) \
|
||
atomic_store(object, 0)
|
||
|
||
#define atomic_flag_clear_explicit(object, order) \
|
||
atomic_flag_clear(object)
|
||
|
||
#endif /* COMPAT_ATOMICS_WIN32_STDATOMIC_H */
|
||
|
||
#endif // $if defined(_WIN32)
|
||
#if 1
|
||
// inserted by module `sync.stdatomic`, file: 1.declarations.c.v:11:
|
||
/*
|
||
Compatibility header for stdatomic.h that works for all compilers supported by V.
|
||
For TCC, we use libatomic from the OS.
|
||
*/
|
||
#ifndef __ATOMIC_H
|
||
#define __ATOMIC_H
|
||
|
||
#ifndef __cplusplus
|
||
// If C just use stdatomic.h
|
||
#ifndef __TINYC__
|
||
#include <stdatomic.h>
|
||
#endif
|
||
#else
|
||
// CPP wrapper for atomic operations that are compatible with C
|
||
#include "atomic_cpp.h"
|
||
#endif
|
||
|
||
#ifdef __TINYC__
|
||
|
||
typedef volatile long long atomic_llong;
|
||
typedef volatile unsigned long long atomic_ullong;
|
||
typedef volatile uintptr_t atomic_uintptr_t;
|
||
|
||
// use functions for 64, 32 and 8 bit from libatomic directly
|
||
// since tcc is not capible to use "generic" C functions
|
||
// there is no header file for libatomic so we provide function declarations here
|
||
|
||
extern unsigned long long __atomic_load_8(unsigned long long* x, int mo);
|
||
extern void __atomic_store_8(unsigned long long* x, unsigned long long y, int mo);
|
||
extern _Bool __atomic_compare_exchange_8(unsigned long long* x, unsigned long long* expected, unsigned long long y, int mo, int mo2);
|
||
extern _Bool __atomic_compare_exchange_8(unsigned long long* x, unsigned long long* expected, unsigned long long y, int mo, int mo2);
|
||
extern unsigned long long __atomic_exchange_8(unsigned long long* x, unsigned long long y, int mo);
|
||
extern unsigned long long __atomic_fetch_add_8(unsigned long long* x, unsigned long long y, int mo);
|
||
extern unsigned long long __atomic_fetch_sub_8(unsigned long long* x, unsigned long long y, int mo);
|
||
extern unsigned long long __atomic_fetch_and_8(unsigned long long* x, unsigned long long y, int mo);
|
||
extern unsigned long long __atomic_fetch_or_8(unsigned long long* x, unsigned long long y, int mo);
|
||
extern unsigned long long __atomic_fetch_xor_8(unsigned long long* x, unsigned long long y, int mo);
|
||
|
||
extern unsigned int __atomic_load_4(unsigned int* x, int mo);
|
||
extern void __atomic_store_4(unsigned int* x, unsigned int y, int mo);
|
||
extern _Bool __atomic_compare_exchange_4(unsigned int* x, unsigned int* expected, unsigned int y, int mo, int mo2);
|
||
extern _Bool __atomic_compare_exchange_4(unsigned int* x, unsigned int* expected, unsigned int y, int mo, int mo2);
|
||
extern unsigned int __atomic_exchange_4(unsigned int* x, unsigned int y, int mo);
|
||
extern unsigned int __atomic_fetch_add_4(unsigned int* x, unsigned int y, int mo);
|
||
extern unsigned int __atomic_fetch_sub_4(unsigned int* x, unsigned int y, int mo);
|
||
extern unsigned int __atomic_fetch_and_4(unsigned int* x, unsigned int y, int mo);
|
||
extern unsigned int __atomic_fetch_or_4(unsigned int* x, unsigned int y, int mo);
|
||
extern unsigned int __atomic_fetch_xor_4(unsigned int* x, unsigned int y, int mo);
|
||
|
||
extern unsigned short __atomic_load_2(unsigned short* x, int mo);
|
||
extern void __atomic_store_2(unsigned short* x, unsigned short y, int mo);
|
||
extern _Bool __atomic_compare_exchange_2(unsigned short* x, unsigned short* expected, unsigned short y, int mo, int mo2);
|
||
extern _Bool __atomic_compare_exchange_2(unsigned short* x, unsigned short* expected, unsigned short y, int mo, int mo2);
|
||
extern unsigned short __atomic_exchange_2(unsigned short* x, unsigned short y, int mo);
|
||
extern unsigned short __atomic_fetch_add_2(unsigned short* x, unsigned short y, int mo);
|
||
extern unsigned short __atomic_fetch_sub_2(unsigned short* x, unsigned short y, int mo);
|
||
extern unsigned short __atomic_fetch_and_2(unsigned short* x, unsigned short y, int mo);
|
||
extern unsigned short __atomic_fetch_or_2(unsigned short* x, unsigned short y, int mo);
|
||
extern unsigned short __atomic_fetch_xor_2(unsigned short* x, unsigned short y, int mo);
|
||
|
||
extern unsigned char __atomic_load_1(unsigned char* x, int mo);
|
||
extern void __atomic_store_1(unsigned char* x, unsigned char y, int mo);
|
||
extern _Bool __atomic_compare_exchange_1(unsigned char* x, unsigned char* expected, unsigned char y, int mo, int mo2);
|
||
extern _Bool __atomic_compare_exchange_1(unsigned char* x, unsigned char* expected, unsigned char y, int mo, int mo2);
|
||
extern unsigned char __atomic_exchange_1(unsigned char* x, unsigned char y, int mo);
|
||
extern unsigned char __atomic_fetch_add_1(unsigned char* x, unsigned char y, int mo);
|
||
extern unsigned char __atomic_fetch_sub_1(unsigned char* x, unsigned char y, int mo);
|
||
extern unsigned char __atomic_fetch_and_1(unsigned char* x, unsigned char y, int mo);
|
||
extern unsigned char __atomic_fetch_or_1(unsigned char* x, unsigned char y, int mo);
|
||
extern unsigned char __atomic_fetch_xor_1(unsigned char* x, unsigned char y, int mo);
|
||
|
||
// The default functions should work with pointers so we have to decide based on pointer size
|
||
#if UINTPTR_MAX == 0xFFFFFFFF
|
||
|
||
#define atomic_load_explicit __atomic_load_4
|
||
#define atomic_store_explicit __atomic_store_4
|
||
#define atomic_compare_exchange_weak_explicit __atomic_compare_exchange_4
|
||
#define atomic_compare_exchange_strong_explicit __atomic_compare_exchange_4
|
||
#define atomic_exchange_explicit __atomic_exchange_4
|
||
#define atomic_fetch_add_explicit __atomic_fetch_add_4
|
||
#define atomic_fetch_sub_explicit __atomic_sub_fetch_4
|
||
|
||
#else
|
||
|
||
#define atomic_load_explicit __atomic_load_8
|
||
#define atomic_store_explicit __atomic_store_8
|
||
#define atomic_compare_exchange_weak_explicit __atomic_compare_exchange_8
|
||
#define atomic_compare_exchange_strong_explicit __atomic_compare_exchange_8
|
||
#define atomic_exchange_explicit __atomic_exchange_8
|
||
#define atomic_fetch_add_explicit __atomic_fetch_add_8
|
||
#define atomic_fetch_sub_explicit __atomic_sub_fetch_8
|
||
|
||
#endif
|
||
|
||
// memory order policies - we use "sequentially consistent" by default
|
||
|
||
#define memory_order_relaxed 0
|
||
#define memory_order_consume 1
|
||
#define memory_order_acquire 2
|
||
#define memory_order_release 3
|
||
#define memory_order_acq_rel 4
|
||
#define memory_order_seq_cst 5
|
||
|
||
static inline void** atomic_load(void** x) {
|
||
return (void**)atomic_load_explicit((unsigned long long*)x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store(void** x, void* y) {
|
||
atomic_store_explicit((unsigned long long*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak(void** x, void** expected, void* y) {
|
||
return (int)atomic_compare_exchange_weak_explicit((unsigned long long*)x, (unsigned long long*)expected, (uintptr_t)y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong(void** x, void** expected, void* y) {
|
||
return (int)atomic_compare_exchange_strong_explicit((unsigned long long*)x, (unsigned long long*)expected, (uintptr_t)y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline uintptr_t atomic_exchange(void** x, void* y) {
|
||
return atomic_exchange_explicit((unsigned long long*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline uintptr_t atomic_fetch_add(uintptr_t* x, uintptr_t y) {
|
||
return atomic_fetch_add_explicit(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline uintptr_t atomic_fetch_sub(uintptr_t* x, uintptr_t y) {
|
||
return atomic_fetch_sub_explicit(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline uintptr_t atomic_fetch_and(uintptr_t* x, uintptr_t y) {
|
||
return atomic_fetch_and_explicit(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline uintptr_t atomic_fetch_or(uintptr_t* x, uintptr_t y) {
|
||
return atomic_fetch_or_explicit(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline uintptr_t atomic_fetch_xor(uintptr_t* x, uintptr_t y) {
|
||
return atomic_fetch_xor_explicit(x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
#define atomic_load_ptr atomic_load
|
||
#define atomic_store_ptr atomic_store
|
||
#define atomic_compare_exchange_weak_ptr atomic_compare_exchange_weak
|
||
#define atomic_compare_exchange_strong_ptr atomic_compare_exchange_strong
|
||
#define atomic_exchange_ptr atomic_exchange
|
||
#define atomic_fetch_add_ptr atomic_fetch_add
|
||
#define atomic_fetch_sub_ptr atomic_fetch_sub
|
||
#define atomic_fetch_and_ptr atomic_fetch_and
|
||
#define atomic_fetch_or_ptr atomic_fetch_or
|
||
#define atomic_fetch_xor_ptr atomic_fetch_xor
|
||
|
||
// specialized versions for 64 bit
|
||
|
||
static inline unsigned long long atomic_load_u64(unsigned long long* x) {
|
||
return __atomic_load_8(x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_u64(unsigned long long* x, unsigned long long y) {
|
||
__atomic_store_8(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_u64(unsigned long long* x, unsigned long long* expected, unsigned long long y) {
|
||
return (int)__atomic_compare_exchange_8(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_u64(unsigned long long* x, unsigned long long* expected, unsigned long long y) {
|
||
return (int)__atomic_compare_exchange_8(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_exchange_u64(unsigned long long* x, unsigned long long y) {
|
||
return __atomic_exchange_8(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_add_u64(unsigned long long* x, unsigned long long y) {
|
||
return __atomic_fetch_add_8(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_sub_u64(unsigned long long* x, unsigned long long y) {
|
||
return __atomic_fetch_sub_8(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_and_u64(unsigned long long* x, unsigned long long y) {
|
||
return __atomic_fetch_and_8(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_or_u64(unsigned long long* x, unsigned long long y) {
|
||
return __atomic_fetch_or_8(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_xor_u64(unsigned long long* x, unsigned long long y) {
|
||
return __atomic_fetch_xor_8(x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
static inline unsigned atomic_load_u32(unsigned* x) {
|
||
return __atomic_load_4(x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_u32(unsigned* x, unsigned y) {
|
||
__atomic_store_4(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_u32(unsigned* x, unsigned* expected, unsigned y) {
|
||
return (int)__atomic_compare_exchange_4(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_u32(unsigned* x, unsigned* expected, unsigned y) {
|
||
return (int)__atomic_compare_exchange_4(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_exchange_u32(unsigned* x, unsigned y) {
|
||
return __atomic_exchange_4(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_add_u32(unsigned* x, unsigned y) {
|
||
return __atomic_fetch_add_4(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_sub_u32(unsigned* x, unsigned y) {
|
||
return __atomic_fetch_sub_4(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_and_u32(unsigned* x, unsigned y) {
|
||
return __atomic_fetch_and_4(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_or_u32(unsigned* x, unsigned y) {
|
||
return __atomic_fetch_or_4(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_xor_u32(unsigned* x, unsigned y) {
|
||
return __atomic_fetch_xor_4(x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
static inline unsigned short atomic_load_u16(unsigned short* x) {
|
||
return __atomic_load_2(x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_u16(void* x, unsigned short y) {
|
||
__atomic_store_2(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_u16(void* x, unsigned short* expected, unsigned short y) {
|
||
return (int)__atomic_compare_exchange_2(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_u16(unsigned short* x, unsigned short* expected, unsigned short y) {
|
||
return (int)__atomic_compare_exchange_2(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_exchange_u16(unsigned short* x, unsigned short y) {
|
||
return __atomic_exchange_2(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_add_u16(unsigned short* x, unsigned short y) {
|
||
return __atomic_fetch_add_2(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_sub_u16(unsigned short* x, unsigned short y) {
|
||
return __atomic_fetch_sub_2(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_and_u16(unsigned short* x, unsigned short y) {
|
||
return __atomic_fetch_and_2(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_or_u16(unsigned short* x, unsigned short y) {
|
||
return __atomic_fetch_or_2(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_xor_u16(unsigned short* x, unsigned short y) {
|
||
return __atomic_fetch_xor_2(x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
static inline unsigned char atomic_load_byte(unsigned char* x) {
|
||
return __atomic_load_1(x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_byte(unsigned char* x, unsigned char y) {
|
||
__atomic_store_1(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_byte(unsigned char* x, unsigned char* expected, unsigned char y) {
|
||
return __atomic_compare_exchange_1(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_byte(unsigned char* x, unsigned char* expected, unsigned char y) {
|
||
return __atomic_compare_exchange_1(x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_exchange_byte(unsigned char* x, unsigned char y) {
|
||
return __atomic_exchange_1(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_add_byte(unsigned char* x, unsigned char y) {
|
||
return __atomic_fetch_add_1(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_sub_byte(unsigned char* x, unsigned char y) {
|
||
return __atomic_fetch_sub_1(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_and_byte(unsigned char* x, unsigned char y) {
|
||
return __atomic_fetch_and_1(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_or_byte(unsigned char* x, unsigned char y) {
|
||
return __atomic_fetch_or_1(x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_xor_byte(unsigned char* x, unsigned char y) {
|
||
return __atomic_fetch_xor_1(x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
#else
|
||
|
||
// Since V might be confused with "generic" C functions either we provide special versions
|
||
// for gcc/clang, too
|
||
static inline unsigned long long atomic_load_u64(unsigned long long* x) {
|
||
return atomic_load_explicit((_Atomic (unsigned long long)*)x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_u64(unsigned long long* x, unsigned long long y) {
|
||
atomic_store_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_u64(unsigned long long* x, unsigned long long* expected, unsigned long long y) {
|
||
return (int)atomic_compare_exchange_weak_explicit((_Atomic(unsigned long long)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_u64(unsigned long long* x, unsigned long long* expected, unsigned long long y) {
|
||
return (int)atomic_compare_exchange_strong_explicit((_Atomic(unsigned long long)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_exchange_u64(unsigned long long* x, unsigned long long y) {
|
||
return atomic_exchange_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_add_u64(unsigned long long* x, unsigned long long y) {
|
||
return atomic_fetch_add_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_sub_u64(unsigned long long* x, unsigned long long y) {
|
||
return atomic_fetch_sub_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_and_u64(unsigned long long* x, unsigned long long y) {
|
||
return atomic_fetch_and_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_or_u64(unsigned long long* x, unsigned long long y) {
|
||
return atomic_fetch_or_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned long long atomic_fetch_xor_u64(unsigned long long* x, unsigned long long y) {
|
||
return atomic_fetch_xor_explicit((_Atomic(unsigned long long)*)x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
|
||
static inline void* atomic_load_ptr(void** x) {
|
||
return (void*)atomic_load_explicit((_Atomic(uintptr_t)*)x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_ptr(void** x, void* y) {
|
||
atomic_store_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_ptr(void** x, void** expected, void* y) {
|
||
return (int)atomic_compare_exchange_weak_explicit((_Atomic(uintptr_t)*)x, (unsigned long *)expected, (uintptr_t)y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_ptr(void** x, void** expected, void* y) {
|
||
return (int)atomic_compare_exchange_strong_explicit((_Atomic(uintptr_t)*)x, (unsigned long *)expected, (uintptr_t)y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline void* atomic_exchange_ptr(void** x, void* y) {
|
||
return (void*)atomic_exchange_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline void* atomic_fetch_add_ptr(void** x, void* y) {
|
||
return (void*)atomic_fetch_add_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline void* atomic_fetch_sub_ptr(void** x, void* y) {
|
||
return (void*)atomic_fetch_sub_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline void* atomic_fetch_and_ptr(void** x, void* y) {
|
||
return (void*)atomic_fetch_and_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline void* atomic_fetch_or_ptr(void** x, void* y) {
|
||
return (void*)atomic_fetch_or_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
static inline void* atomic_fetch_xor_ptr(void** x, void* y) {
|
||
return (void*)atomic_fetch_xor_explicit((_Atomic(uintptr_t)*)x, (uintptr_t)y, memory_order_seq_cst);
|
||
}
|
||
|
||
|
||
static inline unsigned atomic_load_u32(unsigned* x) {
|
||
return atomic_load_explicit((_Atomic(unsigned)*)x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_u32(unsigned* x, unsigned y) {
|
||
atomic_store_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_u32(unsigned* x, unsigned* expected, unsigned y) {
|
||
return (int)atomic_compare_exchange_weak_explicit((_Atomic(unsigned)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_u32(unsigned* x, unsigned* expected, unsigned y) {
|
||
return (int)atomic_compare_exchange_strong_explicit((_Atomic(unsigned)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_exchange_u32(unsigned* x, unsigned y) {
|
||
return atomic_exchange_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_add_u32(unsigned* x, unsigned y) {
|
||
return atomic_fetch_add_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_sub_u32(unsigned* x, unsigned y) {
|
||
return atomic_fetch_sub_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_and_u32(unsigned* x, unsigned y) {
|
||
return atomic_fetch_and_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_or_u32(unsigned* x, unsigned y) {
|
||
return atomic_fetch_or_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned atomic_fetch_xor_u32(unsigned* x, unsigned y) {
|
||
return atomic_fetch_xor_explicit((_Atomic(unsigned)*)x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
static inline unsigned short atomic_load_u16(unsigned short* x) {
|
||
return atomic_load_explicit((_Atomic(unsigned short)*)x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_u16(void* x, unsigned short y) {
|
||
atomic_store_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_u16(void* x, unsigned short* expected, unsigned short y) {
|
||
return (int)atomic_compare_exchange_weak_explicit((_Atomic(unsigned short)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_u16(unsigned short* x, unsigned short* expected, unsigned short y) {
|
||
return (int)atomic_compare_exchange_strong_explicit((_Atomic(unsigned short)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_exchange_u16(unsigned short* x, unsigned short y) {
|
||
return atomic_exchange_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_add_u16(unsigned short* x, unsigned short y) {
|
||
return atomic_fetch_add_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_sub_u16(unsigned short* x, unsigned short y) {
|
||
return atomic_fetch_sub_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_and_u16(unsigned short* x, unsigned short y) {
|
||
return atomic_fetch_and_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_or_u16(unsigned short* x, unsigned short y) {
|
||
return atomic_fetch_or_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned short atomic_fetch_xor_u16(unsigned short* x, unsigned short y) {
|
||
return atomic_fetch_xor_explicit((_Atomic(unsigned short)*)x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
static inline unsigned char atomic_load_byte(unsigned char* x) {
|
||
return atomic_load_explicit((_Atomic(unsigned char)*)x, memory_order_seq_cst);
|
||
}
|
||
static inline void atomic_store_byte(unsigned char* x, unsigned char y) {
|
||
atomic_store_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_weak_byte(unsigned char* x, unsigned char* expected, unsigned char y) {
|
||
return (int)atomic_compare_exchange_weak_explicit((_Atomic(unsigned char)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline int atomic_compare_exchange_strong_byte(unsigned char* x, unsigned char* expected, unsigned char y) {
|
||
return (int)atomic_compare_exchange_strong_explicit((_Atomic(unsigned char)*)x, expected, y, memory_order_seq_cst, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_exchange_byte(unsigned char* x, unsigned char y) {
|
||
return atomic_exchange_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_add_byte(unsigned char* x, unsigned char y) {
|
||
return atomic_fetch_add_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_sub_byte(unsigned char* x, unsigned char y) {
|
||
return atomic_fetch_sub_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_and_byte(unsigned char* x, unsigned char y) {
|
||
return atomic_fetch_and_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_or_byte(unsigned char* x, unsigned char y) {
|
||
return atomic_fetch_or_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
static inline unsigned char atomic_fetch_xor_byte(unsigned char* x, unsigned char y) {
|
||
return atomic_fetch_xor_explicit((_Atomic(unsigned char)*)x, y, memory_order_seq_cst);
|
||
}
|
||
|
||
#endif
|
||
#endif
|
||
|
||
#endif // $if 1
|
||
|
||
|
||
// added by module `os`, file: os.c.v:3:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<sys/stat.h>)
|
||
#include <sys/stat.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <sys/stat.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <sys/stat.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os.c.v:4:
|
||
#include <errno.h>
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os_nix.c.v:5:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<dirent.h>)
|
||
#include <dirent.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <dirent.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <dirent.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os_nix.c.v:6:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<unistd.h>)
|
||
#include <unistd.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <unistd.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <unistd.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os_nix.c.v:7:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<fcntl.h>)
|
||
#include <fcntl.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <fcntl.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <fcntl.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os_nix.c.v:8:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<sys/utsname.h>)
|
||
#include <sys/utsname.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <sys/utsname.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <sys/utsname.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os_nix.c.v:9:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<sys/types.h>)
|
||
#include <sys/types.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <sys/types.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <sys/types.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: os_nix.c.v:10:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<utime.h>)
|
||
#include <utime.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <utime.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <utime.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
#if !defined(__sun) && !defined(__HAIKU__)
|
||
// added by module `os`, file: os_nix.c.v:12:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<sys/ptrace.h>)
|
||
#include <sys/ptrace.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <sys/ptrace.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <sys/ptrace.h>
|
||
#endif
|
||
|
||
#endif // $if !defined(__sun) && !defined(__HAIKU__)
|
||
|
||
|
||
|
||
|
||
// added by module `os`, file: signal.c.v:3:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<signal.h>)
|
||
#include <signal.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <signal.h>, needed for module `os` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <signal.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `term`, file: term_nix.c.v:5:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<sys/ioctl.h>)
|
||
#include <sys/ioctl.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <sys/ioctl.h>, needed for module `term` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <sys/ioctl.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `term`, file: term_nix.c.v:6:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<termios.h>)
|
||
#include <termios.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <termios.h>, needed for module `term` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <termios.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
|
||
// added by module `sync`, file: sync_default.c.v:14:
|
||
|
||
#if defined(__has_include)
|
||
|
||
#if __has_include(<semaphore.h>)
|
||
#include <semaphore.h>
|
||
#else
|
||
#error VERROR_MESSAGE Header file <semaphore.h>, needed for module `sync` was not found. Please install the corresponding development headers.
|
||
#endif
|
||
|
||
#else
|
||
#include <semaphore.h>
|
||
#endif
|
||
|
||
|
||
|
||
|
||
// Enum definitions:
|
||
typedef enum {
|
||
strconv__ParserState__ok, //
|
||
strconv__ParserState__pzero, // +1
|
||
strconv__ParserState__mzero, // +2
|
||
strconv__ParserState__pinf, // +3
|
||
strconv__ParserState__minf, // +4
|
||
strconv__ParserState__invalid_number, // +5
|
||
} strconv__ParserState;
|
||
|
||
typedef enum {
|
||
strconv__Align_text__right = 0, // 0
|
||
strconv__Align_text__left, // 0+1
|
||
strconv__Align_text__center, // 0+2
|
||
} strconv__Align_text;
|
||
|
||
typedef enum {
|
||
strconv__Char_parse_state__start, //
|
||
strconv__Char_parse_state__norm_char, // +1
|
||
strconv__Char_parse_state__field_char, // +2
|
||
strconv__Char_parse_state__pad_ch, // +3
|
||
strconv__Char_parse_state__len_set_start, // +4
|
||
strconv__Char_parse_state__len_set_in, // +5
|
||
strconv__Char_parse_state__check_type, // +6
|
||
strconv__Char_parse_state__check_float, // +7
|
||
strconv__Char_parse_state__check_float_in, // +8
|
||
strconv__Char_parse_state__reset_params, // +9
|
||
} strconv__Char_parse_state;
|
||
|
||
typedef enum {
|
||
ArrayFlags__noslices = 1, // 1 << 0
|
||
ArrayFlags__noshrink = 2, // 1 << 1
|
||
} ArrayFlags;
|
||
|
||
typedef enum {
|
||
AttributeKind__plain, //
|
||
AttributeKind__string, // +1
|
||
AttributeKind__number, // +2
|
||
AttributeKind__comptime_define, // +3
|
||
} AttributeKind;
|
||
|
||
typedef enum {
|
||
ChanState__success, //
|
||
ChanState__not_ready, // +1
|
||
ChanState__closed, // +2
|
||
} ChanState;
|
||
|
||
typedef enum {
|
||
StrIntpType__si_no_str = 0, // 0
|
||
StrIntpType__si_c, // 0+1
|
||
StrIntpType__si_u8, // 0+2
|
||
StrIntpType__si_i8, // 0+3
|
||
StrIntpType__si_u16, // 0+4
|
||
StrIntpType__si_i16, // 0+5
|
||
StrIntpType__si_u32, // 0+6
|
||
StrIntpType__si_i32, // 0+7
|
||
StrIntpType__si_u64, // 0+8
|
||
StrIntpType__si_i64, // 0+9
|
||
StrIntpType__si_e32, // 0+10
|
||
StrIntpType__si_e64, // 0+11
|
||
StrIntpType__si_f32, // 0+12
|
||
StrIntpType__si_f64, // 0+13
|
||
StrIntpType__si_g32, // 0+14
|
||
StrIntpType__si_g64, // 0+15
|
||
StrIntpType__si_s, // 0+16
|
||
StrIntpType__si_p, // 0+17
|
||
StrIntpType__si_vp, // 0+18
|
||
} StrIntpType;
|
||
|
||
typedef enum {
|
||
v__token__Kind__unknown, //
|
||
v__token__Kind__eof, // +1
|
||
v__token__Kind__name, // +2
|
||
v__token__Kind__number, // +3
|
||
v__token__Kind__string, // +4
|
||
v__token__Kind__str_inter, // +5
|
||
v__token__Kind__chartoken, // +6
|
||
v__token__Kind__plus, // +7
|
||
v__token__Kind__minus, // +8
|
||
v__token__Kind__mul, // +9
|
||
v__token__Kind__div, // +10
|
||
v__token__Kind__mod, // +11
|
||
v__token__Kind__xor, // +12
|
||
v__token__Kind__pipe, // +13
|
||
v__token__Kind__inc, // +14
|
||
v__token__Kind__dec, // +15
|
||
v__token__Kind__and, // +16
|
||
v__token__Kind__logical_or, // +17
|
||
v__token__Kind__not, // +18
|
||
v__token__Kind__bit_not, // +19
|
||
v__token__Kind__question, // +20
|
||
v__token__Kind__comma, // +21
|
||
v__token__Kind__semicolon, // +22
|
||
v__token__Kind__colon, // +23
|
||
v__token__Kind__arrow, // +24
|
||
v__token__Kind__amp, // +25
|
||
v__token__Kind__hash, // +26
|
||
v__token__Kind__dollar, // +27
|
||
v__token__Kind__at, // +28
|
||
v__token__Kind__str_dollar, // +29
|
||
v__token__Kind__left_shift, // +30
|
||
v__token__Kind__right_shift, // +31
|
||
v__token__Kind__unsigned_right_shift, // +32
|
||
v__token__Kind__not_in, // +33
|
||
v__token__Kind__not_is, // +34
|
||
v__token__Kind__assign, // +35
|
||
v__token__Kind__decl_assign, // +36
|
||
v__token__Kind__plus_assign, // +37
|
||
v__token__Kind__minus_assign, // +38
|
||
v__token__Kind__div_assign, // +39
|
||
v__token__Kind__mult_assign, // +40
|
||
v__token__Kind__xor_assign, // +41
|
||
v__token__Kind__mod_assign, // +42
|
||
v__token__Kind__or_assign, // +43
|
||
v__token__Kind__and_assign, // +44
|
||
v__token__Kind__right_shift_assign, // +45
|
||
v__token__Kind__left_shift_assign, // +46
|
||
v__token__Kind__unsigned_right_shift_assign, // +47
|
||
v__token__Kind__lcbr, // +48
|
||
v__token__Kind__rcbr, // +49
|
||
v__token__Kind__lpar, // +50
|
||
v__token__Kind__rpar, // +51
|
||
v__token__Kind__lsbr, // +52
|
||
v__token__Kind__nilsbr, // +53
|
||
v__token__Kind__rsbr, // +54
|
||
v__token__Kind__eq, // +55
|
||
v__token__Kind__ne, // +56
|
||
v__token__Kind__gt, // +57
|
||
v__token__Kind__lt, // +58
|
||
v__token__Kind__ge, // +59
|
||
v__token__Kind__le, // +60
|
||
v__token__Kind__comment, // +61
|
||
v__token__Kind__nl, // +62
|
||
v__token__Kind__dot, // +63
|
||
v__token__Kind__dotdot, // +64
|
||
v__token__Kind__ellipsis, // +65
|
||
v__token__Kind__keyword_beg, // +66
|
||
v__token__Kind__key_as, // +67
|
||
v__token__Kind__key_asm, // +68
|
||
v__token__Kind__key_assert, // +69
|
||
v__token__Kind__key_atomic, // +70
|
||
v__token__Kind__key_break, // +71
|
||
v__token__Kind__key_const, // +72
|
||
v__token__Kind__key_continue, // +73
|
||
v__token__Kind__key_defer, // +74
|
||
v__token__Kind__key_else, // +75
|
||
v__token__Kind__key_enum, // +76
|
||
v__token__Kind__key_false, // +77
|
||
v__token__Kind__key_for, // +78
|
||
v__token__Kind__key_fn, // +79
|
||
v__token__Kind__key_global, // +80
|
||
v__token__Kind__key_go, // +81
|
||
v__token__Kind__key_goto, // +82
|
||
v__token__Kind__key_if, // +83
|
||
v__token__Kind__key_import, // +84
|
||
v__token__Kind__key_in, // +85
|
||
v__token__Kind__key_interface, // +86
|
||
v__token__Kind__key_is, // +87
|
||
v__token__Kind__key_match, // +88
|
||
v__token__Kind__key_module, // +89
|
||
v__token__Kind__key_mut, // +90
|
||
v__token__Kind__key_shared, // +91
|
||
v__token__Kind__key_lock, // +92
|
||
v__token__Kind__key_rlock, // +93
|
||
v__token__Kind__key_none, // +94
|
||
v__token__Kind__key_return, // +95
|
||
v__token__Kind__key_select, // +96
|
||
v__token__Kind__key_sizeof, // +97
|
||
v__token__Kind__key_isreftype, // +98
|
||
v__token__Kind__key_likely, // +99
|
||
v__token__Kind__key_unlikely, // +100
|
||
v__token__Kind__key_offsetof, // +101
|
||
v__token__Kind__key_struct, // +102
|
||
v__token__Kind__key_true, // +103
|
||
v__token__Kind__key_type, // +104
|
||
v__token__Kind__key_typeof, // +105
|
||
v__token__Kind__key_dump, // +106
|
||
v__token__Kind__key_orelse, // +107
|
||
v__token__Kind__key_union, // +108
|
||
v__token__Kind__key_pub, // +109
|
||
v__token__Kind__key_static, // +110
|
||
v__token__Kind__key_volatile, // +111
|
||
v__token__Kind__key_unsafe, // +112
|
||
v__token__Kind__keyword_end, // +113
|
||
v__token__Kind___end_, // +114
|
||
} v__token__Kind;
|
||
|
||
typedef enum {
|
||
v__token__AtKind__unknown, //
|
||
v__token__AtKind__fn_name, // +1
|
||
v__token__AtKind__method_name, // +2
|
||
v__token__AtKind__mod_name, // +3
|
||
v__token__AtKind__struct_name, // +4
|
||
v__token__AtKind__vexe_path, // +5
|
||
v__token__AtKind__file_path, // +6
|
||
v__token__AtKind__line_nr, // +7
|
||
v__token__AtKind__column_nr, // +8
|
||
v__token__AtKind__vhash, // +9
|
||
v__token__AtKind__vmod_file, // +10
|
||
v__token__AtKind__vmodroot_path, // +11
|
||
v__token__AtKind__vroot_path, // +12
|
||
v__token__AtKind__vexeroot_path, // +13
|
||
} v__token__AtKind;
|
||
|
||
typedef enum {
|
||
v__token__Precedence__lowest, //
|
||
v__token__Precedence__cond, // +1
|
||
v__token__Precedence__in_as, // +2
|
||
v__token__Precedence__assign, // +3
|
||
v__token__Precedence__eq, // +4
|
||
v__token__Precedence__sum, // +5
|
||
v__token__Precedence__product, // +6
|
||
v__token__Precedence__prefix, // +7
|
||
v__token__Precedence__postfix, // +8
|
||
v__token__Precedence__call, // +9
|
||
v__token__Precedence__index, // +10
|
||
} v__token__Precedence;
|
||
|
||
typedef enum {
|
||
time__FormatTime__hhmm12, //
|
||
time__FormatTime__hhmm24, // +1
|
||
time__FormatTime__hhmmss12, // +2
|
||
time__FormatTime__hhmmss24, // +3
|
||
time__FormatTime__hhmmss24_milli, // +4
|
||
time__FormatTime__hhmmss24_micro, // +5
|
||
time__FormatTime__no_time, // +6
|
||
} time__FormatTime;
|
||
|
||
typedef enum {
|
||
time__FormatDate__ddmmyy, //
|
||
time__FormatDate__ddmmyyyy, // +1
|
||
time__FormatDate__mmddyy, // +2
|
||
time__FormatDate__mmddyyyy, // +3
|
||
time__FormatDate__mmmd, // +4
|
||
time__FormatDate__mmmdd, // +5
|
||
time__FormatDate__mmmddyy, // +6
|
||
time__FormatDate__mmmddyyyy, // +7
|
||
time__FormatDate__no_date, // +8
|
||
time__FormatDate__yyyymmdd, // +9
|
||
time__FormatDate__yymmdd, // +10
|
||
} time__FormatDate;
|
||
|
||
typedef enum {
|
||
time__FormatDelimiter__dot, //
|
||
time__FormatDelimiter__hyphen, // +1
|
||
time__FormatDelimiter__slash, // +2
|
||
time__FormatDelimiter__space, // +3
|
||
time__FormatDelimiter__no_delimiter, // +4
|
||
} time__FormatDelimiter;
|
||
|
||
typedef enum {
|
||
semver__Operator__gt, //
|
||
semver__Operator__lt, // +1
|
||
semver__Operator__ge, // +2
|
||
semver__Operator__le, // +3
|
||
semver__Operator__eq, // +4
|
||
} semver__Operator;
|
||
|
||
typedef enum {
|
||
semver__Increment__major, //
|
||
semver__Increment__minor, // +1
|
||
semver__Increment__patch, // +2
|
||
} semver__Increment;
|
||
|
||
typedef enum {
|
||
os__SeekMode__start, //
|
||
os__SeekMode__current, // +1
|
||
os__SeekMode__end, // +2
|
||
} os__SeekMode;
|
||
|
||
typedef enum {
|
||
os__FileType__regular, //
|
||
os__FileType__directory, // +1
|
||
os__FileType__character_device, // +2
|
||
os__FileType__block_device, // +3
|
||
os__FileType__fifo, // +4
|
||
os__FileType__symbolic_link, // +5
|
||
os__FileType__socket, // +6
|
||
} os__FileType;
|
||
|
||
typedef enum {
|
||
os__GlobMatch__exact, //
|
||
os__GlobMatch__ends_with, // +1
|
||
os__GlobMatch__starts_with, // +2
|
||
os__GlobMatch__start_and_ends_with, // +3
|
||
os__GlobMatch__contains, // +4
|
||
os__GlobMatch__any, // +5
|
||
} os__GlobMatch;
|
||
|
||
typedef enum {
|
||
os__ProcessState__not_started, //
|
||
os__ProcessState__running, // +1
|
||
os__ProcessState__stopped, // +2
|
||
os__ProcessState__exited, // +3
|
||
os__ProcessState__aborted, // +4
|
||
os__ProcessState__closed, // +5
|
||
} os__ProcessState;
|
||
|
||
typedef enum {
|
||
os__Signal__hup = 1, // 1
|
||
os__Signal__int = 2, // 2
|
||
os__Signal__quit = 3, // 3
|
||
os__Signal__ill = 4, // 4
|
||
os__Signal__trap = 5, // 5
|
||
os__Signal__abrt = 6, // 6
|
||
os__Signal__bus = 7, // 7
|
||
os__Signal__fpe = 8, // 8
|
||
os__Signal__kill = 9, // 9
|
||
os__Signal__usr1 = 10, // 10
|
||
os__Signal__segv = 11, // 11
|
||
os__Signal__usr2 = 12, // 12
|
||
os__Signal__pipe = 13, // 13
|
||
os__Signal__alrm = 14, // 14
|
||
os__Signal__term = 15, // 15
|
||
os__Signal__stkflt = 16, // 16
|
||
os__Signal__chld = 17, // 17
|
||
os__Signal__cont = 18, // 18
|
||
os__Signal__stop = 19, // 19
|
||
os__Signal__tstp = 20, // 20
|
||
os__Signal__ttin = 21, // 21
|
||
os__Signal__ttou = 22, // 22
|
||
os__Signal__urg = 23, // 23
|
||
os__Signal__xcpu = 24, // 24
|
||
os__Signal__xfsz = 25, // 25
|
||
os__Signal__vtalrm = 26, // 26
|
||
os__Signal__prof = 27, // 27
|
||
os__Signal__winch = 28, // 28
|
||
os__Signal__poll = 29, // 29
|
||
os__Signal__pwr = 30, // 30
|
||
os__Signal__sys = 31, // 31
|
||
} os__Signal;
|
||
|
||
typedef enum {
|
||
v__errors__Reporter__scanner, //
|
||
v__errors__Reporter__parser, // +1
|
||
v__errors__Reporter__checker, // +2
|
||
v__errors__Reporter__builder, // +3
|
||
v__errors__Reporter__gen, // +4
|
||
} v__errors__Reporter;
|
||
|
||
typedef enum {
|
||
v__vet__ErrorKind__error, //
|
||
v__vet__ErrorKind__warning, // +1
|
||
} v__vet__ErrorKind;
|
||
|
||
typedef enum {
|
||
v__vet__FixKind__unknown, //
|
||
v__vet__FixKind__doc, // +1
|
||
v__vet__FixKind__vfmt, // +2
|
||
} v__vet__FixKind;
|
||
|
||
typedef enum {
|
||
v__vet__ErrorType__default, //
|
||
v__vet__ErrorType__space_indent, // +1
|
||
v__vet__ErrorType__trailing_space, // +2
|
||
} v__vet__ErrorType;
|
||
|
||
typedef enum {
|
||
v__vmod__TokenKind__module_keyword, //
|
||
v__vmod__TokenKind__field_key, // +1
|
||
v__vmod__TokenKind__lcbr, // +2
|
||
v__vmod__TokenKind__rcbr, // +3
|
||
v__vmod__TokenKind__labr, // +4
|
||
v__vmod__TokenKind__rabr, // +5
|
||
v__vmod__TokenKind__comma, // +6
|
||
v__vmod__TokenKind__colon, // +7
|
||
v__vmod__TokenKind__eof, // +8
|
||
v__vmod__TokenKind__str, // +9
|
||
v__vmod__TokenKind__ident, // +10
|
||
v__vmod__TokenKind__unknown, // +11
|
||
} v__vmod__TokenKind;
|
||
|
||
typedef enum {
|
||
v__pref__OS___auto, //
|
||
v__pref__OS__ios, // +1
|
||
v__pref__OS__macos, // +2
|
||
v__pref__OS__linux, // +3
|
||
v__pref__OS__windows, // +4
|
||
v__pref__OS__freebsd, // +5
|
||
v__pref__OS__openbsd, // +6
|
||
v__pref__OS__netbsd, // +7
|
||
v__pref__OS__dragonfly, // +8
|
||
v__pref__OS__js_node, // +9
|
||
v__pref__OS__js_browser, // +10
|
||
v__pref__OS__js_freestanding, // +11
|
||
v__pref__OS__android, // +12
|
||
v__pref__OS__solaris, // +13
|
||
v__pref__OS__serenity, // +14
|
||
v__pref__OS__vinix, // +15
|
||
v__pref__OS__haiku, // +16
|
||
v__pref__OS__wasm32, // +17
|
||
v__pref__OS__wasm32_emscripten, // +18
|
||
v__pref__OS__wasm32_wasi, // +19
|
||
v__pref__OS__raw, // +20
|
||
v__pref__OS__all, // +21
|
||
} v__pref__OS;
|
||
|
||
typedef enum {
|
||
v__pref__BuildMode__default_mode, //
|
||
v__pref__BuildMode__build_module, // +1
|
||
} v__pref__BuildMode;
|
||
|
||
typedef enum {
|
||
v__pref__AssertFailureMode__default, //
|
||
v__pref__AssertFailureMode__aborts, // +1
|
||
v__pref__AssertFailureMode__backtraces, // +2
|
||
} v__pref__AssertFailureMode;
|
||
|
||
typedef enum {
|
||
v__pref__GarbageCollectionMode__unknown, //
|
||
v__pref__GarbageCollectionMode__no_gc, // +1
|
||
v__pref__GarbageCollectionMode__boehm_full, // +2
|
||
v__pref__GarbageCollectionMode__boehm_incr, // +3
|
||
v__pref__GarbageCollectionMode__boehm_full_opt, // +4
|
||
v__pref__GarbageCollectionMode__boehm_incr_opt, // +5
|
||
v__pref__GarbageCollectionMode__boehm_leak, // +6
|
||
} v__pref__GarbageCollectionMode;
|
||
|
||
typedef enum {
|
||
v__pref__OutputMode__stdout, //
|
||
v__pref__OutputMode__silent, // +1
|
||
} v__pref__OutputMode;
|
||
|
||
typedef enum {
|
||
v__pref__ColorOutput__auto, //
|
||
v__pref__ColorOutput__always, // +1
|
||
v__pref__ColorOutput__never, // +2
|
||
} v__pref__ColorOutput;
|
||
|
||
typedef enum {
|
||
v__pref__Backend__c, //
|
||
v__pref__Backend__js_node, // +1
|
||
v__pref__Backend__js_browser, // +2
|
||
v__pref__Backend__js_freestanding, // +3
|
||
v__pref__Backend__native, // +4
|
||
v__pref__Backend__interpret, // +5
|
||
} v__pref__Backend;
|
||
|
||
typedef enum {
|
||
v__pref__CompilerType__gcc, //
|
||
v__pref__CompilerType__tinyc, // +1
|
||
v__pref__CompilerType__clang, // +2
|
||
v__pref__CompilerType__mingw, // +3
|
||
v__pref__CompilerType__msvc, // +4
|
||
v__pref__CompilerType__cplusplus, // +5
|
||
} v__pref__CompilerType;
|
||
|
||
typedef enum {
|
||
v__pref__Arch___auto, //
|
||
v__pref__Arch__amd64, // +1
|
||
v__pref__Arch__arm64, // +2
|
||
v__pref__Arch__arm32, // +3
|
||
v__pref__Arch__rv64, // +4
|
||
v__pref__Arch__rv32, // +5
|
||
v__pref__Arch__i386, // +6
|
||
v__pref__Arch__js_node, // +7
|
||
v__pref__Arch__js_browser, // +8
|
||
v__pref__Arch__js_freestanding, // +9
|
||
v__pref__Arch___max, // +10
|
||
} v__pref__Arch;
|
||
|
||
typedef enum {
|
||
sync__BufferElemStat__unused = 0, // 0
|
||
sync__BufferElemStat__writing, // 0+1
|
||
sync__BufferElemStat__written, // 0+2
|
||
sync__BufferElemStat__reading, // 0+3
|
||
} sync__BufferElemStat;
|
||
|
||
typedef enum {
|
||
sync__Direction__pop, //
|
||
sync__Direction__push, // +1
|
||
} sync__Direction;
|
||
|
||
typedef enum {
|
||
v__ast__ComptimeTypeKind__map_, //
|
||
v__ast__ComptimeTypeKind__int, // +1
|
||
v__ast__ComptimeTypeKind__float, // +2
|
||
v__ast__ComptimeTypeKind__struct_, // +3
|
||
v__ast__ComptimeTypeKind__iface, // +4
|
||
v__ast__ComptimeTypeKind__array, // +5
|
||
v__ast__ComptimeTypeKind__sum_type, // +6
|
||
v__ast__ComptimeTypeKind__enum_, // +7
|
||
} v__ast__ComptimeTypeKind;
|
||
|
||
typedef enum {
|
||
v__ast__GenericKindField__unknown, //
|
||
v__ast__GenericKindField__name, // +1
|
||
v__ast__GenericKindField__typ, // +2
|
||
} v__ast__GenericKindField;
|
||
|
||
typedef enum {
|
||
v__ast__IdentKind__unresolved, //
|
||
v__ast__IdentKind__blank_ident, // +1
|
||
v__ast__IdentKind__variable, // +2
|
||
v__ast__IdentKind__constant, // +3
|
||
v__ast__IdentKind__global, // +4
|
||
v__ast__IdentKind__function, // +5
|
||
} v__ast__IdentKind;
|
||
|
||
typedef enum {
|
||
v__ast__ComptimeForKind__methods, //
|
||
v__ast__ComptimeForKind__fields, // +1
|
||
v__ast__ComptimeForKind__attributes, // +2
|
||
} v__ast__ComptimeForKind;
|
||
|
||
typedef enum {
|
||
v__ast__AddressingMode__invalid, //
|
||
v__ast__AddressingMode__displacement, // +1
|
||
v__ast__AddressingMode__base, // +2
|
||
v__ast__AddressingMode__base_plus_displacement, // +3
|
||
v__ast__AddressingMode__index_times_scale_plus_displacement, // +4
|
||
v__ast__AddressingMode__base_plus_index_plus_displacement, // +5
|
||
v__ast__AddressingMode__base_plus_index_times_scale_plus_displacement, // +6
|
||
v__ast__AddressingMode__rip_plus_displacement, // +7
|
||
} v__ast__AddressingMode;
|
||
|
||
typedef enum {
|
||
v__ast__OrKind__absent, //
|
||
v__ast__OrKind__block, // +1
|
||
v__ast__OrKind__propagate_option, // +2
|
||
v__ast__OrKind__propagate_result, // +3
|
||
} v__ast__OrKind;
|
||
|
||
typedef enum {
|
||
v__ast__SqlStmtKind__insert, //
|
||
v__ast__SqlStmtKind__update, // +1
|
||
v__ast__SqlStmtKind__delete, // +2
|
||
v__ast__SqlStmtKind__create, // +3
|
||
v__ast__SqlStmtKind__drop, // +4
|
||
} v__ast__SqlStmtKind;
|
||
|
||
typedef enum {
|
||
v__ast__AttrKind__plain, //
|
||
v__ast__AttrKind__string, // +1
|
||
v__ast__AttrKind__number, // +2
|
||
v__ast__AttrKind__bool, // +3
|
||
v__ast__AttrKind__comptime_define, // +4
|
||
} v__ast__AttrKind;
|
||
|
||
typedef enum {
|
||
v__ast__Language__v, //
|
||
v__ast__Language__c, // +1
|
||
v__ast__Language__js, // +2
|
||
v__ast__Language__amd64, // +3
|
||
v__ast__Language__i386, // +4
|
||
v__ast__Language__arm64, // +5
|
||
v__ast__Language__arm32, // +6
|
||
v__ast__Language__rv64, // +7
|
||
v__ast__Language__rv32, // +8
|
||
} v__ast__Language;
|
||
|
||
typedef enum {
|
||
v__ast__TypeFlag__optional, //
|
||
v__ast__TypeFlag__result, // +1
|
||
v__ast__TypeFlag__variadic, // +2
|
||
v__ast__TypeFlag__generic, // +3
|
||
v__ast__TypeFlag__shared_f, // +4
|
||
v__ast__TypeFlag__atomic_f, // +5
|
||
} v__ast__TypeFlag;
|
||
|
||
typedef enum {
|
||
v__ast__ShareType__mut_t, //
|
||
v__ast__ShareType__shared_t, // +1
|
||
v__ast__ShareType__atomic_t, // +2
|
||
} v__ast__ShareType;
|
||
|
||
typedef enum {
|
||
v__ast__Kind__placeholder, //
|
||
v__ast__Kind__void, // +1
|
||
v__ast__Kind__voidptr, // +2
|
||
v__ast__Kind__byteptr, // +3
|
||
v__ast__Kind__charptr, // +4
|
||
v__ast__Kind__i8, // +5
|
||
v__ast__Kind__i16, // +6
|
||
v__ast__Kind__int, // +7
|
||
v__ast__Kind__i64, // +8
|
||
v__ast__Kind__isize, // +9
|
||
v__ast__Kind__u8, // +10
|
||
v__ast__Kind__u16, // +11
|
||
v__ast__Kind__u32, // +12
|
||
v__ast__Kind__u64, // +13
|
||
v__ast__Kind__usize, // +14
|
||
v__ast__Kind__f32, // +15
|
||
v__ast__Kind__f64, // +16
|
||
v__ast__Kind__char, // +17
|
||
v__ast__Kind__rune, // +18
|
||
v__ast__Kind__bool, // +19
|
||
v__ast__Kind__none_, // +20
|
||
v__ast__Kind__string, // +21
|
||
v__ast__Kind__array, // +22
|
||
v__ast__Kind__array_fixed, // +23
|
||
v__ast__Kind__map, // +24
|
||
v__ast__Kind__chan, // +25
|
||
v__ast__Kind__any, // +26
|
||
v__ast__Kind__struct_, // +27
|
||
v__ast__Kind__generic_inst, // +28
|
||
v__ast__Kind__multi_return, // +29
|
||
v__ast__Kind__sum_type, // +30
|
||
v__ast__Kind__alias, // +31
|
||
v__ast__Kind__enum_, // +32
|
||
v__ast__Kind__function, // +33
|
||
v__ast__Kind__interface_, // +34
|
||
v__ast__Kind__float_literal, // +35
|
||
v__ast__Kind__int_literal, // +36
|
||
v__ast__Kind__aggregate, // +37
|
||
v__ast__Kind__thread, // +38
|
||
} v__ast__Kind;
|
||
|
||
typedef enum {
|
||
v__checker__ComptimeBranchSkipState__eval, //
|
||
v__checker__ComptimeBranchSkipState__skip, // +1
|
||
v__checker__ComptimeBranchSkipState__unknown, // +2
|
||
} v__checker__ComptimeBranchSkipState;
|
||
|
||
typedef enum {
|
||
v__gen__c__SqlExprSide__left, //
|
||
v__gen__c__SqlExprSide__right, // +1
|
||
} v__gen__c__SqlExprSide;
|
||
|
||
typedef enum {
|
||
v__gen__c__SqlType__sqlite3, //
|
||
v__gen__c__SqlType__mysql, // +1
|
||
v__gen__c__SqlType__psql, // +2
|
||
v__gen__c__SqlType__mssql, // +3
|
||
v__gen__c__SqlType__unknown, // +4
|
||
} v__gen__c__SqlType;
|
||
|
||
typedef enum {
|
||
v__scanner__CommentsMode__skip_comments, //
|
||
v__scanner__CommentsMode__parse_comments, // +1
|
||
v__scanner__CommentsMode__toplevel_comments, // +2
|
||
} v__scanner__CommentsMode;
|
||
|
||
typedef enum {
|
||
v__parser__State__simple, //
|
||
v__parser__State__html, // +1
|
||
v__parser__State__css, // +2
|
||
v__parser__State__js, // +3
|
||
} v__parser__State;
|
||
|
||
|
||
// V type definitions:
|
||
struct IError {
|
||
union {
|
||
void* _object;
|
||
None__* _None__;
|
||
Error* _Error;
|
||
MessageError* _MessageError;
|
||
time__TimeParseError* _time__TimeParseError;
|
||
flag__UnkownFlagError* _flag__UnkownFlagError;
|
||
flag__ArgsCountError* _flag__ArgsCountError;
|
||
semver__InvalidComparatorFormatError* _semver__InvalidComparatorFormatError;
|
||
semver__EmptyInputError* _semver__EmptyInputError;
|
||
semver__InvalidVersionFormatError* _semver__InvalidVersionFormatError;
|
||
os__FileNotOpenedError* _os__FileNotOpenedError;
|
||
os__SizeOfTypeIs0Error* _os__SizeOfTypeIs0Error;
|
||
os__ExecutableNotFoundError* _os__ExecutableNotFoundError;
|
||
v__gen__c__UnsupportedAssertCtempTransform* _v__gen__c__UnsupportedAssertCtempTransform;
|
||
};
|
||
int _typ;
|
||
string* msg;
|
||
int* code;
|
||
};
|
||
|
||
struct string {
|
||
u8* str;
|
||
int len;
|
||
int is_lit;
|
||
};
|
||
|
||
|
||
|
||
struct array {
|
||
int element_size;
|
||
voidptr data;
|
||
int offset;
|
||
int len;
|
||
int cap;
|
||
ArrayFlags flags;
|
||
};
|
||
|
||
|
||
|
||
struct DenseArray {
|
||
int key_bytes;
|
||
int value_bytes;
|
||
int cap;
|
||
int len;
|
||
u32 deletes;
|
||
u8* all_deleted;
|
||
u8* keys;
|
||
u8* values;
|
||
};
|
||
|
||
|
||
|
||
struct map {
|
||
int key_bytes;
|
||
int value_bytes;
|
||
u32 even_index;
|
||
u8 cached_hashbits;
|
||
u8 shift;
|
||
DenseArray key_values;
|
||
u32* metas;
|
||
u32 extra_metas;
|
||
bool has_string_keys;
|
||
MapHashFn hash_fn;
|
||
MapEqFn key_eq_fn;
|
||
MapCloneFn clone_fn;
|
||
MapFreeFn free_fn;
|
||
int len;
|
||
};
|
||
|
||
|
||
|
||
struct Error {
|
||
EMPTY_STRUCT_DECLARATION;
|
||
};
|
||
|
||
|
||
|
||
struct _option {
|
||
u8 state;
|
||
IError err;
|
||
};
|
||
|
||
|
||
|
||
struct _result {
|
||
bool is_error;
|
||
IError err;
|
||
};
|
||
|
||
|
||
typedef array Array_string;
|
||
typedef array Array_u8;
|
||
typedef array Array_int;
|
||
typedef array Array_voidptr;
|
||
typedef array Array_VCastTypeIndexName;
|
||
typedef array Array_MethodArgs;
|
||
typedef array Array_u8_ptr;
|
||
typedef array Array_rune;
|
||
typedef string Array_fixed_string_11 [11];
|
||
typedef voidptr Array_fixed_voidptr_11 [11];
|
||
typedef array Array_RepIndex;
|
||
typedef map Map_string_int;
|
||
typedef map Map_string_string;
|
||
typedef array Array_char_ptr;
|
||
typedef int Array_fixed_int_3 [3];
|
||
typedef char Array_fixed_char_256 [256];
|
||
typedef int Array_fixed_int_10 [10];
|
||
typedef map Map_string_Array_string;
|
||
typedef array Array_v__util__Possibility;
|
||
typedef map Map_string_time__StopWatch;
|
||
typedef array Array_v__ast__File_ptr;
|
||
typedef array Array_v__builder__FunctionRedefinition;
|
||
typedef array Array_v__cflag__CFlag;
|
||
typedef map Map_string_bool;
|
||
typedef array Array_u32;
|
||
typedef array Array_v__token__WIndex;
|
||
typedef map Map_string_T;
|
||
typedef map Map_string_v__token__Kind;
|
||
typedef array Array_v__token__Precedence;
|
||
typedef array Array_v__vmod__Token;
|
||
typedef map Map_string_v__vmod__ModFileAndFolder;
|
||
typedef array Array_v__ast__Stmt;
|
||
typedef array Array_v__ast__Comment;
|
||
typedef array Array_bool;
|
||
typedef array Array_v__token__Pos;
|
||
typedef array Array_v__ast__Expr;
|
||
typedef array Array_v__ast__Type;
|
||
typedef array Array_v__ast__Attr;
|
||
typedef array Array_v__ast__ConstField;
|
||
typedef array Array_v__ast__Embed;
|
||
typedef array Array_v__ast__StructField;
|
||
typedef array Array_v__ast__FnDecl;
|
||
typedef array Array_v__ast__InterfaceEmbedding;
|
||
typedef array Array_v__ast__StructInitField;
|
||
typedef array Array_v__ast__StructInitEmbed;
|
||
typedef array Array_v__ast__ImportSymbol;
|
||
typedef array Array_v__ast__Param;
|
||
typedef array Array_v__ast__DeferStmt;
|
||
typedef array Array_v__ast__CallArg;
|
||
typedef array Array_v__ast__GlobalField;
|
||
typedef array Array_v__ast__Import;
|
||
typedef array Array_v__ast__EmbeddedFile;
|
||
typedef array Array_v__errors__Error;
|
||
typedef array Array_v__errors__Warning;
|
||
typedef array Array_v__errors__Notice;
|
||
typedef array Array_v__ast__FnDecl_ptr;
|
||
typedef array Array_v__ast__IfBranch;
|
||
typedef array Array_v__ast__MatchBranch;
|
||
typedef array Array_Array_v__ast__Comment;
|
||
typedef array Array_v__ast__SelectBranch;
|
||
typedef array Array_v__ast__EnumField;
|
||
typedef array Array_v__ast__TypeNode;
|
||
typedef array Array_v__ast__Ident;
|
||
typedef array Array_v__ast__AsmClobbered;
|
||
typedef array Array_v__ast__AsmTemplate;
|
||
typedef array Array_v__ast__AsmIO;
|
||
typedef array Array_v__ast__AsmArg;
|
||
typedef array Array_v__ast__IfGuardVar;
|
||
typedef array Array_v__ast__SqlStmtLine;
|
||
typedef map Map_int_v__ast__SqlStmtLine;
|
||
typedef map Map_int_v__ast__SqlExpr;
|
||
typedef array Array_v__ast__Node;
|
||
typedef map Map_string_v__ast__ScopeObject;
|
||
typedef map Map_string_v__ast__ScopeStructField;
|
||
typedef array Array_v__ast__Scope_ptr;
|
||
typedef array Array_v__ast__TypeSymbol_ptr;
|
||
typedef map Map_string_v__ast__Fn;
|
||
typedef map Map_string_Array_v__ast__Type;
|
||
typedef map Map_int_string;
|
||
typedef array Array_Array_v__ast__Type;
|
||
typedef map Map_string_Array_Array_v__ast__Type;
|
||
typedef map Map_int_v__ast__InterfaceDecl;
|
||
typedef map Map_string_v__ast__EnumDecl;
|
||
typedef map Map_string_time__Time;
|
||
typedef map Map_u64_string;
|
||
typedef array Array_v__ast__Fn;
|
||
typedef map Map_string_v__ast__StructField;
|
||
typedef array Array_v__ast__Kind;
|
||
typedef map Map_int_Array_v__ast__Type;
|
||
typedef array Array_v__ast__File;
|
||
typedef map Map_string_v__ast__Type;
|
||
typedef map Map_int_v__ast__InterfaceEmbedding;
|
||
typedef array Array_i64;
|
||
typedef array Array_v__transformer__KeyVal;
|
||
typedef array Array_Array_v__transformer__KeyVal;
|
||
typedef array Array_v__vet__Error;
|
||
typedef map Map_string_v__ast__FnDecl;
|
||
typedef map Map_string_v__ast__ConstField;
|
||
typedef map Map_string_v__ast__GlobalField;
|
||
typedef array Array_v__depgraph__DepGraphNode;
|
||
typedef map Map_string_i64;
|
||
typedef map Map_string_strings__Builder;
|
||
typedef map Map_string_v__gen__c__GlobalConstDef;
|
||
typedef map Map_string_v__ast__Stmt_ptr;
|
||
typedef array Array_v__gen__c__StrType;
|
||
typedef array Array_v__gen__c__SumtypeCastingFn;
|
||
typedef map Map_int_bool;
|
||
typedef array Array_v__gen__c__ProfileCounterMeta;
|
||
typedef array Array_v__ast__InfixExpr;
|
||
typedef array Array_v__ast__TypeSymbol;
|
||
typedef array Array_v__token__Token;
|
||
typedef array Array_sync__Channel_ptr;
|
||
typedef array Array_sync__Direction;
|
||
typedef array Array_sync__Subscription;
|
||
typedef array Array_flag__Flag;
|
||
typedef array Array_f64;
|
||
typedef array Array_semver__Comparator;
|
||
typedef array Array_semver__ComparatorSet;
|
||
typedef u8 Array_fixed_u8_5 [5];
|
||
typedef array Array_u64;
|
||
typedef array Array_strconv__Uint128;
|
||
typedef u8 Array_fixed_u8_32 [32];
|
||
typedef u8 Array_fixed_u8_26 [26];
|
||
typedef voidptr Array_fixed_voidptr_100 [100];
|
||
typedef u8 Array_fixed_u8_1000 [1000];
|
||
typedef u8 Array_fixed_u8_17 [17];
|
||
typedef array Array_StrIntpType;
|
||
typedef array Array_v__token__Kind;
|
||
typedef u8 Array_fixed_u8_1024 [1024];
|
||
typedef u8 Array_fixed_u8_4096 [4096];
|
||
typedef array Array_os__ProcessState;
|
||
typedef int Array_fixed_int_6 [6];
|
||
typedef u8 Array_fixed_u8_50 [50];
|
||
typedef array Array_v__vmod__TokenKind;
|
||
typedef array Array_v__pref__Backend;
|
||
typedef map Map_int_Array_string;
|
||
typedef map Map_int_Map_string_int;
|
||
typedef array Array_v__ast__IdentKind;
|
||
typedef array Array_v__ast__IfExpr;
|
||
typedef array Array_v__ast__BoolLiteral;
|
||
typedef array Array_v__ast__SelectorExpr;
|
||
typedef array Array_v__pref__GarbageCollectionMode;
|
||
typedef array Array_v__gen__c__Gen_ptr;
|
||
typedef array Array_v__ast__Struct;
|
||
typedef array Array_v__ast__CallExpr;
|
||
typedef array Array_v__pref__Arch;
|
||
typedef array Array_v__pref__OS;
|
||
typedef u8 byte;
|
||
typedef int i32;
|
||
typedef Array_u8 strings__Builder;
|
||
typedef voidptr v__builder__RegKey;
|
||
typedef i64 time__Duration;
|
||
typedef int v__ast__Type;
|
||
typedef bool (*anon_fn_voidptr__bool)(voidptr);
|
||
typedef voidptr (*anon_fn_voidptr__voidptr)(voidptr);
|
||
typedef int (*anon_fn_voidptr_voidptr__int)(voidptr,voidptr);
|
||
typedef int (*anon_fn_int_int__int)(int,int);
|
||
typedef void (*FnExitCb)();
|
||
typedef int (*FnSortCB)(voidptr,voidptr);
|
||
typedef void (*anon_fn_string)(string);
|
||
typedef void (*os__FnWalkContextCB)(voidptr,string);
|
||
typedef void (*os__SignalHandler)(os__Signal);
|
||
typedef void (*os__FN_SA_Handler)(int);
|
||
typedef string (*anon_fn_string__string)(string);
|
||
typedef void (*v__builder__FnBackend)(v__builder__Builder*);
|
||
typedef void (*v__ast__FnPanicHandler)(v__ast__Table*,string);
|
||
typedef string (*v__dotgraph__FnLabel2NodeName)(string,voidptr);
|
||
typedef bool (*v__ast__walker__InspectorFn)(v__ast__Node*,voidptr);
|
||
typedef void (*anon_fn_)();
|
||
typedef void (*anon_fn_voidptr)(voidptr);
|
||
typedef voidptr (*sync__pool__ThreadCB)(sync__pool__PoolProcessor*,int,int);
|
||
struct rand__PRNG {
|
||
union {
|
||
void* _object;
|
||
rand__wyrand__WyRandRNG* _rand__wyrand__WyRandRNG;
|
||
};
|
||
int _typ;
|
||
};
|
||
struct hash__Hasher {
|
||
union {
|
||
void* _object;
|
||
};
|
||
int _typ;
|
||
};
|
||
struct hash__Hash32er {
|
||
union {
|
||
void* _object;
|
||
};
|
||
int _typ;
|
||
};
|
||
struct hash__Hash64er {
|
||
union {
|
||
void* _object;
|
||
};
|
||
int _typ;
|
||
};
|
||
struct v__ast__walker__Visitor {
|
||
union {
|
||
void* _object;
|
||
v__ast__walker__Inspector* _v__ast__walker__Inspector;
|
||
v__callgraph__Mapper* _v__callgraph__Mapper;
|
||
};
|
||
int _typ;
|
||
};
|
||
// #start sorted_symbols
|
||
struct none {
|
||
EMPTY_STRUCT_DECLARATION;
|
||
};
|
||
typedef pthread_t __v_thread;
|
||
|
||
struct None__ {
|
||
Error Error;
|
||
};
|
||
|
||
|
||
|
||
struct StrIntpCgenData {
|
||
string str;
|
||
string fmt;
|
||
string d;
|
||
};
|
||
|
||
|
||
|
||
struct os__FileNotOpenedError {
|
||
Error Error;
|
||
};
|
||
|
||
|
||
|
||
struct os__SizeOfTypeIs0Error {
|
||
Error Error;
|
||
};
|
||
|
||
|
||
|
||
struct os__ExecutableNotFoundError {
|
||
Error Error;
|
||
};
|
||
|
||
|
||
|
||
struct os__Uname {
|
||
string sysname;
|
||
string nodename;
|
||
string release;
|
||
string version;
|
||
string machine;
|
||
};
|
||
|
||
|
||
|
||
struct v__cflag__CFlag {
|
||
string mod;
|
||
string os;
|
||
string name;
|
||
string value;
|
||
string cached;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__WindowsKit {
|
||
string um_lib_path;
|
||
string ucrt_lib_path;
|
||
string um_include_path;
|
||
string ucrt_include_path;
|
||
string shared_include_path;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__VsInstallation {
|
||
string include_path;
|
||
string lib_path;
|
||
string exe_path;
|
||
};
|
||
|
||
|
||
|
||
struct v__vmod__ModFileAndFolder {
|
||
string vmod_file;
|
||
string vmod_folder;
|
||
};
|
||
|
||
|
||
|
||
// Union sum type v__ast__TypeDecl =
|
||
// | 244 = v__ast__AliasTypeDecl
|
||
// | 245 = v__ast__FnTypeDecl
|
||
// | 246 = v__ast__SumTypeDecl
|
||
struct v__ast__TypeDecl {
|
||
union {
|
||
v__ast__AliasTypeDecl* _v__ast__AliasTypeDecl;
|
||
v__ast__FnTypeDecl* _v__ast__FnTypeDecl;
|
||
v__ast__SumTypeDecl* _v__ast__SumTypeDecl;
|
||
};
|
||
int _typ;
|
||
string* name;
|
||
bool* is_pub;
|
||
v__token__Pos* pos;
|
||
Array_v__ast__Comment* comments;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__Expr =
|
||
// | 248 = v__ast__AnonFn
|
||
// | 249 = v__ast__ArrayDecompose
|
||
// | 250 = v__ast__ArrayInit
|
||
// | 251 = v__ast__AsCast
|
||
// | 252 = v__ast__Assoc
|
||
// | 253 = v__ast__AtExpr
|
||
// | 254 = v__ast__BoolLiteral
|
||
// | 255 = v__ast__CTempVar
|
||
// | 256 = v__ast__CallExpr
|
||
// | 257 = v__ast__CastExpr
|
||
// | 258 = v__ast__ChanInit
|
||
// | 259 = v__ast__CharLiteral
|
||
// | 260 = v__ast__Comment
|
||
// | 261 = v__ast__ComptimeCall
|
||
// | 262 = v__ast__ComptimeSelector
|
||
// | 263 = v__ast__ComptimeType
|
||
// | 264 = v__ast__ConcatExpr
|
||
// | 265 = v__ast__DumpExpr
|
||
// | 266 = v__ast__EmptyExpr
|
||
// | 267 = v__ast__EnumVal
|
||
// | 268 = v__ast__FloatLiteral
|
||
// | 269 = v__ast__GoExpr
|
||
// | 270 = v__ast__Ident
|
||
// | 271 = v__ast__IfExpr
|
||
// | 272 = v__ast__IfGuardExpr
|
||
// | 273 = v__ast__IndexExpr
|
||
// | 274 = v__ast__InfixExpr
|
||
// | 275 = v__ast__IntegerLiteral
|
||
// | 276 = v__ast__IsRefType
|
||
// | 277 = v__ast__Likely
|
||
// | 278 = v__ast__LockExpr
|
||
// | 279 = v__ast__MapInit
|
||
// | 280 = v__ast__MatchExpr
|
||
// | 281 = v__ast__NodeError
|
||
// | 282 = v__ast__None
|
||
// | 283 = v__ast__OffsetOf
|
||
// | 284 = v__ast__OrExpr
|
||
// | 285 = v__ast__ParExpr
|
||
// | 286 = v__ast__PostfixExpr
|
||
// | 287 = v__ast__PrefixExpr
|
||
// | 288 = v__ast__RangeExpr
|
||
// | 289 = v__ast__SelectExpr
|
||
// | 290 = v__ast__SelectorExpr
|
||
// | 291 = v__ast__SizeOf
|
||
// | 292 = v__ast__SqlExpr
|
||
// | 293 = v__ast__StringInterLiteral
|
||
// | 294 = v__ast__StringLiteral
|
||
// | 295 = v__ast__StructInit
|
||
// | 296 = v__ast__TypeNode
|
||
// | 297 = v__ast__TypeOf
|
||
// | 298 = v__ast__UnsafeExpr
|
||
struct v__ast__Expr {
|
||
union {
|
||
v__ast__AnonFn* _v__ast__AnonFn;
|
||
v__ast__ArrayDecompose* _v__ast__ArrayDecompose;
|
||
v__ast__ArrayInit* _v__ast__ArrayInit;
|
||
v__ast__AsCast* _v__ast__AsCast;
|
||
v__ast__Assoc* _v__ast__Assoc;
|
||
v__ast__AtExpr* _v__ast__AtExpr;
|
||
v__ast__BoolLiteral* _v__ast__BoolLiteral;
|
||
v__ast__CTempVar* _v__ast__CTempVar;
|
||
v__ast__CallExpr* _v__ast__CallExpr;
|
||
v__ast__CastExpr* _v__ast__CastExpr;
|
||
v__ast__ChanInit* _v__ast__ChanInit;
|
||
v__ast__CharLiteral* _v__ast__CharLiteral;
|
||
v__ast__Comment* _v__ast__Comment;
|
||
v__ast__ComptimeCall* _v__ast__ComptimeCall;
|
||
v__ast__ComptimeSelector* _v__ast__ComptimeSelector;
|
||
v__ast__ComptimeType* _v__ast__ComptimeType;
|
||
v__ast__ConcatExpr* _v__ast__ConcatExpr;
|
||
v__ast__DumpExpr* _v__ast__DumpExpr;
|
||
v__ast__EmptyExpr* _v__ast__EmptyExpr;
|
||
v__ast__EnumVal* _v__ast__EnumVal;
|
||
v__ast__FloatLiteral* _v__ast__FloatLiteral;
|
||
v__ast__GoExpr* _v__ast__GoExpr;
|
||
v__ast__Ident* _v__ast__Ident;
|
||
v__ast__IfExpr* _v__ast__IfExpr;
|
||
v__ast__IfGuardExpr* _v__ast__IfGuardExpr;
|
||
v__ast__IndexExpr* _v__ast__IndexExpr;
|
||
v__ast__InfixExpr* _v__ast__InfixExpr;
|
||
v__ast__IntegerLiteral* _v__ast__IntegerLiteral;
|
||
v__ast__IsRefType* _v__ast__IsRefType;
|
||
v__ast__Likely* _v__ast__Likely;
|
||
v__ast__LockExpr* _v__ast__LockExpr;
|
||
v__ast__MapInit* _v__ast__MapInit;
|
||
v__ast__MatchExpr* _v__ast__MatchExpr;
|
||
v__ast__NodeError* _v__ast__NodeError;
|
||
v__ast__None* _v__ast__None;
|
||
v__ast__OffsetOf* _v__ast__OffsetOf;
|
||
v__ast__OrExpr* _v__ast__OrExpr;
|
||
v__ast__ParExpr* _v__ast__ParExpr;
|
||
v__ast__PostfixExpr* _v__ast__PostfixExpr;
|
||
v__ast__PrefixExpr* _v__ast__PrefixExpr;
|
||
v__ast__RangeExpr* _v__ast__RangeExpr;
|
||
v__ast__SelectExpr* _v__ast__SelectExpr;
|
||
v__ast__SelectorExpr* _v__ast__SelectorExpr;
|
||
v__ast__SizeOf* _v__ast__SizeOf;
|
||
v__ast__SqlExpr* _v__ast__SqlExpr;
|
||
v__ast__StringInterLiteral* _v__ast__StringInterLiteral;
|
||
v__ast__StringLiteral* _v__ast__StringLiteral;
|
||
v__ast__StructInit* _v__ast__StructInit;
|
||
v__ast__TypeNode* _v__ast__TypeNode;
|
||
v__ast__TypeOf* _v__ast__TypeOf;
|
||
v__ast__UnsafeExpr* _v__ast__UnsafeExpr;
|
||
};
|
||
int _typ;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__Stmt =
|
||
// | 300 = v__ast__AsmStmt
|
||
// | 301 = v__ast__AssertStmt
|
||
// | 302 = v__ast__AssignStmt
|
||
// | 303 = v__ast__Block
|
||
// | 304 = v__ast__BranchStmt
|
||
// | 305 = v__ast__ComptimeFor
|
||
// | 306 = v__ast__ConstDecl
|
||
// | 307 = v__ast__DeferStmt
|
||
// | 308 = v__ast__EmptyStmt
|
||
// | 309 = v__ast__EnumDecl
|
||
// | 310 = v__ast__ExprStmt
|
||
// | 185 = v__ast__FnDecl
|
||
// | 311 = v__ast__ForCStmt
|
||
// | 312 = v__ast__ForInStmt
|
||
// | 313 = v__ast__ForStmt
|
||
// | 314 = v__ast__GlobalDecl
|
||
// | 315 = v__ast__GotoLabel
|
||
// | 316 = v__ast__GotoStmt
|
||
// | 317 = v__ast__HashStmt
|
||
// | 318 = v__ast__Import
|
||
// | 319 = v__ast__InterfaceDecl
|
||
// | 320 = v__ast__Module
|
||
// | 281 = v__ast__NodeError
|
||
// | 321 = v__ast__Return
|
||
// | 322 = v__ast__SqlStmt
|
||
// | 323 = v__ast__StructDecl
|
||
// | 247 = v__ast__TypeDecl
|
||
struct v__ast__Stmt {
|
||
union {
|
||
v__ast__AsmStmt* _v__ast__AsmStmt;
|
||
v__ast__AssertStmt* _v__ast__AssertStmt;
|
||
v__ast__AssignStmt* _v__ast__AssignStmt;
|
||
v__ast__Block* _v__ast__Block;
|
||
v__ast__BranchStmt* _v__ast__BranchStmt;
|
||
v__ast__ComptimeFor* _v__ast__ComptimeFor;
|
||
v__ast__ConstDecl* _v__ast__ConstDecl;
|
||
v__ast__DeferStmt* _v__ast__DeferStmt;
|
||
v__ast__EmptyStmt* _v__ast__EmptyStmt;
|
||
v__ast__EnumDecl* _v__ast__EnumDecl;
|
||
v__ast__ExprStmt* _v__ast__ExprStmt;
|
||
v__ast__FnDecl* _v__ast__FnDecl;
|
||
v__ast__ForCStmt* _v__ast__ForCStmt;
|
||
v__ast__ForInStmt* _v__ast__ForInStmt;
|
||
v__ast__ForStmt* _v__ast__ForStmt;
|
||
v__ast__GlobalDecl* _v__ast__GlobalDecl;
|
||
v__ast__GotoLabel* _v__ast__GotoLabel;
|
||
v__ast__GotoStmt* _v__ast__GotoStmt;
|
||
v__ast__HashStmt* _v__ast__HashStmt;
|
||
v__ast__Import* _v__ast__Import;
|
||
v__ast__InterfaceDecl* _v__ast__InterfaceDecl;
|
||
v__ast__Module* _v__ast__Module;
|
||
v__ast__NodeError* _v__ast__NodeError;
|
||
v__ast__Return* _v__ast__Return;
|
||
v__ast__SqlStmt* _v__ast__SqlStmt;
|
||
v__ast__StructDecl* _v__ast__StructDecl;
|
||
v__ast__TypeDecl* _v__ast__TypeDecl;
|
||
};
|
||
int _typ;
|
||
v__token__Pos* pos;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__ScopeObject =
|
||
// | 325 = v__ast__AsmRegister
|
||
// | 326 = v__ast__ConstField
|
||
// | 327 = v__ast__GlobalField
|
||
// | 328 = v__ast__Var
|
||
struct v__ast__ScopeObject {
|
||
union {
|
||
v__ast__AsmRegister* _v__ast__AsmRegister;
|
||
v__ast__ConstField* _v__ast__ConstField;
|
||
v__ast__GlobalField* _v__ast__GlobalField;
|
||
v__ast__Var* _v__ast__Var;
|
||
};
|
||
int _typ;
|
||
string* name;
|
||
v__ast__Type* typ;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__Node =
|
||
// | 330 = v__ast__CallArg
|
||
// | 326 = v__ast__ConstField
|
||
// | 331 = v__ast__EmptyNode
|
||
// | 332 = v__ast__EnumField
|
||
// | 299 = v__ast__Expr
|
||
// | 176 = v__ast__File
|
||
// | 327 = v__ast__GlobalField
|
||
// | 333 = v__ast__IfBranch
|
||
// | 334 = v__ast__MatchBranch
|
||
// | 281 = v__ast__NodeError
|
||
// | 335 = v__ast__Param
|
||
// | 329 = v__ast__ScopeObject
|
||
// | 336 = v__ast__SelectBranch
|
||
// | 324 = v__ast__Stmt
|
||
// | 337 = v__ast__StructField
|
||
// | 338 = v__ast__StructInitField
|
||
struct v__ast__Node {
|
||
union {
|
||
v__ast__CallArg* _v__ast__CallArg;
|
||
v__ast__ConstField* _v__ast__ConstField;
|
||
v__ast__EmptyNode* _v__ast__EmptyNode;
|
||
v__ast__EnumField* _v__ast__EnumField;
|
||
v__ast__Expr* _v__ast__Expr;
|
||
v__ast__File* _v__ast__File;
|
||
v__ast__GlobalField* _v__ast__GlobalField;
|
||
v__ast__IfBranch* _v__ast__IfBranch;
|
||
v__ast__MatchBranch* _v__ast__MatchBranch;
|
||
v__ast__NodeError* _v__ast__NodeError;
|
||
v__ast__Param* _v__ast__Param;
|
||
v__ast__ScopeObject* _v__ast__ScopeObject;
|
||
v__ast__SelectBranch* _v__ast__SelectBranch;
|
||
v__ast__Stmt* _v__ast__Stmt;
|
||
v__ast__StructField* _v__ast__StructField;
|
||
v__ast__StructInitField* _v__ast__StructInitField;
|
||
};
|
||
int _typ;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__ComptTimeConstValue =
|
||
// | 266 = v__ast__EmptyExpr
|
||
// | 15 = f32
|
||
// | 16 = f64
|
||
// | 6 = i16
|
||
// | 8 = i64
|
||
// | 5 = i8
|
||
// | 7 = int
|
||
// | 21 = rune
|
||
// | 20 = string
|
||
// | 11 = u16
|
||
// | 12 = u32
|
||
// | 13 = u64
|
||
// | 10 = u8
|
||
struct v__ast__ComptTimeConstValue {
|
||
union {
|
||
v__ast__EmptyExpr* _v__ast__EmptyExpr;
|
||
f32* _f32;
|
||
f64* _f64;
|
||
i16* _i16;
|
||
i64* _i64;
|
||
i8* _i8;
|
||
int* _int;
|
||
rune* _rune;
|
||
string* _string;
|
||
u16* _u16;
|
||
u32* _u32;
|
||
u64* _u64;
|
||
u8* _u8;
|
||
};
|
||
int _typ;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__IdentInfo =
|
||
// | 379 = v__ast__IdentFn
|
||
// | 380 = v__ast__IdentVar
|
||
struct v__ast__IdentInfo {
|
||
union {
|
||
v__ast__IdentFn* _v__ast__IdentFn;
|
||
v__ast__IdentVar* _v__ast__IdentVar;
|
||
};
|
||
int _typ;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__AsmArg =
|
||
// | 400 = v__ast__AsmAddressing
|
||
// | 401 = v__ast__AsmAlias
|
||
// | 402 = v__ast__AsmDisp
|
||
// | 325 = v__ast__AsmRegister
|
||
// | 254 = v__ast__BoolLiteral
|
||
// | 259 = v__ast__CharLiteral
|
||
// | 268 = v__ast__FloatLiteral
|
||
// | 275 = v__ast__IntegerLiteral
|
||
// | 20 = string
|
||
struct v__ast__AsmArg {
|
||
union {
|
||
v__ast__AsmAddressing* _v__ast__AsmAddressing;
|
||
v__ast__AsmAlias* _v__ast__AsmAlias;
|
||
v__ast__AsmDisp* _v__ast__AsmDisp;
|
||
v__ast__AsmRegister* _v__ast__AsmRegister;
|
||
v__ast__BoolLiteral* _v__ast__BoolLiteral;
|
||
v__ast__CharLiteral* _v__ast__CharLiteral;
|
||
v__ast__FloatLiteral* _v__ast__FloatLiteral;
|
||
v__ast__IntegerLiteral* _v__ast__IntegerLiteral;
|
||
string* _string;
|
||
};
|
||
int _typ;
|
||
};
|
||
|
||
|
||
// Union sum type v__ast__TypeInfo =
|
||
// | 434 = v__ast__Aggregate
|
||
// | 436 = v__ast__Alias
|
||
// | 415 = v__ast__Array
|
||
// | 444 = v__ast__ArrayFixed
|
||
// | 445 = v__ast__Chan
|
||
// | 450 = v__ast__Enum
|
||
// | 448 = v__ast__FnType
|
||
// | 449 = v__ast__GenericInst
|
||
// | 439 = v__ast__Interface
|
||
// | 416 = v__ast__Map
|
||
// | 447 = v__ast__MultiReturn
|
||
// | 420 = v__ast__Struct
|
||
// | 440 = v__ast__SumType
|
||
// | 446 = v__ast__Thread
|
||
struct v__ast__TypeInfo {
|
||
union {
|
||
v__ast__Aggregate* _v__ast__Aggregate;
|
||
v__ast__Alias* _v__ast__Alias;
|
||
v__ast__Array* _v__ast__Array;
|
||
v__ast__ArrayFixed* _v__ast__ArrayFixed;
|
||
v__ast__Chan* _v__ast__Chan;
|
||
v__ast__Enum* _v__ast__Enum;
|
||
v__ast__FnType* _v__ast__FnType;
|
||
v__ast__GenericInst* _v__ast__GenericInst;
|
||
v__ast__Interface* _v__ast__Interface;
|
||
v__ast__Map* _v__ast__Map;
|
||
v__ast__MultiReturn* _v__ast__MultiReturn;
|
||
v__ast__Struct* _v__ast__Struct;
|
||
v__ast__SumType* _v__ast__SumType;
|
||
v__ast__Thread* _v__ast__Thread;
|
||
};
|
||
int _typ;
|
||
};
|
||
|
||
|
||
struct v__gen__c__UnsupportedAssertCtempTransform {
|
||
Error Error;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__ProfileCounterMeta {
|
||
string fn_name;
|
||
string vpc_name;
|
||
string vpc_calls;
|
||
};
|
||
|
||
|
||
|
||
struct sync__Subscription {
|
||
sync__Semaphore* sem;
|
||
sync__Subscription** prev;
|
||
sync__Subscription* nxt;
|
||
};
|
||
|
||
|
||
|
||
struct flag__UnkownFlagError {
|
||
Error Error;
|
||
string flag;
|
||
};
|
||
|
||
|
||
|
||
struct semver__EmptyInputError {
|
||
Error Error;
|
||
};
|
||
|
||
|
||
|
||
struct semver__InvalidVersionFormatError {
|
||
Error Error;
|
||
string input;
|
||
};
|
||
|
||
|
||
|
||
struct VCastTypeIndexName {
|
||
int tindex;
|
||
string tname;
|
||
};
|
||
|
||
|
||
|
||
struct VAssertMetaInfo {
|
||
string fpath;
|
||
int line_nr;
|
||
string fn_name;
|
||
string src;
|
||
string op;
|
||
string llabel;
|
||
string rlabel;
|
||
string lvalue;
|
||
string rvalue;
|
||
};
|
||
|
||
|
||
|
||
struct MethodArgs {
|
||
int typ;
|
||
string name;
|
||
};
|
||
|
||
|
||
|
||
struct FunctionData {
|
||
string name;
|
||
Array_string attrs;
|
||
Array_MethodArgs args;
|
||
int return_type;
|
||
int typ;
|
||
};
|
||
|
||
|
||
|
||
struct FieldData {
|
||
string name;
|
||
Array_string attrs;
|
||
bool is_pub;
|
||
bool is_mut;
|
||
bool is_shared;
|
||
int typ;
|
||
};
|
||
|
||
|
||
|
||
struct StructAttribute {
|
||
string name;
|
||
bool has_arg;
|
||
string arg;
|
||
AttributeKind kind;
|
||
};
|
||
|
||
|
||
|
||
union strconv__Float64u {
|
||
f64 f;
|
||
u64 u;
|
||
};
|
||
|
||
|
||
|
||
union strconv__Float32u {
|
||
f32 f;
|
||
u32 u;
|
||
};
|
||
|
||
|
||
|
||
struct MessageError {
|
||
string msg;
|
||
int code;
|
||
};
|
||
|
||
|
||
|
||
struct Option {
|
||
u8 state;
|
||
IError err;
|
||
};
|
||
|
||
|
||
|
||
struct VMemoryBlock {
|
||
int id;
|
||
isize cap;
|
||
byte* start;
|
||
VMemoryBlock* previous;
|
||
isize remaining;
|
||
u8* current;
|
||
int mallocs;
|
||
};
|
||
|
||
|
||
|
||
struct SortedMap {
|
||
int value_bytes;
|
||
mapnode* root;
|
||
int len;
|
||
};
|
||
|
||
|
||
|
||
struct RepIndex {
|
||
int idx;
|
||
int val_idx;
|
||
};
|
||
|
||
|
||
|
||
union StrIntpMem {
|
||
u32 d_c;
|
||
byte d_u8;
|
||
i8 d_i8;
|
||
u16 d_u16;
|
||
i16 d_i16;
|
||
u32 d_u32;
|
||
int d_i32;
|
||
u64 d_u64;
|
||
i64 d_i64;
|
||
f32 d_f32;
|
||
f64 d_f64;
|
||
string d_s;
|
||
voidptr d_p;
|
||
voidptr d_vp;
|
||
};
|
||
|
||
|
||
|
||
struct strconv__BF_param {
|
||
u8 pad_ch;
|
||
int len0;
|
||
int len1;
|
||
bool positive;
|
||
bool sign_flag;
|
||
strconv__Align_text allign;
|
||
bool rm_tail_zero;
|
||
};
|
||
|
||
|
||
|
||
struct strconv__PrepNumber {
|
||
bool negative;
|
||
int exponent;
|
||
u64 mantissa;
|
||
};
|
||
|
||
|
||
|
||
struct strconv__Dec32 {
|
||
u32 m;
|
||
int e;
|
||
};
|
||
|
||
|
||
|
||
union strconv__Uf32 {
|
||
f32 f;
|
||
u32 u;
|
||
};
|
||
|
||
|
||
|
||
struct strconv__Dec64 {
|
||
u64 m;
|
||
int e;
|
||
};
|
||
|
||
|
||
|
||
union strconv__Uf64 {
|
||
f64 f;
|
||
u64 u;
|
||
};
|
||
|
||
|
||
|
||
struct strconv__Uint128 {
|
||
u64 lo;
|
||
u64 hi;
|
||
};
|
||
|
||
|
||
|
||
struct os__File {
|
||
voidptr cfile;
|
||
int fd;
|
||
bool is_opened;
|
||
};
|
||
|
||
|
||
|
||
struct os__FileInfo {
|
||
string name;
|
||
int size;
|
||
};
|
||
|
||
|
||
|
||
struct os__FilePermission {
|
||
bool read;
|
||
bool write;
|
||
bool execute;
|
||
};
|
||
|
||
|
||
|
||
struct os__Result {
|
||
int exit_code;
|
||
string output;
|
||
};
|
||
|
||
|
||
|
||
struct os__Command {
|
||
voidptr f;
|
||
bool eof;
|
||
int exit_code;
|
||
string path;
|
||
bool redirect_stdout;
|
||
};
|
||
|
||
|
||
|
||
struct term__Coord {
|
||
int x;
|
||
int y;
|
||
};
|
||
|
||
|
||
|
||
struct v__vcache__CacheManager {
|
||
string basepath;
|
||
string original_vopts;
|
||
string vopts;
|
||
Map_string_string k2cpath;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__EManager {
|
||
bool support_color;
|
||
};
|
||
|
||
|
||
|
||
struct v__token__Pos {
|
||
int len;
|
||
int line_nr;
|
||
int pos;
|
||
int col;
|
||
int last_line;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__LinesCache {
|
||
Map_string_Array_string lines;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__Possibility {
|
||
string value;
|
||
string svalue;
|
||
f32 similarity;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__Suggestion {
|
||
Array_v__util__Possibility known;
|
||
string wanted;
|
||
string swanted;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__Surrounder {
|
||
Array_string befores;
|
||
Array_string afters;
|
||
};
|
||
|
||
|
||
|
||
struct time__StopWatch {
|
||
u64 elapsed;
|
||
u64 start;
|
||
u64 end;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__Timers {
|
||
string label;
|
||
Map_string_time__StopWatch swatches;
|
||
bool should_print;
|
||
Array_string already_shown;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__TimerParams {
|
||
bool should_print;
|
||
string label;
|
||
};
|
||
|
||
|
||
|
||
struct v__util__SourceCache {
|
||
Map_string_string sources;
|
||
};
|
||
|
||
|
||
|
||
struct v__transformer__Transformer {
|
||
v__pref__Preferences* pref;
|
||
v__transformer__IndexState* index;
|
||
v__ast__Table* table;
|
||
bool is_assert;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__MsvcResult {
|
||
string full_cl_exe_path;
|
||
string exe_path;
|
||
string um_lib_path;
|
||
string ucrt_lib_path;
|
||
string vs_lib_path;
|
||
string um_include_path;
|
||
string ucrt_include_path;
|
||
string vs_include_path;
|
||
string shared_include_path;
|
||
bool valid;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Table {
|
||
Map_string_int type_idxs;
|
||
Map_string_v__ast__Fn fns;
|
||
Map_string_Array_v__ast__Type iface_types;
|
||
Map_int_string dumps;
|
||
Map_string_Array_Array_v__ast__Type fn_generic_types;
|
||
Map_int_v__ast__InterfaceDecl interfaces;
|
||
Map_string_bool used_fns;
|
||
Map_string_bool used_consts;
|
||
Map_string_bool used_globals;
|
||
Map_string_v__ast__EnumDecl enum_decls;
|
||
Map_string_string mdeprecated_msg;
|
||
Map_string_time__Time mdeprecated_after;
|
||
Map_string_bool builtin_pub_fns;
|
||
Map_u64_string cached_type_to_str;
|
||
Array_v__ast__TypeSymbol_ptr type_symbols;
|
||
Array_string imports;
|
||
Array_string modules;
|
||
Array_v__cflag__CFlag cflags;
|
||
Array_string redefined_fns;
|
||
Array_v__ast__Type used_vweb_types;
|
||
Array_v__ast__Type cur_concrete_types;
|
||
string parsing_type;
|
||
string cmod_prefix;
|
||
v__ast__Scope* global_scope;
|
||
v__ast__FnDecl* cur_fn;
|
||
int used_maps;
|
||
int panic_npanics;
|
||
int gostmts;
|
||
int pointer_size;
|
||
v__ast__FnPanicHandler panic_handler;
|
||
voidptr panic_userdata;
|
||
bool is_fmt : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__CcompilerOptions {
|
||
string guessed_compiler;
|
||
string shared_postfix;
|
||
bool debug_mode;
|
||
bool is_cc_tcc;
|
||
bool is_cc_gcc;
|
||
bool is_cc_msvc;
|
||
bool is_cc_clang;
|
||
string env_cflags;
|
||
string env_ldflags;
|
||
Array_string args;
|
||
Array_string wargs;
|
||
Array_string pre_args;
|
||
Array_string o_args;
|
||
Array_string source_args;
|
||
Array_string post_args;
|
||
Array_string linker_flags;
|
||
};
|
||
|
||
|
||
|
||
struct v__depgraph__DepGraph {
|
||
bool acyclic;
|
||
Array_v__depgraph__DepGraphNode nodes;
|
||
Map_string_i64 values;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__MsvcStringFlags {
|
||
Array_string real_libs;
|
||
Array_string inc_paths;
|
||
Array_string lib_paths;
|
||
Array_string defines;
|
||
Array_string other_flags;
|
||
};
|
||
|
||
|
||
|
||
struct strings__textscanner__TextScanner {
|
||
string input;
|
||
int ilen;
|
||
int pos;
|
||
};
|
||
|
||
|
||
|
||
struct rand__config__NormalConfigStruct {
|
||
f64 mu;
|
||
f64 sigma;
|
||
};
|
||
|
||
|
||
|
||
struct rand__config__ShuffleConfigStruct {
|
||
int start;
|
||
int end;
|
||
};
|
||
|
||
|
||
|
||
struct rand__config__PRNGConfigStruct {
|
||
Array_u32 seed_;
|
||
};
|
||
|
||
|
||
|
||
struct v__token__WIndex {
|
||
string word;
|
||
int index;
|
||
};
|
||
|
||
|
||
typedef Array_v__token__WIndex Array_fixed_Array_v__token__WIndex_20 [20];
|
||
|
||
struct v__token__Token {
|
||
string lit;
|
||
int line_nr;
|
||
int col;
|
||
int pos;
|
||
int len;
|
||
int tidx;
|
||
v__token__Kind kind : 7;
|
||
};
|
||
|
||
|
||
|
||
struct time__Time {
|
||
int year;
|
||
int month;
|
||
int day;
|
||
int hour;
|
||
int minute;
|
||
int second;
|
||
int microsecond;
|
||
i64 _v_unix;
|
||
bool is_local;
|
||
};
|
||
|
||
|
||
|
||
struct time__TimeParseError {
|
||
Error Error;
|
||
int code;
|
||
};
|
||
|
||
|
||
|
||
struct time__StopWatchOptions {
|
||
bool auto_start;
|
||
};
|
||
|
||
|
||
|
||
struct v__vmod__Manifest {
|
||
string name;
|
||
string version;
|
||
string description;
|
||
Array_string dependencies;
|
||
string license;
|
||
string repo_url;
|
||
string author;
|
||
Map_string_Array_string unknown;
|
||
};
|
||
|
||
|
||
|
||
struct v__vmod__Token {
|
||
v__vmod__TokenKind typ;
|
||
string val;
|
||
int line;
|
||
};
|
||
|
||
|
||
|
||
struct v__vmod__Scanner {
|
||
int pos;
|
||
int line;
|
||
string text;
|
||
bool inside_text;
|
||
Array_v__vmod__Token tokens;
|
||
};
|
||
|
||
|
||
|
||
struct v__vmod__ModFileCacher {
|
||
Map_string_v__vmod__ModFileAndFolder cache;
|
||
Map_string_Array_string folder_files;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__CTempVar {
|
||
string name;
|
||
v__ast__Type typ;
|
||
bool is_ptr;
|
||
v__ast__Expr orig;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EmptyExpr {
|
||
int x;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IfGuardExpr {
|
||
Array_v__ast__IfGuardVar vars;
|
||
v__ast__Expr expr;
|
||
v__ast__Type expr_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmRegister {
|
||
string name;
|
||
v__ast__Type typ;
|
||
int size;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EmptyNode {
|
||
int x;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Scope {
|
||
Map_string_v__ast__ScopeObject objects;
|
||
Map_string_v__ast__ScopeStructField struct_fields;
|
||
v__ast__Scope* parent;
|
||
bool detached_from_parent;
|
||
Array_v__ast__Scope_ptr children;
|
||
int start_pos;
|
||
int end_pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EmbeddedFile {
|
||
Array_u8 bytes;
|
||
string rpath;
|
||
string apath;
|
||
string compression_type;
|
||
int len;
|
||
bool is_compressed : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IdentFn {
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IdentVar {
|
||
v__ast__Type typ;
|
||
v__ast__ShareType share : 2;
|
||
bool is_mut : 1;
|
||
bool is_static : 1;
|
||
bool is_volatile : 1;
|
||
bool is_optional : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Array {
|
||
int nr_dims;
|
||
v__ast__Type elem_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Map {
|
||
v__ast__Type key_type;
|
||
v__ast__Type value_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Struct {
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__Type embeds;
|
||
Array_v__ast__StructField fields;
|
||
Array_v__ast__Type generic_types;
|
||
Array_v__ast__Type concrete_types;
|
||
v__ast__Type parent_type;
|
||
bool is_typedef : 1;
|
||
bool is_union : 1;
|
||
bool is_heap : 1;
|
||
bool is_minify : 1;
|
||
bool is_generic : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__TypeSymbol {
|
||
Array_v__ast__Fn methods;
|
||
v__ast__TypeInfo info;
|
||
string name;
|
||
string cname;
|
||
string mod;
|
||
int parent_idx;
|
||
int idx;
|
||
int size;
|
||
int align;
|
||
v__ast__Kind kind : 6;
|
||
v__ast__Language language : 4;
|
||
bool is_pub : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Aggregate {
|
||
Array_v__ast__StructField fields;
|
||
v__ast__Type sum_type;
|
||
Array_v__ast__Type types;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GetEmbedsOptions {
|
||
Array_v__ast__Type preceding;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Alias {
|
||
v__ast__Type parent_type;
|
||
v__ast__Language language : 4;
|
||
bool is_import : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Interface {
|
||
Map_int_Array_v__ast__Type conversions;
|
||
Array_v__ast__Type types;
|
||
Array_v__ast__StructField fields;
|
||
Array_v__ast__Fn methods;
|
||
Array_v__ast__Type embeds;
|
||
Array_v__ast__Type generic_types;
|
||
Array_v__ast__Type concrete_types;
|
||
v__ast__Type parent_type;
|
||
bool is_generic : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SumType {
|
||
Array_v__ast__StructField fields;
|
||
Array_v__ast__Type variants;
|
||
Array_v__ast__Type generic_types;
|
||
Array_v__ast__Type concrete_types;
|
||
v__ast__Type parent_type;
|
||
bool found_fields : 1;
|
||
bool is_anon : 1;
|
||
bool is_generic : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ArrayFixed {
|
||
v__ast__Expr size_expr;
|
||
int size;
|
||
v__ast__Type elem_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Chan {
|
||
v__ast__Type elem_type;
|
||
bool is_mut;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Thread {
|
||
v__ast__Type return_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__MultiReturn {
|
||
Array_v__ast__Type types;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GenericInst {
|
||
int parent_idx;
|
||
Array_v__ast__Type concrete_types;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Enum {
|
||
Array_string vals;
|
||
bool is_flag;
|
||
bool is_multi_allowed;
|
||
bool uses_exprs;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__FnSignatureOpts {
|
||
bool skip_receiver : 1;
|
||
bool type_only : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__transformer__KeyVal {
|
||
string key;
|
||
int value;
|
||
};
|
||
|
||
|
||
|
||
struct v__transformer__IndexState {
|
||
Map_string_int max_index;
|
||
Array_bool saved_disabled;
|
||
Array_Array_v__transformer__KeyVal saved_key_vals;
|
||
bool disabled;
|
||
int level;
|
||
};
|
||
|
||
|
||
|
||
struct v__scanner__Scanner {
|
||
Array_v__token__Token all_tokens;
|
||
Array_string error_details;
|
||
Array_v__errors__Error errors;
|
||
Array_v__errors__Warning warnings;
|
||
Array_v__errors__Notice notices;
|
||
Array_v__vet__Error vet_errors;
|
||
string file_path;
|
||
string file_base;
|
||
string text;
|
||
string line_comment;
|
||
v__pref__Preferences* pref;
|
||
int pos;
|
||
int line_nr;
|
||
int last_nl_pos;
|
||
int last_lt;
|
||
int nr_lines;
|
||
int tidx;
|
||
int eofs;
|
||
int inter_cbr_count;
|
||
u8 quote;
|
||
u8 inter_quote;
|
||
v__scanner__CommentsMode comments_mode : 2;
|
||
bool is_crlf : 1;
|
||
bool is_inside_string : 1;
|
||
bool is_inter_start : 1;
|
||
bool is_inter_end : 1;
|
||
bool is_enclosed_inter : 1;
|
||
bool is_started : 1;
|
||
bool is_print_line_on_error : 1;
|
||
bool is_print_colored_error : 1;
|
||
bool is_print_rel_paths_on_error : 1;
|
||
bool is_vh : 1;
|
||
bool is_fmt : 1;
|
||
bool is_inside_toplvl_statement : 1;
|
||
bool should_abort : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__parser__EatCommentsConfig {
|
||
bool same_line;
|
||
bool follow_up;
|
||
};
|
||
|
||
|
||
|
||
struct v__markused__Walker {
|
||
v__ast__Table* table;
|
||
Map_string_bool used_fns;
|
||
Map_string_bool used_consts;
|
||
Map_string_bool used_globals;
|
||
int n_asserts;
|
||
v__pref__Preferences* pref;
|
||
Array_v__ast__File_ptr files;
|
||
Map_string_v__ast__FnDecl all_fns;
|
||
Map_string_v__ast__ConstField all_consts;
|
||
Map_string_v__ast__GlobalField all_globals;
|
||
};
|
||
|
||
|
||
|
||
struct v__depgraph__DepGraphNode {
|
||
string name;
|
||
i64 value;
|
||
Array_string deps;
|
||
};
|
||
|
||
|
||
|
||
struct v__depgraph__OrderedDepMap {
|
||
Array_string keys;
|
||
Map_string_Array_string data;
|
||
};
|
||
|
||
|
||
|
||
struct v__depgraph__NodeNames {
|
||
Map_string_bool is_cycle;
|
||
Map_string_Array_string names;
|
||
};
|
||
|
||
|
||
|
||
struct v__dotgraph__DotGraph {
|
||
strings__Builder sb;
|
||
};
|
||
|
||
|
||
|
||
struct v__dotgraph__NewNodeConfig {
|
||
string node_name;
|
||
bool should_highlight;
|
||
string tooltip;
|
||
voidptr ctx;
|
||
v__dotgraph__FnLabel2NodeName name2node_fn;
|
||
};
|
||
|
||
|
||
|
||
struct v__dotgraph__NewEdgeConfig {
|
||
bool should_highlight;
|
||
voidptr ctx;
|
||
v__dotgraph__FnLabel2NodeName name2node_fn;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__Type {
|
||
v__ast__Type typ;
|
||
v__ast__TypeSymbol* sym;
|
||
v__ast__Type unaliased;
|
||
v__ast__TypeSymbol* unaliased_sym;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__StrType {
|
||
string styp;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__GlobalConstDef {
|
||
string mod;
|
||
string def;
|
||
string init;
|
||
Array_string dep_names;
|
||
int order;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__SumtypeCastingFn {
|
||
string fn_name;
|
||
v__ast__Type got;
|
||
v__ast__Type exp;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__GenSafeIntegerCfg {
|
||
v__token__Kind op;
|
||
bool reverse;
|
||
v__ast__Type unsigned_type;
|
||
v__ast__Expr unsigned_expr;
|
||
v__ast__Type signed_type;
|
||
v__ast__Expr signed_expr;
|
||
};
|
||
|
||
|
||
|
||
struct rand__buffer__PRNGBuffer {
|
||
int bytes_left;
|
||
u64 buffer;
|
||
};
|
||
|
||
|
||
|
||
struct v__pkgconfig__MainOptions {
|
||
bool modversion;
|
||
bool description;
|
||
bool help;
|
||
bool debug;
|
||
bool listall;
|
||
bool exists;
|
||
bool variables;
|
||
bool requires;
|
||
string atleast;
|
||
string atleastpc;
|
||
string exactversion;
|
||
bool version;
|
||
bool cflags;
|
||
bool cflags_only_path;
|
||
bool cflags_only_other;
|
||
bool stat1c;
|
||
bool libs;
|
||
bool libs_only_link;
|
||
bool libs_only_path;
|
||
bool libs_only_other;
|
||
Array_string args;
|
||
};
|
||
|
||
|
||
|
||
struct v__pkgconfig__Main {
|
||
v__pkgconfig__MainOptions* opt;
|
||
string res;
|
||
bool has_actions;
|
||
};
|
||
|
||
|
||
|
||
struct v__pkgconfig__Options {
|
||
string path;
|
||
bool debug;
|
||
bool norecurse;
|
||
bool only_description;
|
||
bool use_default_paths;
|
||
};
|
||
|
||
|
||
|
||
struct flag__FlagParser {
|
||
Array_string original_args;
|
||
int idx_dashdash;
|
||
Array_string all_after_dashdash;
|
||
Array_string usage_examples;
|
||
string default_help_label;
|
||
string default_version_label;
|
||
Array_string args;
|
||
int max_free_args;
|
||
Array_flag__Flag flags;
|
||
string application_name;
|
||
string application_version;
|
||
string application_description;
|
||
int min_free_args;
|
||
string args_description;
|
||
bool allow_unknown_args;
|
||
Array_string footers;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__walker__Inspector {
|
||
v__ast__walker__InspectorFn inspector_callback;
|
||
voidptr data;
|
||
};
|
||
|
||
|
||
|
||
struct sync__Semaphore {
|
||
sem_t sem;
|
||
};
|
||
|
||
|
||
|
||
struct sync__RwMutex {
|
||
pthread_rwlock_t mutex;
|
||
};
|
||
|
||
|
||
|
||
struct sync__Mutex {
|
||
pthread_mutex_t mutex;
|
||
};
|
||
|
||
|
||
|
||
struct sync__RwMutexAttr {
|
||
pthread_rwlockattr_t attr;
|
||
};
|
||
|
||
|
||
|
||
struct sync__pool__PoolProcessorConfig {
|
||
int maxjobs;
|
||
sync__pool__ThreadCB callback;
|
||
};
|
||
|
||
|
||
|
||
struct flag__Flag {
|
||
string name;
|
||
u8 abbr;
|
||
string usage;
|
||
string val_desc;
|
||
};
|
||
|
||
|
||
|
||
struct flag__ArgsCountError {
|
||
Error Error;
|
||
int got;
|
||
int want;
|
||
};
|
||
|
||
|
||
|
||
struct semver__Version {
|
||
int major;
|
||
int minor;
|
||
int patch;
|
||
string prerelease;
|
||
string metadata;
|
||
};
|
||
|
||
|
||
|
||
struct semver__RawVersion {
|
||
string prerelease;
|
||
string metadata;
|
||
Array_string raw_ints;
|
||
};
|
||
|
||
|
||
|
||
struct semver__ComparatorSet {
|
||
Array_semver__Comparator comparators;
|
||
};
|
||
|
||
|
||
|
||
struct semver__Range {
|
||
Array_semver__ComparatorSet comparator_sets;
|
||
};
|
||
|
||
|
||
typedef char Array_fixed_C__char_1024 [1024];
|
||
|
||
struct mapnode {
|
||
voidptr* children;
|
||
int len;
|
||
Array_fixed_string_11 keys;
|
||
Array_fixed_voidptr_11 values;
|
||
};
|
||
|
||
|
||
|
||
struct StrIntpData {
|
||
string str;
|
||
u32 fmt;
|
||
StrIntpMem d;
|
||
};
|
||
|
||
|
||
|
||
struct v__pref__Preferences {
|
||
v__vcache__CacheManager cache_manager;
|
||
Array_string profile_fns;
|
||
Array_string lookup_path;
|
||
Array_string run_only;
|
||
Array_string compile_defines;
|
||
Array_string compile_defines_all;
|
||
Array_string run_args;
|
||
Array_string printfn_list;
|
||
Array_string cleanup_files;
|
||
Array_string build_options;
|
||
string test_runner;
|
||
string profile_file;
|
||
string dump_c_flags;
|
||
string dump_modules;
|
||
string dump_files;
|
||
string cflags;
|
||
string ccompiler;
|
||
string third_party_option;
|
||
string bare_builtin_dir;
|
||
string custom_prelude;
|
||
string cmain;
|
||
string vroot;
|
||
string out_name_c;
|
||
string out_name;
|
||
string path;
|
||
int message_limit;
|
||
int checker_match_exhaustive_cutoff_limit;
|
||
int thread_stack_size;
|
||
v__pref__OS os : 5;
|
||
v__pref__Arch arch : 4;
|
||
v__pref__GarbageCollectionMode gc_mode : 3;
|
||
v__pref__Backend backend : 3;
|
||
v__pref__CompilerType ccompiler_type : 3;
|
||
v__pref__ColorOutput use_color : 2;
|
||
v__pref__AssertFailureMode assert_failure_mode : 2;
|
||
v__pref__BuildMode build_mode : 2;
|
||
v__pref__OutputMode output_mode : 2;
|
||
bool is_verbose : 1;
|
||
bool is_glibc : 1;
|
||
bool is_musl : 1;
|
||
bool is_test : 1;
|
||
bool is_script : 1;
|
||
bool is_vsh : 1;
|
||
bool is_livemain : 1;
|
||
bool is_liveshared : 1;
|
||
bool is_shared : 1;
|
||
bool is_o : 1;
|
||
bool is_prof : 1;
|
||
bool is_prod : 1;
|
||
bool is_repl : 1;
|
||
bool is_run : 1;
|
||
bool is_crun : 1;
|
||
bool is_debug : 1;
|
||
bool is_vlines : 1;
|
||
bool is_stats : 1;
|
||
bool is_fmt : 1;
|
||
bool is_vet : 1;
|
||
bool is_vweb : 1;
|
||
bool is_ios_simulator : 1;
|
||
bool is_apk : 1;
|
||
bool is_help : 1;
|
||
bool is_cstrict : 1;
|
||
bool profile_no_inline : 1;
|
||
bool translated : 1;
|
||
bool obfuscate : 1;
|
||
bool sanitize : 1;
|
||
bool sourcemap : 1;
|
||
bool sourcemap_inline : 1;
|
||
bool sourcemap_src_included : 1;
|
||
bool show_cc : 1;
|
||
bool show_c_output : 1;
|
||
bool show_callgraph : 1;
|
||
bool show_depgraph : 1;
|
||
bool use_cache : 1;
|
||
bool retry_compilation : 1;
|
||
bool m64 : 1;
|
||
bool building_v : 1;
|
||
bool autofree : 1;
|
||
bool compress : 1;
|
||
bool no_builtin : 1;
|
||
bool enable_globals : 1;
|
||
bool is_bare : 1;
|
||
bool no_preludes : 1;
|
||
bool output_cross_c : 1;
|
||
bool output_es5 : 1;
|
||
bool prealloc : 1;
|
||
bool print_v_files : 1;
|
||
bool skip_running : 1;
|
||
bool skip_warnings : 1;
|
||
bool warn_impure_v : 1;
|
||
bool warns_are_errors : 1;
|
||
bool fatal_errors : 1;
|
||
bool reuse_tmpc : 1;
|
||
bool no_rsp : 1;
|
||
bool no_std : 1;
|
||
bool no_parallel : 1;
|
||
bool only_check_syntax : 1;
|
||
bool check_only : 1;
|
||
bool experimental : 1;
|
||
bool skip_unused : 1;
|
||
bool show_timings : 1;
|
||
bool nofloat : 1;
|
||
};
|
||
|
||
|
||
|
||
struct os__FileMode {
|
||
os__FileType typ;
|
||
os__FilePermission owner;
|
||
os__FilePermission group;
|
||
os__FilePermission others;
|
||
};
|
||
|
||
|
||
|
||
struct os__Process {
|
||
string filename;
|
||
int pid;
|
||
int code;
|
||
os__ProcessState status;
|
||
string err;
|
||
Array_string args;
|
||
bool env_is_custom;
|
||
Array_string env;
|
||
bool use_stdio_ctl;
|
||
bool use_pgroup;
|
||
Array_fixed_int_3 stdio_fd;
|
||
voidptr wdata;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__Builder {
|
||
string compiled_dir;
|
||
string module_path;
|
||
v__checker__Checker* checker;
|
||
v__transformer__Transformer* transformer;
|
||
string out_name_c;
|
||
string out_name_js;
|
||
int stats_lines;
|
||
int stats_bytes;
|
||
int nr_errors;
|
||
int nr_warnings;
|
||
int nr_notices;
|
||
v__pref__Preferences* pref;
|
||
Array_string module_search_paths;
|
||
Array_v__ast__File_ptr parsed_files;
|
||
v__builder__MsvcResult cached_msvc;
|
||
v__ast__Table* table;
|
||
v__builder__CcompilerOptions ccoptions;
|
||
Map_string_Array_string mod_invalidates_paths;
|
||
Map_string_Array_string mod_invalidates_mods;
|
||
Map_string_Array_string path_invalidates_mods;
|
||
Array_string crun_cache_keys;
|
||
};
|
||
|
||
|
||
|
||
struct v__errors__Error {
|
||
string message;
|
||
string details;
|
||
string file_path;
|
||
string backtrace;
|
||
v__token__Pos pos;
|
||
v__errors__Reporter reporter : 3;
|
||
};
|
||
|
||
|
||
|
||
struct rand__wyrand__WyRandRNG {
|
||
rand__buffer__PRNGBuffer PRNGBuffer;
|
||
u64 state;
|
||
int bytes_left;
|
||
u64 buffer;
|
||
};
|
||
|
||
|
||
|
||
struct v__token__KeywordsMatcher {
|
||
int len_min;
|
||
int len_max;
|
||
Array_fixed_Array_v__token__WIndex_20 words;
|
||
};
|
||
|
||
|
||
|
||
struct v__vmod__Parser {
|
||
string file_path;
|
||
v__vmod__Scanner scanner;
|
||
};
|
||
|
||
|
||
|
||
struct v__errors__Warning {
|
||
string message;
|
||
string details;
|
||
string file_path;
|
||
v__token__Pos pos;
|
||
v__errors__Reporter reporter;
|
||
};
|
||
|
||
|
||
|
||
struct v__errors__Notice {
|
||
string message;
|
||
string details;
|
||
string file_path;
|
||
v__token__Pos pos;
|
||
v__errors__Reporter reporter;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AliasTypeDecl {
|
||
string name;
|
||
bool is_pub;
|
||
v__ast__Type parent_type;
|
||
v__token__Pos pos;
|
||
v__token__Pos type_pos;
|
||
Array_v__ast__Comment comments;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__FnTypeDecl {
|
||
string name;
|
||
bool is_pub;
|
||
v__ast__Type typ;
|
||
v__token__Pos pos;
|
||
v__token__Pos type_pos;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Attr attrs;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SumTypeDecl {
|
||
string name;
|
||
bool is_pub;
|
||
v__token__Pos pos;
|
||
v__token__Pos name_pos;
|
||
Array_v__ast__Comment comments;
|
||
v__ast__Type typ;
|
||
Array_v__ast__Type generic_types;
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__TypeNode variants;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ArrayDecompose {
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
v__ast__Type expr_type;
|
||
v__ast__Type arg_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ArrayInit {
|
||
Array_Array_v__ast__Comment ecmnts;
|
||
Array_v__ast__Comment pre_cmnts;
|
||
Array_v__ast__Expr exprs;
|
||
Array_v__ast__Type expr_types;
|
||
string mod;
|
||
v__ast__Expr len_expr;
|
||
v__ast__Expr cap_expr;
|
||
v__ast__Expr default_expr;
|
||
v__token__Pos pos;
|
||
v__token__Pos elem_type_pos;
|
||
v__ast__Type elem_type;
|
||
v__ast__Type default_type;
|
||
v__ast__Type typ;
|
||
bool is_fixed : 1;
|
||
bool has_val : 1;
|
||
bool has_len : 1;
|
||
bool has_cap : 1;
|
||
bool has_default : 1;
|
||
bool has_it : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsCast {
|
||
v__ast__Type typ;
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
v__ast__Type expr_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Assoc {
|
||
Array_string fields;
|
||
Array_v__ast__Expr exprs;
|
||
string var_name;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AtExpr {
|
||
string name;
|
||
v__token__Pos pos;
|
||
v__token__AtKind kind;
|
||
string val;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__BoolLiteral {
|
||
bool val;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__CastExpr {
|
||
v__ast__Expr arg;
|
||
v__ast__Expr expr;
|
||
string typname;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
v__ast__Type expr_type;
|
||
bool has_arg : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ChanInit {
|
||
v__token__Pos pos;
|
||
bool has_cap;
|
||
v__ast__Expr cap_expr;
|
||
v__ast__Type typ;
|
||
v__ast__Type elem_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__CharLiteral {
|
||
string val;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Comment {
|
||
string text;
|
||
bool is_multi;
|
||
bool is_inline;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ComptimeSelector {
|
||
v__ast__Expr left;
|
||
v__ast__Expr field_expr;
|
||
v__token__Pos pos;
|
||
v__ast__Type left_type;
|
||
v__ast__Type typ;
|
||
bool has_parens : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ComptimeType {
|
||
v__ast__ComptimeTypeKind kind;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ConcatExpr {
|
||
Array_v__ast__Expr vals;
|
||
v__token__Pos pos;
|
||
v__ast__Type return_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__DumpExpr {
|
||
v__ast__Expr expr;
|
||
string cname;
|
||
v__token__Pos pos;
|
||
v__ast__Type expr_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EnumVal {
|
||
string enum_name;
|
||
string val;
|
||
string mod;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__FloatLiteral {
|
||
string val;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Ident {
|
||
v__ast__ScopeObject obj;
|
||
string mod;
|
||
string name;
|
||
v__ast__IdentInfo info;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__token__Pos mut_pos;
|
||
v__token__Kind tok_kind : 7;
|
||
v__ast__Language language : 4;
|
||
v__ast__IdentKind kind : 3;
|
||
bool comptime : 1;
|
||
bool is_mut : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IfExpr {
|
||
Array_v__ast__Comment post_comments;
|
||
Array_v__ast__IfBranch branches;
|
||
v__ast__Expr left;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
v__token__Kind tok_kind : 7;
|
||
bool is_comptime : 1;
|
||
bool is_expr : 1;
|
||
bool has_else : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IntegerLiteral {
|
||
string val;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IsRefType {
|
||
bool is_type;
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Likely {
|
||
v__token__Pos pos;
|
||
bool is_likely;
|
||
v__ast__Expr expr;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__LockExpr {
|
||
Array_bool is_rlock;
|
||
v__token__Pos pos;
|
||
Array_v__ast__Stmt stmts;
|
||
Array_v__ast__Expr lockeds;
|
||
Array_v__ast__Comment comments;
|
||
bool is_expr;
|
||
v__ast__Type typ;
|
||
v__ast__Scope* scope;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__MapInit {
|
||
Array_Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment pre_cmnts;
|
||
Array_v__ast__Expr keys;
|
||
Array_v__ast__Expr vals;
|
||
Array_v__ast__Type val_types;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
v__ast__Type key_type;
|
||
v__ast__Type value_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__MatchExpr {
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__MatchBranch branches;
|
||
v__ast__Expr cond;
|
||
v__token__Pos pos;
|
||
v__ast__Type return_type;
|
||
v__ast__Type cond_type;
|
||
v__ast__Type expected_type;
|
||
v__token__Kind tok_kind : 7;
|
||
bool is_expr : 1;
|
||
bool is_sum_type : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__NodeError {
|
||
int idx;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__None {
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__OffsetOf {
|
||
string field;
|
||
v__token__Pos pos;
|
||
v__ast__Type struct_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__OrExpr {
|
||
Array_v__ast__Stmt stmts;
|
||
v__ast__OrKind kind;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ParExpr {
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__PostfixExpr {
|
||
v__token__Kind op;
|
||
v__token__Pos pos;
|
||
bool is_c2v_prefix;
|
||
v__ast__Expr expr;
|
||
string auto_locked;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__RangeExpr {
|
||
v__ast__Expr low;
|
||
v__ast__Expr high;
|
||
v__token__Pos pos;
|
||
bool has_high : 1;
|
||
bool has_low : 1;
|
||
bool is_gated : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SelectExpr {
|
||
Array_v__ast__SelectBranch branches;
|
||
v__token__Pos pos;
|
||
bool has_exception;
|
||
bool is_expr;
|
||
v__ast__Type expected_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SelectorExpr {
|
||
Array_v__ast__Type from_embed_types;
|
||
string field_name;
|
||
v__ast__Expr expr;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__token__Pos mut_pos;
|
||
v__ast__Type expr_type;
|
||
v__ast__Type typ;
|
||
v__ast__Type name_type;
|
||
v__token__Kind next_token : 7;
|
||
v__ast__GenericKindField gkind_field : 2;
|
||
bool is_mut : 1;
|
||
bool has_hidden_receiver : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SizeOf {
|
||
bool is_type;
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StringInterLiteral {
|
||
Array_string vals;
|
||
Array_int fwidths;
|
||
Array_int precisions;
|
||
Array_bool pluss;
|
||
Array_bool fills;
|
||
Array_v__token__Pos fmt_poss;
|
||
v__token__Pos pos;
|
||
Array_v__ast__Expr exprs;
|
||
Array_v__ast__Type expr_types;
|
||
Array_u8 fmts;
|
||
Array_bool need_fmts;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StringLiteral {
|
||
string val;
|
||
v__token__Pos pos;
|
||
v__ast__Language language : 4;
|
||
bool is_raw : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StructInit {
|
||
Array_v__ast__Comment pre_comments;
|
||
Array_v__ast__Comment update_expr_comments;
|
||
Array_v__ast__StructInitField fields;
|
||
Array_v__ast__StructInitEmbed embeds;
|
||
Array_v__ast__Type generic_types;
|
||
string typ_str;
|
||
v__ast__Expr update_expr;
|
||
v__token__Pos pos;
|
||
v__token__Pos name_pos;
|
||
v__ast__Type typ;
|
||
v__ast__Type update_expr_type;
|
||
bool is_short : 1;
|
||
bool is_short_syntax : 1;
|
||
bool unresolved : 1;
|
||
bool is_update_embed : 1;
|
||
bool has_update_expr : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__TypeNode {
|
||
v__ast__Type typ;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__TypeOf {
|
||
v__ast__Expr expr;
|
||
v__token__Pos pos;
|
||
v__ast__Type expr_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__UnsafeExpr {
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmStmt {
|
||
Array_v__ast__AsmClobbered clobbered;
|
||
Array_v__ast__AsmTemplate templates;
|
||
Array_v__ast__AsmIO output;
|
||
Array_v__ast__AsmIO input;
|
||
Array_string global_labels;
|
||
Array_string local_labels;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__pref__Arch arch : 4;
|
||
bool is_basic : 1;
|
||
bool is_volatile : 1;
|
||
bool is_goto : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AssertStmt {
|
||
v__ast__Expr expr;
|
||
v__token__Pos pos;
|
||
bool is_used : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AssignStmt {
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment end_comments;
|
||
Array_v__ast__Expr right;
|
||
Array_v__ast__Expr left;
|
||
Array_v__ast__Type left_types;
|
||
Array_v__ast__Type right_types;
|
||
v__token__Pos pos;
|
||
v__token__Kind op : 7;
|
||
bool is_static : 1;
|
||
bool is_volatile : 1;
|
||
bool is_simple : 1;
|
||
bool has_cross_var : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Block {
|
||
Array_v__ast__Stmt stmts;
|
||
bool is_unsafe;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__BranchStmt {
|
||
string label;
|
||
v__token__Pos pos;
|
||
v__token__Kind kind : 7;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ComptimeFor {
|
||
string val_var;
|
||
Array_v__ast__Stmt stmts;
|
||
v__ast__ComptimeForKind kind;
|
||
v__token__Pos pos;
|
||
v__token__Pos typ_pos;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ConstDecl {
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__ConstField fields;
|
||
Array_v__ast__Comment end_comments;
|
||
v__token__Pos pos;
|
||
bool is_pub : 1;
|
||
bool is_block : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__DeferStmt {
|
||
Array_v__ast__Stmt stmts;
|
||
Array_v__ast__Ident defer_vars;
|
||
string ifdef;
|
||
v__token__Pos pos;
|
||
int idx_in_fn;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EmptyStmt {
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EnumDecl {
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__EnumField fields;
|
||
Array_v__ast__Attr attrs;
|
||
string name;
|
||
v__token__Pos pos;
|
||
bool is_pub : 1;
|
||
bool is_flag : 1;
|
||
bool is_multi_allowed : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ExprStmt {
|
||
v__token__Pos pos;
|
||
Array_v__ast__Comment comments;
|
||
v__ast__Expr expr;
|
||
bool is_expr;
|
||
v__ast__Type typ;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ForCStmt {
|
||
bool has_init;
|
||
bool has_cond;
|
||
bool has_inc;
|
||
bool is_multi;
|
||
v__token__Pos pos;
|
||
v__ast__Stmt init;
|
||
v__ast__Expr cond;
|
||
v__ast__Stmt inc;
|
||
Array_v__ast__Stmt stmts;
|
||
string label;
|
||
v__ast__Scope* scope;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ForInStmt {
|
||
Array_v__ast__Stmt stmts;
|
||
string key_var;
|
||
string val_var;
|
||
v__ast__Expr high;
|
||
v__ast__Expr cond;
|
||
string label;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__ast__Type key_type;
|
||
v__ast__Type val_type;
|
||
v__ast__Type cond_type;
|
||
v__ast__Type high_type;
|
||
v__ast__Kind kind : 6;
|
||
bool is_range : 1;
|
||
bool val_is_mut : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ForStmt {
|
||
bool is_inf;
|
||
v__token__Pos pos;
|
||
v__ast__Expr cond;
|
||
Array_v__ast__Stmt stmts;
|
||
string label;
|
||
v__ast__Scope* scope;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GlobalDecl {
|
||
string mod;
|
||
v__token__Pos pos;
|
||
bool is_block;
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__GlobalField fields;
|
||
Array_v__ast__Comment end_comments;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GotoLabel {
|
||
string name;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GotoStmt {
|
||
string name;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__HashStmt {
|
||
string mod;
|
||
v__token__Pos pos;
|
||
string source_file;
|
||
string val;
|
||
string kind;
|
||
string main;
|
||
string msg;
|
||
Array_v__ast__Expr ct_conds;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Import {
|
||
string mod;
|
||
string alias;
|
||
v__token__Pos pos;
|
||
v__token__Pos mod_pos;
|
||
v__token__Pos alias_pos;
|
||
v__token__Pos syms_pos;
|
||
Array_v__ast__ImportSymbol syms;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment next_comments;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__InterfaceDecl {
|
||
Array_string field_names;
|
||
Array_v__ast__Comment pre_comments;
|
||
Array_v__ast__Type generic_types;
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__FnDecl methods;
|
||
Array_v__ast__StructField fields;
|
||
Array_v__ast__InterfaceEmbedding embeds;
|
||
string name;
|
||
v__token__Pos name_pos;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
int mut_pos;
|
||
v__ast__Language language : 4;
|
||
bool is_pub : 1;
|
||
bool are_embeds_expanded : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Module {
|
||
string name;
|
||
string short_name;
|
||
Array_v__ast__Attr attrs;
|
||
v__token__Pos pos;
|
||
v__token__Pos name_pos;
|
||
bool is_skipped;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Return {
|
||
v__token__Pos pos;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Expr exprs;
|
||
Array_v__ast__Type types;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SqlStmt {
|
||
v__token__Pos pos;
|
||
v__ast__Expr db_expr;
|
||
Array_v__ast__SqlStmtLine lines;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StructDecl {
|
||
Array_v__ast__Type generic_types;
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__Comment end_comments;
|
||
Array_v__ast__Embed embeds;
|
||
Array_v__ast__StructField fields;
|
||
string name;
|
||
v__token__Pos pos;
|
||
int mut_pos;
|
||
int pub_pos;
|
||
int pub_mut_pos;
|
||
int global_pos;
|
||
int module_pos;
|
||
v__ast__Language language : 4;
|
||
bool is_pub : 1;
|
||
bool is_union : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ConstField {
|
||
string mod;
|
||
string name;
|
||
bool is_pub;
|
||
bool is_markused;
|
||
v__token__Pos pos;
|
||
v__ast__Expr expr;
|
||
v__ast__Type typ;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment end_comments;
|
||
v__ast__ComptTimeConstValue comptime_expr_value;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GlobalField {
|
||
Array_v__ast__Comment comments;
|
||
string name;
|
||
v__ast__Expr expr;
|
||
v__token__Pos pos;
|
||
v__token__Pos typ_pos;
|
||
v__ast__Type typ;
|
||
bool has_expr : 1;
|
||
bool is_markused : 1;
|
||
bool is_volatile : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Var {
|
||
Array_v__ast__Type smartcasts;
|
||
string name;
|
||
v__ast__Expr expr;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
v__ast__Type orig_type;
|
||
v__ast__ShareType share : 2;
|
||
bool is_mut : 1;
|
||
bool is_autofree_tmp : 1;
|
||
bool is_arg : 1;
|
||
bool is_auto_deref : 1;
|
||
bool is_inherited : 1;
|
||
bool is_used : 1;
|
||
bool is_changed : 1;
|
||
bool is_or : 1;
|
||
bool is_tmp : 1;
|
||
bool is_auto_heap : 1;
|
||
bool is_stack_obj : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__CallArg {
|
||
Array_v__ast__Comment comments;
|
||
v__ast__Expr expr;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
v__ast__ShareType share : 2;
|
||
bool is_mut : 1;
|
||
bool is_tmp_autofree : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__EnumField {
|
||
string name;
|
||
v__token__Pos pos;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment next_comments;
|
||
bool has_expr;
|
||
v__ast__Expr expr;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IfBranch {
|
||
v__token__Pos pos;
|
||
v__token__Pos body_pos;
|
||
Array_v__ast__Comment comments;
|
||
v__ast__Expr cond;
|
||
bool pkg_exist;
|
||
Array_v__ast__Stmt stmts;
|
||
v__ast__Scope* scope;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__MatchBranch {
|
||
Array_Array_v__ast__Comment ecmnts;
|
||
v__token__Pos pos;
|
||
bool is_else;
|
||
Array_v__ast__Comment post_comments;
|
||
v__token__Pos branch_pos;
|
||
Array_v__ast__Stmt stmts;
|
||
Array_v__ast__Expr exprs;
|
||
v__ast__Scope* scope;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Param {
|
||
string name;
|
||
v__token__Pos pos;
|
||
v__token__Pos type_pos;
|
||
v__ast__Type typ;
|
||
bool is_mut : 1;
|
||
bool is_auto_rec : 1;
|
||
bool is_hidden : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StructField {
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Attr attrs;
|
||
string default_val;
|
||
string deprecation_msg;
|
||
string deprecated_after;
|
||
v__ast__Expr default_expr;
|
||
string name;
|
||
v__token__Pos pos;
|
||
v__token__Pos type_pos;
|
||
int i;
|
||
v__ast__Type default_expr_typ;
|
||
v__ast__Type typ;
|
||
bool has_default_expr : 1;
|
||
bool is_pub : 1;
|
||
bool is_mut : 1;
|
||
bool is_global : 1;
|
||
bool is_volatile : 1;
|
||
bool is_deprecated : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StructInitField {
|
||
v__token__Pos pos;
|
||
v__token__Pos name_pos;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment next_comments;
|
||
v__ast__Expr expr;
|
||
string name;
|
||
v__ast__Type typ;
|
||
v__ast__Type expected_type;
|
||
v__ast__Type parent_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Attr {
|
||
string name;
|
||
string arg;
|
||
v__ast__Expr ct_expr;
|
||
v__token__Pos pos;
|
||
v__ast__AttrKind kind : 3;
|
||
bool has_arg : 1;
|
||
bool ct_opt : 1;
|
||
bool ct_evaled : 1;
|
||
bool ct_skip : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Embed {
|
||
v__ast__Type typ;
|
||
v__token__Pos pos;
|
||
Array_v__ast__Comment comments;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__InterfaceEmbedding {
|
||
string name;
|
||
v__ast__Type typ;
|
||
v__token__Pos pos;
|
||
Array_v__ast__Comment comments;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__StructInitEmbed {
|
||
v__token__Pos pos;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment next_comments;
|
||
v__ast__Expr expr;
|
||
string name;
|
||
v__ast__Type typ;
|
||
v__ast__Type expected_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ImportSymbol {
|
||
v__token__Pos pos;
|
||
string name;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ScopeStructField {
|
||
Array_v__ast__Type smartcasts;
|
||
string name;
|
||
v__token__Pos pos;
|
||
v__ast__Type struct_type;
|
||
v__ast__Type typ;
|
||
v__ast__Type orig_type;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmClobbered {
|
||
v__ast__AsmRegister reg;
|
||
Array_v__ast__Comment comments;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmTemplate {
|
||
Array_v__ast__AsmArg args;
|
||
Array_v__ast__Comment comments;
|
||
string name;
|
||
v__token__Pos pos;
|
||
bool is_label : 1;
|
||
bool is_directive : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmIO {
|
||
string alias;
|
||
string constraint;
|
||
v__ast__Expr expr;
|
||
Array_v__ast__Comment comments;
|
||
v__ast__Type typ;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmAddressing {
|
||
int scale;
|
||
v__ast__AddressingMode mode;
|
||
v__token__Pos pos;
|
||
string segment;
|
||
v__ast__AsmArg displacement;
|
||
v__ast__AsmArg base;
|
||
v__ast__AsmArg index;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmAlias {
|
||
v__token__Pos pos;
|
||
string name;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AsmDisp {
|
||
string val;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IfGuardVar {
|
||
string name;
|
||
bool is_mut;
|
||
v__token__Pos pos;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__Fn {
|
||
Array_v__ast__Param params;
|
||
Array_string generic_names;
|
||
Array_string dep_names;
|
||
Array_v__ast__Attr attrs;
|
||
string mod;
|
||
string file;
|
||
string name;
|
||
v__token__Pos pos;
|
||
v__token__Pos return_type_pos;
|
||
v__ast__Type return_type;
|
||
v__ast__Type receiver_type;
|
||
int usages;
|
||
int ctdefine_idx;
|
||
voidptr source_fn;
|
||
v__ast__Language language : 4;
|
||
v__ast__Language file_mode : 4;
|
||
bool is_variadic : 1;
|
||
bool is_pub : 1;
|
||
bool is_ctor_new : 1;
|
||
bool is_deprecated : 1;
|
||
bool is_noreturn : 1;
|
||
bool is_unsafe : 1;
|
||
bool is_placeholder : 1;
|
||
bool is_main : 1;
|
||
bool is_test : 1;
|
||
bool is_keep_alive : 1;
|
||
bool is_method : 1;
|
||
bool no_body : 1;
|
||
bool is_conditional : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__parser__Parser {
|
||
Map_string_string imports;
|
||
Map_string_string imported_symbols;
|
||
v__token__Token tok;
|
||
v__token__Token prev_tok;
|
||
v__token__Token peek_tok;
|
||
v__token__Token script_mode_start_token;
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__Import ast_imports;
|
||
Array_string used_imports;
|
||
Array_string auto_imports;
|
||
Array_string label_names;
|
||
Array_string global_labels;
|
||
Array_v__ast__Ident defer_vars;
|
||
Array_v__ast__Type struct_init_generic_types;
|
||
Array_v__ast__Comment if_cond_comments;
|
||
Array_v__errors__Error errors;
|
||
Array_v__errors__Warning warnings;
|
||
Array_v__errors__Notice notices;
|
||
Array_v__vet__Error vet_errors;
|
||
string file_base;
|
||
string file_name;
|
||
string file_name_dir;
|
||
string unique_prefix;
|
||
string mod;
|
||
string expr_mod;
|
||
string cur_fn_name;
|
||
string codegen_text;
|
||
v__pref__Preferences* pref;
|
||
v__ast__Table* table;
|
||
v__ast__Scope* scope;
|
||
v__scanner__Scanner* scanner;
|
||
int expr_level;
|
||
int n_asm;
|
||
v__ast__Language file_backend_mode : 4;
|
||
v__ast__Language language : 4;
|
||
v__ast__Language fn_language : 4;
|
||
v__scanner__CommentsMode comments_mode : 2;
|
||
bool inside_vlib_file : 1;
|
||
bool inside_test_file : 1;
|
||
bool inside_if : 1;
|
||
bool inside_comptime_if : 1;
|
||
bool inside_if_expr : 1;
|
||
bool inside_if_cond : 1;
|
||
bool inside_ct_if_expr : 1;
|
||
bool inside_or_expr : 1;
|
||
bool inside_for : 1;
|
||
bool inside_fn : 1;
|
||
bool inside_fn_return : 1;
|
||
bool inside_unsafe_fn : 1;
|
||
bool inside_str_interp : 1;
|
||
bool inside_array_lit : 1;
|
||
bool inside_in_array : 1;
|
||
bool inside_match : 1;
|
||
bool inside_select : 1;
|
||
bool inside_match_case : 1;
|
||
bool inside_match_body : 1;
|
||
bool inside_unsafe : 1;
|
||
bool inside_sum_type : 1;
|
||
bool inside_asm_template : 1;
|
||
bool inside_asm : 1;
|
||
bool inside_defer : 1;
|
||
bool inside_generic_params : 1;
|
||
bool inside_receiver_param : 1;
|
||
bool inside_struct_field_decl : 1;
|
||
bool or_is_handled : 1;
|
||
bool builtin_mod : 1;
|
||
bool is_manualfree : 1;
|
||
bool has_globals : 1;
|
||
bool is_generated : 1;
|
||
bool is_translated : 1;
|
||
bool is_amp : 1;
|
||
bool returns : 1;
|
||
bool is_stmt_ident : 1;
|
||
bool expecting_type : 1;
|
||
bool name_error : 1;
|
||
bool comptime_if_cond : 1;
|
||
bool should_abort : 1;
|
||
bool script_mode : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__parser__ReceiverParsingInfo {
|
||
string name;
|
||
v__token__Pos pos;
|
||
v__ast__Type typ;
|
||
v__token__Pos type_pos;
|
||
bool is_mut;
|
||
v__ast__Language language;
|
||
};
|
||
|
||
|
||
|
||
struct v__vet__Error {
|
||
string message;
|
||
string details;
|
||
string file_path;
|
||
v__token__Pos pos;
|
||
v__vet__FixKind fix : 2;
|
||
v__vet__ErrorType typ : 2;
|
||
v__vet__ErrorKind kind : 2;
|
||
};
|
||
|
||
|
||
|
||
struct v__callgraph__Mapper {
|
||
int pos;
|
||
v__pref__Preferences* pref;
|
||
v__ast__Table* table;
|
||
v__ast__File* file;
|
||
v__ast__Node* node;
|
||
v__ast__FnDecl* fn_decl;
|
||
string caller_name;
|
||
string dot_caller_name;
|
||
bool is_caller_used;
|
||
v__dotgraph__DotGraph dg;
|
||
};
|
||
|
||
|
||
|
||
struct v__pkgconfig__PkgConfig {
|
||
v__pkgconfig__Options options;
|
||
string name;
|
||
string modname;
|
||
string url;
|
||
string version;
|
||
string description;
|
||
Array_string libs;
|
||
Array_string libs_private;
|
||
Array_string cflags;
|
||
Array_string paths;
|
||
Map_string_string vars;
|
||
Array_string requires;
|
||
Array_string requires_private;
|
||
Array_string conflicts;
|
||
};
|
||
|
||
|
||
|
||
struct sync__Channel {
|
||
u8* ringbuf;
|
||
u8* statusbuf;
|
||
u32 objsize;
|
||
sync__Semaphore writesem;
|
||
sync__Semaphore readsem;
|
||
sync__Semaphore writesem_im;
|
||
sync__Semaphore readsem_im;
|
||
atomic_uintptr_t write_adr;
|
||
atomic_uintptr_t read_adr;
|
||
atomic_uintptr_t adr_read;
|
||
atomic_uintptr_t adr_written;
|
||
u32 write_free;
|
||
u32 read_avail;
|
||
u32 buf_elem_write_idx;
|
||
u32 buf_elem_read_idx;
|
||
sync__Subscription* write_subscriber;
|
||
sync__Subscription* read_subscriber;
|
||
u16 write_sub_mtx;
|
||
u16 read_sub_mtx;
|
||
u16 closed;
|
||
u32 cap;
|
||
};
|
||
|
||
|
||
|
||
struct sync__ManyTimes {
|
||
sync__RwMutex m;
|
||
u64 times;
|
||
u64 count;
|
||
};
|
||
|
||
|
||
|
||
struct sync__Once {
|
||
sync__RwMutex m;
|
||
u64 count;
|
||
};
|
||
|
||
|
||
|
||
struct sync__WaitGroup {
|
||
u32 task_count;
|
||
u32 wait_count;
|
||
sync__Semaphore sem;
|
||
};
|
||
|
||
|
||
|
||
struct semver__Comparator {
|
||
semver__Version ver;
|
||
semver__Operator op;
|
||
};
|
||
|
||
|
||
|
||
struct semver__InvalidComparatorFormatError {
|
||
MessageError MessageError;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__File {
|
||
int nr_lines;
|
||
int nr_bytes;
|
||
v__ast__Module mod;
|
||
v__ast__Scope* global_scope;
|
||
bool is_test;
|
||
bool is_generated;
|
||
bool is_translated;
|
||
int idx;
|
||
string path;
|
||
string path_base;
|
||
v__ast__Scope* scope;
|
||
Array_v__ast__Stmt stmts;
|
||
Array_v__ast__Import imports;
|
||
Array_string auto_imports;
|
||
Array_v__ast__EmbeddedFile embedded_files;
|
||
Map_string_string imported_symbols;
|
||
Array_v__errors__Error errors;
|
||
Array_v__errors__Warning warnings;
|
||
Array_v__errors__Notice notices;
|
||
Array_v__ast__FnDecl_ptr generic_fns;
|
||
Array_string global_labels;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__FnDecl {
|
||
v__ast__StructField receiver;
|
||
Array_string generic_names;
|
||
Array_v__ast__Attr attrs;
|
||
Array_v__ast__Param params;
|
||
Array_v__ast__Stmt stmts;
|
||
Array_v__ast__DeferStmt defer_stmts;
|
||
Array_v__ast__Comment comments;
|
||
Array_v__ast__Comment end_comments;
|
||
Array_v__ast__Comment next_comments;
|
||
Array_string label_names;
|
||
string name;
|
||
string short_name;
|
||
string mod;
|
||
string file;
|
||
v__ast__File* source_file;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos receiver_pos;
|
||
v__token__Pos method_type_pos;
|
||
v__token__Pos body_pos;
|
||
v__token__Pos return_type_pos;
|
||
v__token__Pos pos;
|
||
int method_idx;
|
||
int ctdefine_idx;
|
||
int idx;
|
||
v__ast__Type return_type;
|
||
int ninstances;
|
||
v__ast__Language language : 4;
|
||
v__ast__Language file_mode : 4;
|
||
v__ast__ShareType rec_share : 2;
|
||
bool is_deprecated : 1;
|
||
bool is_pub : 1;
|
||
bool is_variadic : 1;
|
||
bool is_anon : 1;
|
||
bool is_noreturn : 1;
|
||
bool is_manualfree : 1;
|
||
bool is_main : 1;
|
||
bool is_test : 1;
|
||
bool is_conditional : 1;
|
||
bool is_exported : 1;
|
||
bool is_keep_alive : 1;
|
||
bool is_unsafe : 1;
|
||
bool is_markused : 1;
|
||
bool is_method : 1;
|
||
bool rec_mut : 1;
|
||
bool no_body : 1;
|
||
bool is_builtin : 1;
|
||
bool is_direct_arr : 1;
|
||
bool has_return : 1;
|
||
bool should_be_skipped : 1;
|
||
bool has_await : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__CallExpr {
|
||
v__ast__OrExpr or_block;
|
||
Array_v__ast__CallArg args;
|
||
Array_v__ast__Type expected_arg_types;
|
||
Array_v__ast__Type concrete_types;
|
||
Array_v__ast__Type raw_concrete_types;
|
||
Array_v__ast__Type from_embed_types;
|
||
Array_v__ast__Comment comments;
|
||
string mod;
|
||
string name;
|
||
v__ast__Expr left;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__token__Pos name_pos;
|
||
v__token__Pos concrete_list_pos;
|
||
v__ast__Type left_type;
|
||
v__ast__Type receiver_type;
|
||
v__ast__Type return_type;
|
||
v__ast__Type fn_var_type;
|
||
v__ast__Language language : 4;
|
||
bool is_method : 1;
|
||
bool is_field : 1;
|
||
bool is_fn_var : 1;
|
||
bool is_keep_alive : 1;
|
||
bool is_noreturn : 1;
|
||
bool is_ctor_new : 1;
|
||
bool should_be_skipped : 1;
|
||
bool free_receiver : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__IndexExpr {
|
||
v__ast__OrExpr or_expr;
|
||
v__ast__Expr index;
|
||
v__ast__Expr left;
|
||
v__token__Pos pos;
|
||
v__ast__Type left_type;
|
||
bool is_setter : 1;
|
||
bool is_map : 1;
|
||
bool is_array : 1;
|
||
bool is_farray : 1;
|
||
bool is_option : 1;
|
||
bool is_direct : 1;
|
||
bool is_gated : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__InfixExpr {
|
||
v__ast__OrExpr or_block;
|
||
v__ast__Expr left;
|
||
v__ast__Expr right;
|
||
string auto_locked;
|
||
v__ast__ComptTimeConstValue ct_left_value;
|
||
v__ast__ComptTimeConstValue ct_right_value;
|
||
v__token__Pos pos;
|
||
v__ast__Type left_type;
|
||
v__ast__Type right_type;
|
||
v__token__Kind op : 7;
|
||
bool is_stmt : 1;
|
||
bool ct_left_value_evaled : 1;
|
||
bool ct_right_value_evaled : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__PrefixExpr {
|
||
v__ast__OrExpr or_block;
|
||
v__ast__Expr right;
|
||
v__token__Pos pos;
|
||
v__ast__Type right_type;
|
||
v__token__Kind op : 7;
|
||
bool is_option : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SqlExpr {
|
||
v__ast__Type typ;
|
||
bool is_count;
|
||
bool has_where;
|
||
bool has_order;
|
||
bool has_limit;
|
||
bool has_offset;
|
||
bool has_desc;
|
||
bool is_array;
|
||
v__token__Pos pos;
|
||
v__ast__Expr db_expr;
|
||
v__ast__Expr where_expr;
|
||
v__ast__Expr order_expr;
|
||
v__ast__Expr limit_expr;
|
||
v__ast__Expr offset_expr;
|
||
v__ast__TypeNode table_expr;
|
||
Array_v__ast__StructField fields;
|
||
Map_int_v__ast__SqlExpr sub_structs;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SelectBranch {
|
||
v__ast__Comment comment;
|
||
Array_v__ast__Comment post_comments;
|
||
Array_v__ast__Stmt stmts;
|
||
v__ast__Stmt stmt;
|
||
v__token__Pos pos;
|
||
bool is_else : 1;
|
||
bool is_timeout : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__SqlStmtLine {
|
||
v__ast__SqlStmtKind kind;
|
||
v__token__Pos pos;
|
||
v__ast__Expr where_expr;
|
||
Array_v__ast__Expr update_exprs;
|
||
string object_var_name;
|
||
Array_string updated_columns;
|
||
v__ast__TypeNode table_expr;
|
||
Array_v__ast__StructField fields;
|
||
Map_int_v__ast__SqlStmtLine sub_structs;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__FnType {
|
||
bool is_anon;
|
||
bool has_decl;
|
||
v__ast__Fn func;
|
||
};
|
||
|
||
|
||
|
||
struct v__gen__c__Gen {
|
||
v__pref__Preferences* pref;
|
||
v__ast__Type field_data_type;
|
||
string module_built;
|
||
bool timers_should_print;
|
||
v__ast__Table* table;
|
||
strings__Builder out;
|
||
strings__Builder cheaders;
|
||
strings__Builder includes;
|
||
strings__Builder typedefs;
|
||
strings__Builder enum_typedefs;
|
||
strings__Builder definitions;
|
||
strings__Builder type_definitions;
|
||
strings__Builder alias_definitions;
|
||
strings__Builder hotcode_definitions;
|
||
strings__Builder channel_definitions;
|
||
strings__Builder comptime_definitions;
|
||
strings__Builder cleanup;
|
||
Map_string_strings__Builder cleanups;
|
||
strings__Builder gowrappers;
|
||
strings__Builder auto_str_funcs;
|
||
strings__Builder dump_funcs;
|
||
strings__Builder pcs_declarations;
|
||
strings__Builder embedded_data;
|
||
strings__Builder shared_types;
|
||
strings__Builder shared_functions;
|
||
strings__Builder options;
|
||
strings__Builder out_results;
|
||
strings__Builder json_forward_decls;
|
||
strings__Builder sql_buf;
|
||
Map_string_v__gen__c__GlobalConstDef global_const_defs;
|
||
Array_string sorted_global_const_names;
|
||
v__ast__File* file;
|
||
u64 unique_file_path_hash;
|
||
v__ast__FnDecl* fn_decl;
|
||
string last_fn_c_name;
|
||
int tmp_count;
|
||
int tmp_count_af;
|
||
int tmp_count_declarations;
|
||
int global_tmp_count;
|
||
bool discard_or_result;
|
||
bool is_assign_lhs;
|
||
bool is_void_expr_stmt;
|
||
bool is_arraymap_set;
|
||
bool is_amp;
|
||
bool is_sql;
|
||
bool is_shared;
|
||
bool is_vlines_enabled;
|
||
bool is_autofree;
|
||
bool is_builtin_mod;
|
||
bool is_json_fn;
|
||
bool is_js_call;
|
||
bool is_fn_index_call;
|
||
bool is_cc_msvc;
|
||
string vlines_path;
|
||
Map_string_string optionals;
|
||
Map_string_string results;
|
||
__shared__Array_string* done_optionals;
|
||
Map_string_string chan_pop_optionals;
|
||
Map_string_string chan_push_optionals;
|
||
string mtxs;
|
||
Map_string_v__ast__Stmt_ptr labeled_loops;
|
||
v__ast__Stmt* inner_loop;
|
||
Map_int_string shareds;
|
||
int inside_ternary;
|
||
bool inside_map_postfix;
|
||
bool inside_map_infix;
|
||
bool inside_map_index;
|
||
bool inside_opt_data;
|
||
bool inside_if_optional;
|
||
bool inside_match_optional;
|
||
bool inside_vweb_tmpl;
|
||
bool inside_return;
|
||
bool inside_struct_init;
|
||
bool inside_or_block;
|
||
bool inside_call;
|
||
bool inside_for_c_stmt;
|
||
bool inside_comptime_for_field;
|
||
int inside_cast_in_heap;
|
||
bool inside_const;
|
||
bool inside_const_optional;
|
||
bool inside_lambda;
|
||
int loop_depth;
|
||
Map_string_string ternary_names;
|
||
Map_string_Array_string ternary_level_names;
|
||
int arraymap_set_pos;
|
||
Array_int stmt_path_pos;
|
||
bool skip_stmt_pos;
|
||
bool right_is_opt;
|
||
int indent;
|
||
bool empty_line;
|
||
v__token__Kind assign_op;
|
||
Array_v__ast__DeferStmt defer_stmts;
|
||
string defer_ifdef;
|
||
string defer_profile_code;
|
||
Array_string defer_vars;
|
||
Array_v__gen__c__StrType str_types;
|
||
Array_v__gen__c__StrType generated_str_fns;
|
||
__shared__Array_string* threaded_fns;
|
||
__shared__Array_string* waiter_fns;
|
||
Array_v__ast__Type needed_equality_fns;
|
||
Array_v__ast__Type generated_eq_fns;
|
||
__shared__Array_string* array_sort_fn;
|
||
Array_v__ast__Type array_contains_types;
|
||
Array_v__ast__Type array_index_types;
|
||
Array_string auto_fn_definitions;
|
||
Array_v__gen__c__SumtypeCastingFn sumtype_casting_fns;
|
||
Array_string anon_fn_definitions;
|
||
Map_int_bool sumtype_definitions;
|
||
Array_v__ast__Type json_types;
|
||
Array_v__gen__c__ProfileCounterMeta pcs;
|
||
Array_string hotcode_fn_names;
|
||
Array_v__ast__EmbeddedFile embedded_files;
|
||
int sql_i;
|
||
string sql_stmt_name;
|
||
string sql_bind_name;
|
||
Array_string sql_idents;
|
||
Array_v__ast__Type sql_idents_types;
|
||
v__ast__Type sql_left_type;
|
||
string sql_table_name;
|
||
string sql_fkey;
|
||
string sql_parent_id;
|
||
v__gen__c__SqlExprSide sql_side;
|
||
Array_string strs_to_free0;
|
||
string comptime_for_method;
|
||
string comptime_for_field_var;
|
||
v__ast__StructField comptime_for_field_value;
|
||
v__ast__Type comptime_for_field_type;
|
||
Map_string_v__ast__Type comptime_var_type_map;
|
||
bool prevent_sum_type_unwrapping_once;
|
||
int aggregate_type_idx;
|
||
int branch_parent_pos;
|
||
string returned_var_name;
|
||
string infix_left_var_name;
|
||
string called_fn_name;
|
||
v__util__Timers* timers;
|
||
bool force_main_console;
|
||
Map_string_string as_cast_type_names;
|
||
Map_string_string obf_table;
|
||
__shared__Map_string_bool* referenced_fns;
|
||
int nr_closures;
|
||
v__ast__Type expected_cast_type;
|
||
v__ast__Type or_expr_return_type;
|
||
bool anon_fn;
|
||
bool tests_inited;
|
||
bool has_main;
|
||
v__ast__Module cur_mod;
|
||
Array_v__ast__Type cur_concrete_types;
|
||
v__ast__FnDecl* cur_fn;
|
||
v__ast__LockExpr cur_lock;
|
||
Map_int_bool autofree_methods;
|
||
Map_int_bool generated_free_methods;
|
||
Array_string autofree_scope_stmts;
|
||
bool use_segfault_handler;
|
||
Array_string test_function_names;
|
||
};
|
||
|
||
|
||
|
||
struct sync__pool__PoolProcessor {
|
||
voidptr thread_cb;
|
||
int njobs;
|
||
Array_voidptr items;
|
||
Array_voidptr results;
|
||
u32 ntask;
|
||
sync__WaitGroup waitgroup;
|
||
voidptr shared_context;
|
||
Array_voidptr thread_contexts;
|
||
};
|
||
|
||
|
||
|
||
struct v__checker__Checker {
|
||
v__ast__FnDecl main_fn_decl_node;
|
||
v__ast__TypeSymbol cur_orm_ts;
|
||
Map_string_v__ast__Type comptime_fields_type;
|
||
Array_v__errors__Error errors;
|
||
Array_v__errors__Warning warnings;
|
||
Array_v__errors__Notice notices;
|
||
Array_int error_lines;
|
||
Array_string const_deps;
|
||
Array_string const_names;
|
||
Array_string global_names;
|
||
Array_string locked_names;
|
||
Array_string rlocked_names;
|
||
Array_v__ast__Expr ct_cond_stack;
|
||
Array_v__ast__File files;
|
||
Array_string error_details;
|
||
Array_v__ast__Type vweb_gen_types;
|
||
string mod;
|
||
string vmod_file_content;
|
||
string loop_label;
|
||
v__pref__Preferences* pref;
|
||
v__ast__Table* table;
|
||
v__ast__File* file;
|
||
v__ast__ConstField* const_var;
|
||
v__util__Timers* timers;
|
||
v__ast__Scope* fn_scope;
|
||
v__token__Pos smartcast_mut_pos;
|
||
v__token__Pos smartcast_cond_pos;
|
||
int nr_errors;
|
||
int nr_warnings;
|
||
int nr_notices;
|
||
v__ast__Type expected_type;
|
||
v__ast__Type expected_or_type;
|
||
v__ast__Type expected_expr_type;
|
||
int in_for_count;
|
||
int fn_level;
|
||
int stmt_level;
|
||
int expr_level;
|
||
v__ast__Type comptime_fields_default_type;
|
||
int match_exhaustive_cutoff_limit;
|
||
int comptime_call_pos;
|
||
bool should_abort : 1;
|
||
bool returns : 1;
|
||
bool scope_returns : 1;
|
||
bool is_builtin_mod : 1;
|
||
bool is_just_builtin_mod : 1;
|
||
bool is_generated : 1;
|
||
bool inside_unsafe : 1;
|
||
bool inside_const : 1;
|
||
bool inside_anon_fn : 1;
|
||
bool inside_ref_lit : 1;
|
||
bool inside_defer : 1;
|
||
bool inside_fn_arg : 1;
|
||
bool inside_ct_attr : 1;
|
||
bool inside_x_is_type : 1;
|
||
bool inside_comptime_for_field : 1;
|
||
bool skip_flags : 1;
|
||
bool is_last_stmt : 1;
|
||
bool prevent_sum_type_unwrapping_once : 1;
|
||
bool using_new_err_struct : 1;
|
||
bool need_recheck_generic_fns : 1;
|
||
bool inside_sql : 1;
|
||
bool inside_selector_expr : 1;
|
||
bool inside_println_arg : 1;
|
||
bool inside_decl_rhs : 1;
|
||
bool inside_if_guard : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__builder__FunctionRedefinition {
|
||
string fpath;
|
||
int fline;
|
||
string fheader;
|
||
v__ast__FnDecl f;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__AnonFn {
|
||
v__ast__FnDecl decl;
|
||
Array_v__ast__Param inherited_vars;
|
||
v__ast__Type typ;
|
||
bool has_gen;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__ComptimeCall {
|
||
v__ast__File vweb_tmpl;
|
||
v__ast__EmbeddedFile embed_file;
|
||
Array_v__ast__CallArg args;
|
||
string method_name;
|
||
v__ast__Expr left;
|
||
string args_var;
|
||
string env_value;
|
||
v__ast__Scope* scope;
|
||
v__token__Pos pos;
|
||
v__token__Pos method_pos;
|
||
v__token__Pos env_pos;
|
||
v__ast__Type left_type;
|
||
v__ast__Type result_type;
|
||
bool has_parens : 1;
|
||
bool is_vweb : 1;
|
||
bool is_embed : 1;
|
||
bool is_env : 1;
|
||
bool is_pkgconfig : 1;
|
||
};
|
||
|
||
|
||
|
||
struct v__ast__GoExpr {
|
||
v__ast__CallExpr call_expr;
|
||
v__token__Pos pos;
|
||
bool is_expr : 1;
|
||
};
|
||
|
||
|
||
// #end sorted_symbols
|
||
|
||
// BEGIN_multi_return_structs
|
||
struct multi_return_u32_u32 {
|
||
u32 arg0;
|
||
u32 arg1;
|
||
};
|
||
|
||
struct multi_return_u32_u32_u32 {
|
||
u32 arg0;
|
||
u32 arg1;
|
||
u32 arg2;
|
||
};
|
||
|
||
struct multi_return_strconv__ParserState_strconv__PrepNumber {
|
||
strconv__ParserState arg0;
|
||
strconv__PrepNumber arg1;
|
||
};
|
||
|
||
struct multi_return_u64_int {
|
||
u64 arg0;
|
||
int arg1;
|
||
};
|
||
|
||
struct multi_return_strconv__Dec32_bool {
|
||
strconv__Dec32 arg0;
|
||
bool arg1;
|
||
};
|
||
|
||
struct multi_return_strconv__Dec64_bool {
|
||
strconv__Dec64 arg0;
|
||
bool arg1;
|
||
};
|
||
|
||
struct multi_return_string_int {
|
||
string arg0;
|
||
int arg1;
|
||
};
|
||
|
||
struct multi_return_int_bool {
|
||
int arg0;
|
||
bool arg1;
|
||
};
|
||
|
||
struct multi_return_int_int {
|
||
int arg0;
|
||
int arg1;
|
||
};
|
||
|
||
struct multi_return_ref_v__pref__Preferences_string {
|
||
v__pref__Preferences* arg0;
|
||
string arg1;
|
||
};
|
||
|
||
struct multi_return_string_string {
|
||
string arg0;
|
||
string arg1;
|
||
};
|
||
|
||
struct multi_return_u64_u64 {
|
||
u64 arg0;
|
||
u64 arg1;
|
||
};
|
||
|
||
struct multi_return_f64_int {
|
||
f64 arg0;
|
||
int arg1;
|
||
};
|
||
|
||
struct multi_return_f64_f64 {
|
||
f64 arg0;
|
||
f64 arg1;
|
||
};
|
||
|
||
struct multi_return_int_int_int {
|
||
int arg0;
|
||
int arg1;
|
||
int arg2;
|
||
};
|
||
|
||
struct multi_return_int_int_int_int_i64_bool {
|
||
int arg0;
|
||
int arg1;
|
||
int arg2;
|
||
int arg3;
|
||
i64 arg4;
|
||
bool arg5;
|
||
};
|
||
|
||
struct multi_return_Array_string_int {
|
||
Array_string arg0;
|
||
int arg1;
|
||
};
|
||
|
||
struct multi_return_Array_string_v__vmod__ModFileAndFolder {
|
||
Array_string arg0;
|
||
v__vmod__ModFileAndFolder arg1;
|
||
};
|
||
|
||
struct multi_return_string_bool {
|
||
string arg0;
|
||
bool arg1;
|
||
};
|
||
|
||
struct multi_return_v__ast__Fn_Array_v__ast__Type {
|
||
v__ast__Fn arg0;
|
||
Array_v__ast__Type arg1;
|
||
};
|
||
|
||
struct multi_return_v__ast__StructField_Array_v__ast__Type {
|
||
v__ast__StructField arg0;
|
||
Array_v__ast__Type arg1;
|
||
};
|
||
|
||
struct multi_return_ref_v__ast__TypeSymbol_int {
|
||
v__ast__TypeSymbol* arg0;
|
||
int arg1;
|
||
};
|
||
|
||
struct multi_return_bool_bool_int {
|
||
bool arg0;
|
||
bool arg1;
|
||
int arg2;
|
||
};
|
||
|
||
struct multi_return_string_v__token__Pos {
|
||
string arg0;
|
||
v__token__Pos arg1;
|
||
};
|
||
|
||
struct multi_return_bool_int_int {
|
||
bool arg0;
|
||
int arg1;
|
||
int arg2;
|
||
};
|
||
|
||
struct multi_return_Array_v__ast__Param_bool_bool {
|
||
Array_v__ast__Param arg0;
|
||
bool arg1;
|
||
bool arg2;
|
||
};
|
||
|
||
struct multi_return_Array_v__ast__Expr_Array_v__ast__Comment {
|
||
Array_v__ast__Expr arg0;
|
||
Array_v__ast__Comment arg1;
|
||
};
|
||
|
||
struct multi_return_ref_v__ast__File_Array_v__vet__Error {
|
||
v__ast__File* arg0;
|
||
Array_v__vet__Error arg1;
|
||
};
|
||
|
||
struct multi_return_Array_v__ast__Type_Array_string {
|
||
Array_v__ast__Type arg0;
|
||
Array_string arg1;
|
||
};
|
||
|
||
struct multi_return_Map_string_v__ast__FnDecl_Map_string_v__ast__ConstField_Map_string_v__ast__GlobalField {
|
||
Map_string_v__ast__FnDecl arg0;
|
||
Map_string_v__ast__ConstField arg1;
|
||
Map_string_v__ast__GlobalField arg2;
|
||
};
|
||
|
||
struct multi_return_bool_Array_string {
|
||
bool arg0;
|
||
Array_string arg1;
|
||
};
|
||
|
||
struct multi_return_Array_string_Array_string_Array_string {
|
||
Array_string arg0;
|
||
Array_string arg1;
|
||
Array_string arg2;
|
||
};
|
||
|
||
struct multi_return_string_string_string_string {
|
||
string arg0;
|
||
string arg1;
|
||
string arg2;
|
||
string arg3;
|
||
};
|
||
|
||
struct multi_return_int_string_string_string {
|
||
int arg0;
|
||
string arg1;
|
||
string arg2;
|
||
string arg3;
|
||
};
|
||
|
||
struct multi_return_Array_string_Array_string_Array_bool {
|
||
Array_string arg0;
|
||
Array_string arg1;
|
||
Array_bool arg2;
|
||
};
|
||
|
||
struct multi_return_u64_string {
|
||
u64 arg0;
|
||
string arg1;
|
||
};
|
||
|
||
// END_multi_return_structs
|
||
|
||
|
||
typedef struct thread_arg_sync__pool__process_in_thread {
|
||
sync__pool__PoolProcessor* arg1;
|
||
int arg2;
|
||
} thread_arg_sync__pool__process_in_thread;
|
||
void* sync__pool__process_in_thread_thread_wrapper(thread_arg_sync__pool__process_in_thread *arg);
|
||
static bool Array_string_contains(Array_string a, string v); // auto
|
||
static bool Array_v__token__Kind_contains(Array_v__token__Kind a, v__token__Kind v); // auto
|
||
static bool Array_u8_contains(Array_u8 a, u8 v); // auto
|
||
static bool Array_Array_v__ast__Type_contains(Array_Array_v__ast__Type a, Array_v__ast__Type v); // auto
|
||
static bool Array_v__ast__Type_contains(Array_v__ast__Type a, v__ast__Type v); // auto
|
||
static bool Array_int_contains(Array_int a, int v); // auto
|
||
static bool Array_i64_contains(Array_i64 a, i64 v); // auto
|
||
static bool Array_v__gen__c__StrType_contains(Array_v__gen__c__StrType a, v__gen__c__StrType v); // auto
|
||
static bool Array_v__gen__c__SumtypeCastingFn_contains(Array_v__gen__c__SumtypeCastingFn a, v__gen__c__SumtypeCastingFn v); // auto
|
||
static bool Array_v__ast__EmbeddedFile_contains(Array_v__ast__EmbeddedFile a, v__ast__EmbeddedFile v); // auto
|
||
static int Array_string_index(Array_string a, string v); // auto
|
||
|
||
// V alias definitions:
|
||
|
||
// V shared types:
|
||
struct __shared__Array_string {
|
||
sync__RwMutex mtx;
|
||
Array_string val;
|
||
};
|
||
struct __shared__Map_string_bool {
|
||
sync__RwMutex mtx;
|
||
Map_string_bool val;
|
||
};
|
||
|
||
// V Option_xxx definitions:
|
||
struct _option_int {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(int) > 0 ? sizeof(int) : 1];
|
||
};
|
||
|
||
struct _option_f64 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(f64) > 0 ? sizeof(f64) : 1];
|
||
};
|
||
|
||
struct _option_u64 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(u64) > 0 ? sizeof(u64) : 1];
|
||
};
|
||
|
||
struct _option_i64 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(i64) > 0 ? sizeof(i64) : 1];
|
||
};
|
||
|
||
struct _option_rune {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(rune) > 0 ? sizeof(rune) : 1];
|
||
};
|
||
|
||
struct _option_string {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(string) > 0 ? sizeof(string) : 1];
|
||
};
|
||
|
||
struct _option_u8 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(u8) > 0 ? sizeof(u8) : 1];
|
||
};
|
||
|
||
struct _option_v__token__Kind {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__token__Kind) > 0 ? sizeof(v__token__Kind) : 1];
|
||
};
|
||
|
||
struct _option_time__Time {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(time__Time) > 0 ? sizeof(time__Time) : 1];
|
||
};
|
||
|
||
struct _option_multi_return_int_int_int {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(multi_return_int_int_int) > 0 ? sizeof(multi_return_int_int_int) : 1];
|
||
};
|
||
|
||
struct _option_multi_return_int_int_int_int_i64_bool {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(multi_return_int_int_int_int_i64_bool) > 0 ? sizeof(multi_return_int_int_int_int_i64_bool) : 1];
|
||
};
|
||
|
||
struct _option_bool {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(bool) > 0 ? sizeof(bool) : 1];
|
||
};
|
||
|
||
struct _option_void {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(u8) > 0 ? sizeof(u8) : 1];
|
||
};
|
||
|
||
struct _option_flag__Flag {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(flag__Flag) > 0 ? sizeof(flag__Flag) : 1];
|
||
};
|
||
|
||
struct _option_Array_string {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(Array_string) > 0 ? sizeof(Array_string) : 1];
|
||
};
|
||
|
||
struct _option_semver__Range {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(semver__Range) > 0 ? sizeof(semver__Range) : 1];
|
||
};
|
||
|
||
struct _option_semver__Version {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(semver__Version) > 0 ? sizeof(semver__Version) : 1];
|
||
};
|
||
|
||
struct _option_semver__ComparatorSet {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(semver__ComparatorSet) > 0 ? sizeof(semver__ComparatorSet) : 1];
|
||
};
|
||
|
||
struct _option_semver__Comparator {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(semver__Comparator) > 0 ? sizeof(semver__Comparator) : 1];
|
||
};
|
||
|
||
struct _option_os__File {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(os__File) > 0 ? sizeof(os__File) : 1];
|
||
};
|
||
|
||
struct _option_FILE_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(FILE*) > 0 ? sizeof(FILE*) : 1];
|
||
};
|
||
|
||
struct _option_Array_u8 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(Array_u8) > 0 ? sizeof(Array_u8) : 1];
|
||
};
|
||
|
||
struct _option_os__SignalHandler {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(os__SignalHandler) > 0 ? sizeof(os__SignalHandler) : 1];
|
||
};
|
||
|
||
struct _option_term__Coord {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(term__Coord) > 0 ? sizeof(term__Coord) : 1];
|
||
};
|
||
|
||
struct _option_v__vmod__Manifest {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__vmod__Manifest) > 0 ? sizeof(v__vmod__Manifest) : 1];
|
||
};
|
||
|
||
struct _option_multi_return_Array_string_int {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(multi_return_Array_string_int) > 0 ? sizeof(multi_return_Array_string_int) : 1];
|
||
};
|
||
|
||
struct _option_v__pkgconfig__PkgConfig_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__pkgconfig__PkgConfig*) > 0 ? sizeof(v__pkgconfig__PkgConfig*) : 1];
|
||
};
|
||
|
||
struct _option_v__pkgconfig__Main_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__pkgconfig__Main*) > 0 ? sizeof(v__pkgconfig__Main*) : 1];
|
||
};
|
||
|
||
struct _option_u32 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(u32) > 0 ? sizeof(u32) : 1];
|
||
};
|
||
|
||
struct _option_f32 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(f32) > 0 ? sizeof(f32) : 1];
|
||
};
|
||
|
||
struct _option_multi_return_f64_f64 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(multi_return_f64_f64) > 0 ? sizeof(multi_return_f64_f64) : 1];
|
||
};
|
||
|
||
struct _option_v__pref__OS {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__pref__OS) > 0 ? sizeof(v__pref__OS) : 1];
|
||
};
|
||
|
||
struct _option_v__pref__Arch {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__pref__Arch) > 0 ? sizeof(v__pref__Arch) : 1];
|
||
};
|
||
|
||
struct _option_v__pref__Backend {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__pref__Backend) > 0 ? sizeof(v__pref__Backend) : 1];
|
||
};
|
||
|
||
struct _option_time__StopWatch {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(time__StopWatch) > 0 ? sizeof(time__StopWatch) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Ident {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Ident) > 0 ? sizeof(v__ast__Ident) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Attr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Attr) > 0 ? sizeof(v__ast__Attr) : 1];
|
||
};
|
||
|
||
struct _option_i8 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(i8) > 0 ? sizeof(i8) : 1];
|
||
};
|
||
|
||
struct _option_i16 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(i16) > 0 ? sizeof(i16) : 1];
|
||
};
|
||
|
||
struct _option_u16 {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(u16) > 0 ? sizeof(u16) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__ComptTimeConstValue {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__ComptTimeConstValue) > 0 ? sizeof(v__ast__ComptTimeConstValue) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__ScopeObject {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__ScopeObject) > 0 ? sizeof(v__ast__ScopeObject) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__ScopeStructField {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__ScopeStructField) > 0 ? sizeof(v__ast__ScopeStructField) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Var_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Var*) > 0 ? sizeof(v__ast__Var*) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__GlobalField_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__GlobalField*) > 0 ? sizeof(v__ast__GlobalField*) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__ConstField_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__ConstField*) > 0 ? sizeof(v__ast__ConstField*) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Fn {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Fn) > 0 ? sizeof(v__ast__Fn) : 1];
|
||
};
|
||
|
||
struct _option_multi_return_v__ast__Fn_Array_v__ast__Type {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(multi_return_v__ast__Fn_Array_v__ast__Type) > 0 ? sizeof(multi_return_v__ast__Fn_Array_v__ast__Type) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__StructField {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__StructField) > 0 ? sizeof(v__ast__StructField) : 1];
|
||
};
|
||
|
||
struct _option_multi_return_v__ast__StructField_Array_v__ast__Type {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(multi_return_v__ast__StructField_Array_v__ast__Type) > 0 ? sizeof(multi_return_v__ast__StructField_Array_v__ast__Type) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__TypeSymbol_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__TypeSymbol*) > 0 ? sizeof(v__ast__TypeSymbol*) : 1];
|
||
};
|
||
|
||
struct _option_Array_Array_v__ast__Type {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(Array_Array_v__ast__Type) > 0 ? sizeof(Array_Array_v__ast__Type) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Type {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Type) > 0 ? sizeof(v__ast__Type) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__InterfaceDecl {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__InterfaceDecl) > 0 ? sizeof(v__ast__InterfaceDecl) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__EnumDecl {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__EnumDecl) > 0 ? sizeof(v__ast__EnumDecl) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Expr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Expr) > 0 ? sizeof(v__ast__Expr) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Param {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Param) > 0 ? sizeof(v__ast__Param) : 1];
|
||
};
|
||
|
||
struct _option_Array_v__ast__Type {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(Array_v__ast__Type) > 0 ? sizeof(Array_v__ast__Type) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__ConstField {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__ConstField) > 0 ? sizeof(v__ast__ConstField) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__GlobalField {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__GlobalField) > 0 ? sizeof(v__ast__GlobalField) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__FnDecl {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__FnDecl) > 0 ? sizeof(v__ast__FnDecl) : 1];
|
||
};
|
||
|
||
struct _option_v__gen__c__GlobalConstDef {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__gen__c__GlobalConstDef) > 0 ? sizeof(v__gen__c__GlobalConstDef) : 1];
|
||
};
|
||
|
||
struct _option_v__ast__Stmt_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__ast__Stmt*) > 0 ? sizeof(v__ast__Stmt*) : 1];
|
||
};
|
||
|
||
struct _option_v__scanner__Scanner_ptr {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__scanner__Scanner*) > 0 ? sizeof(v__scanner__Scanner*) : 1];
|
||
};
|
||
|
||
struct _option_v__builder__MsvcResult {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__builder__MsvcResult) > 0 ? sizeof(v__builder__MsvcResult) : 1];
|
||
};
|
||
|
||
struct _option_v__builder__WindowsKit {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__builder__WindowsKit) > 0 ? sizeof(v__builder__WindowsKit) : 1];
|
||
};
|
||
|
||
struct _option_v__builder__VsInstallation {
|
||
byte state;
|
||
IError err;
|
||
byte data[sizeof(v__builder__VsInstallation) > 0 ? sizeof(v__builder__VsInstallation) : 1];
|
||
};
|
||
|
||
|
||
// V result_xxx definitions:
|
||
|
||
// V json forward decls:
|
||
|
||
// V definitions:
|
||
static char * v_typeof_interface_IError(int sidx);
|
||
static char * v_typeof_interface_rand__PRNG(int sidx);
|
||
static char * v_typeof_interface_hash__Hasher(int sidx);
|
||
static char * v_typeof_interface_hash__Hash32er(int sidx);
|
||
static char * v_typeof_interface_hash__Hash64er(int sidx);
|
||
static char * v_typeof_interface_v__ast__walker__Visitor(int sidx);
|
||
// end of definitions #endif
|
||
strings__Builder strings__new_builder(int initial_size);
|
||
void strings__Builder_write_ptr(strings__Builder* b, u8* ptr, int len);
|
||
void strings__Builder_write_rune(strings__Builder* b, rune r);
|
||
void strings__Builder_write_runes(strings__Builder* b, Array_rune runes);
|
||
void strings__Builder_clear(strings__Builder* b);
|
||
void strings__Builder_write_u8(strings__Builder* b, u8 data);
|
||
void strings__Builder_write_byte(strings__Builder* b, byte data);
|
||
_option_int strings__Builder_write(strings__Builder* b, Array_u8 data);
|
||
void strings__Builder_drain_builder(strings__Builder* b, strings__Builder* other, int other_new_cap);
|
||
u8 strings__Builder_byte_at(strings__Builder* b, int n);
|
||
void strings__Builder_write_string(strings__Builder* b, string s);
|
||
void strings__Builder_go_back(strings__Builder* b, int n);
|
||
VV_LOCAL_SYMBOL string strings__Builder_spart(strings__Builder* b, int start_pos, int n);
|
||
string strings__Builder_cut_last(strings__Builder* b, int n);
|
||
string strings__Builder_cut_to(strings__Builder* b, int pos);
|
||
void strings__Builder_go_back_to(strings__Builder* b, int pos);
|
||
void strings__Builder_writeln(strings__Builder* b, string s);
|
||
string strings__Builder_last_n(strings__Builder* b, int n);
|
||
string strings__Builder_after(strings__Builder* b, int n);
|
||
string strings__Builder_str(strings__Builder* b);
|
||
void strings__Builder_ensure_cap(strings__Builder* b, int n);
|
||
void strings__Builder_free(strings__Builder* b);
|
||
int strings__levenshtein_distance(string a, string b);
|
||
f32 strings__levenshtein_distance_percentage(string a, string b);
|
||
f32 strings__dice_coefficient(string s1, string s2);
|
||
string strings__repeat(u8 c, int n);
|
||
string strings__repeat_string(string s, int n);
|
||
string strings__find_between_pair_u8(string input, u8 start, u8 end);
|
||
string strings__find_between_pair_rune(string input, rune start, rune end);
|
||
string strings__find_between_pair_string(string input, string start, string end);
|
||
Array_string strings__split_capital(string s);
|
||
int math__bits__leading_zeros_8(u8 x);
|
||
int math__bits__leading_zeros_16(u16 x);
|
||
int math__bits__leading_zeros_32(u32 x);
|
||
int math__bits__leading_zeros_64(u64 x);
|
||
int math__bits__trailing_zeros_8(u8 x);
|
||
int math__bits__trailing_zeros_16(u16 x);
|
||
int math__bits__trailing_zeros_32(u32 x);
|
||
int math__bits__trailing_zeros_64(u64 x);
|
||
int math__bits__ones_count_8(u8 x);
|
||
int math__bits__ones_count_16(u16 x);
|
||
int math__bits__ones_count_32(u32 x);
|
||
int math__bits__ones_count_64(u64 x);
|
||
u8 math__bits__rotate_left_8(u8 x, int k);
|
||
u16 math__bits__rotate_left_16(u16 x, int k);
|
||
u32 math__bits__rotate_left_32(u32 x, int k);
|
||
u64 math__bits__rotate_left_64(u64 x, int k);
|
||
u8 math__bits__reverse_8(u8 x);
|
||
u16 math__bits__reverse_16(u16 x);
|
||
u32 math__bits__reverse_32(u32 x);
|
||
u64 math__bits__reverse_64(u64 x);
|
||
u16 math__bits__reverse_bytes_16(u16 x);
|
||
u32 math__bits__reverse_bytes_32(u32 x);
|
||
u64 math__bits__reverse_bytes_64(u64 x);
|
||
int math__bits__len_8(u8 x);
|
||
int math__bits__len_16(u16 x);
|
||
int math__bits__len_32(u32 x);
|
||
int math__bits__len_64(u64 x);
|
||
multi_return_u32_u32 math__bits__add_32(u32 x, u32 y, u32 carry);
|
||
multi_return_u64_u64 math__bits__add_64(u64 x, u64 y, u64 carry);
|
||
multi_return_u32_u32 math__bits__sub_32(u32 x, u32 y, u32 borrow);
|
||
multi_return_u64_u64 math__bits__sub_64(u64 x, u64 y, u64 borrow);
|
||
multi_return_u32_u32 math__bits__mul_32(u32 x, u32 y);
|
||
multi_return_u64_u64 math__bits__mul_64(u64 x, u64 y);
|
||
multi_return_u32_u32 math__bits__div_32(u32 hi, u32 lo, u32 y);
|
||
multi_return_u64_u64 math__bits__div_64(u64 hi, u64 lo, u64 y1);
|
||
u32 math__bits__rem_32(u32 hi, u32 lo, u32 y);
|
||
u64 math__bits__rem_64(u64 hi, u64 lo, u64 y);
|
||
multi_return_f64_int math__bits__normalize(f64 x);
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__lsr96(u32 s2, u32 s1, u32 s0);
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__lsl96(u32 s2, u32 s1, u32 s0);
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__add96(u32 s2, u32 s1, u32 s0, u32 d2, u32 d1, u32 d0);
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__sub96(u32 s2, u32 s1, u32 s0, u32 d2, u32 d1, u32 d0);
|
||
VV_LOCAL_SYMBOL bool strconv__is_digit(u8 x);
|
||
VV_LOCAL_SYMBOL bool strconv__is_space(u8 x);
|
||
VV_LOCAL_SYMBOL bool strconv__is_exp(u8 x);
|
||
VV_LOCAL_SYMBOL multi_return_strconv__ParserState_strconv__PrepNumber strconv__parser(string s);
|
||
VV_LOCAL_SYMBOL u64 strconv__converter(strconv__PrepNumber* pn);
|
||
_option_f64 strconv__atof64(string s);
|
||
f64 strconv__atof_quick(string s);
|
||
u8 strconv__byte_to_lower(u8 c);
|
||
_option_u64 strconv__common_parse_uint(string s, int _base, int _bit_size, bool error_on_non_digit, bool error_on_high_digit);
|
||
multi_return_u64_int strconv__common_parse_uint2(string s, int _base, int _bit_size);
|
||
_option_u64 strconv__parse_uint(string s, int _base, int _bit_size);
|
||
_option_i64 strconv__common_parse_int(string _s, int base, int _bit_size, bool error_on_non_digit, bool error_on_high_digit);
|
||
_option_i64 strconv__parse_int(string _s, int base, int _bit_size);
|
||
_option_int strconv__atoi(string s);
|
||
VV_LOCAL_SYMBOL bool strconv__underscore_ok(string s);
|
||
string strconv__Dec32_get_string_32(strconv__Dec32 d, bool neg, int i_n_digit, int i_pad_digit);
|
||
VV_LOCAL_SYMBOL multi_return_strconv__Dec32_bool strconv__f32_to_decimal_exact_int(u32 i_mant, u32 exp);
|
||
VV_LOCAL_SYMBOL strconv__Dec32 strconv__f32_to_decimal(u32 mant, u32 exp);
|
||
string strconv__f32_to_str(f32 f, int n_digit);
|
||
string strconv__f32_to_str_pad(f32 f, int n_digit);
|
||
VV_LOCAL_SYMBOL string strconv__Dec64_get_string_64(strconv__Dec64 d, bool neg, int i_n_digit, int i_pad_digit);
|
||
VV_LOCAL_SYMBOL multi_return_strconv__Dec64_bool strconv__f64_to_decimal_exact_int(u64 i_mant, u64 exp);
|
||
VV_LOCAL_SYMBOL strconv__Dec64 strconv__f64_to_decimal(u64 mant, u64 exp);
|
||
string strconv__f64_to_str(f64 f, int n_digit);
|
||
string strconv__f64_to_str_pad(f64 f, int n_digit);
|
||
string strconv__format_str(string s, strconv__BF_param p);
|
||
void strconv__format_str_sb(string s, strconv__BF_param p, strings__Builder* sb);
|
||
void strconv__format_dec_sb(u64 d, strconv__BF_param p, strings__Builder* res);
|
||
string strconv__f64_to_str_lnd1(f64 f, int dec_digit);
|
||
string strconv__format_fl(f64 f, strconv__BF_param p);
|
||
string strconv__format_es(f64 f, strconv__BF_param p);
|
||
string strconv__remove_tail_zeros(string s);
|
||
string strconv__ftoa_64(f64 f);
|
||
string strconv__ftoa_long_64(f64 f);
|
||
string strconv__ftoa_32(f32 f);
|
||
string strconv__ftoa_long_32(f32 f);
|
||
string strconv__format_int(i64 n, int radix);
|
||
string strconv__format_uint(u64 n, int radix);
|
||
string strconv__f32_to_str_l(f32 f);
|
||
string strconv__f32_to_str_l_no_dot(f32 f);
|
||
string strconv__f64_to_str_l(f64 f);
|
||
string strconv__f64_to_str_l_no_dot(f64 f);
|
||
string strconv__fxx_to_str_l_parse(string s);
|
||
string strconv__fxx_to_str_l_parse_no_dot(string s);
|
||
VV_LOCAL_SYMBOL int strconv__bool_to_int(bool b);
|
||
VV_LOCAL_SYMBOL u32 strconv__bool_to_u32(bool b);
|
||
VV_LOCAL_SYMBOL u64 strconv__bool_to_u64(bool b);
|
||
VV_LOCAL_SYMBOL string strconv__get_string_special(bool neg, bool expZero, bool mantZero);
|
||
VV_LOCAL_SYMBOL u32 strconv__mul_shift_32(u32 m, u64 mul, int ishift);
|
||
VV_LOCAL_SYMBOL u32 strconv__mul_pow5_invdiv_pow2(u32 m, u32 q, int j);
|
||
VV_LOCAL_SYMBOL u32 strconv__mul_pow5_div_pow2(u32 m, u32 i, int j);
|
||
VV_LOCAL_SYMBOL u32 strconv__pow5_factor_32(u32 i_v);
|
||
VV_LOCAL_SYMBOL bool strconv__multiple_of_power_of_five_32(u32 v, u32 p);
|
||
VV_LOCAL_SYMBOL bool strconv__multiple_of_power_of_two_32(u32 v, u32 p);
|
||
VV_LOCAL_SYMBOL u32 strconv__log10_pow2(int e);
|
||
VV_LOCAL_SYMBOL u32 strconv__log10_pow5(int e);
|
||
VV_LOCAL_SYMBOL int strconv__pow5_bits(int e);
|
||
VV_LOCAL_SYMBOL u64 strconv__shift_right_128(strconv__Uint128 v, int shift);
|
||
VV_LOCAL_SYMBOL u64 strconv__mul_shift_64(u64 m, strconv__Uint128 mul, int shift);
|
||
VV_LOCAL_SYMBOL u32 strconv__pow5_factor_64(u64 v_i);
|
||
VV_LOCAL_SYMBOL bool strconv__multiple_of_power_of_five_64(u64 v, u32 p);
|
||
VV_LOCAL_SYMBOL bool strconv__multiple_of_power_of_two_64(u64 v, u32 p);
|
||
int strconv__dec_digits(u64 n);
|
||
void strconv__v_printf(string str, Array_voidptr pt);
|
||
string strconv__v_sprintf(string str, Array_voidptr pt);
|
||
VV_LOCAL_SYMBOL void strconv__v_sprintf_panic(int idx, int len);
|
||
VV_LOCAL_SYMBOL f64 strconv__fabs(f64 x);
|
||
string strconv__format_fl_old(f64 f, strconv__BF_param p);
|
||
VV_LOCAL_SYMBOL string strconv__format_es_old(f64 f, strconv__BF_param p);
|
||
VV_LOCAL_SYMBOL string strconv__remove_tail_zeros_old(string s);
|
||
string strconv__format_dec_old(u64 d, strconv__BF_param p);
|
||
VV_LOCAL_SYMBOL array __new_array(int mylen, int cap, int elm_size);
|
||
VV_LOCAL_SYMBOL array __new_array_with_default(int mylen, int cap, int elm_size, voidptr val);
|
||
VV_LOCAL_SYMBOL array __new_array_with_array_default(int mylen, int cap, int elm_size, array val);
|
||
VV_LOCAL_SYMBOL array __new_array_with_map_default(int mylen, int cap, int elm_size, map val);
|
||
VV_LOCAL_SYMBOL array new_array_from_c_array(int len, int cap, int elm_size, voidptr c_array);
|
||
VV_LOCAL_SYMBOL array new_array_from_c_array_no_alloc(int len, int cap, int elm_size, voidptr c_array);
|
||
VV_LOCAL_SYMBOL void array_ensure_cap(array* a, int required);
|
||
array array_repeat(array a, int count);
|
||
array array_repeat_to_depth(array a, int count, int depth);
|
||
void array_insert(array* a, int i, voidptr val);
|
||
VV_LOCAL_SYMBOL void array_insert_many(array* a, int i, voidptr val, int size);
|
||
void array_prepend(array* a, voidptr val);
|
||
VV_LOCAL_SYMBOL void array_prepend_many(array* a, voidptr val, int size);
|
||
void array_delete(array* a, int i);
|
||
void array_delete_many(array* a, int i, int size);
|
||
void array_clear(array* a);
|
||
void array_trim(array* a, int index);
|
||
void array_drop(array* a, int num);
|
||
VV_LOCAL_SYMBOL voidptr array_get_unsafe(array a, int i);
|
||
VV_LOCAL_SYMBOL voidptr array_get(array a, int i);
|
||
VV_LOCAL_SYMBOL voidptr array_get_with_check(array a, int i);
|
||
voidptr array_first(array a);
|
||
voidptr array_last(array a);
|
||
voidptr array_pop(array* a);
|
||
void array_delete_last(array* a);
|
||
VV_LOCAL_SYMBOL array array_slice(array a, int start, int _end);
|
||
VV_LOCAL_SYMBOL array array_slice_ni(array a, int _start, int _end);
|
||
VV_LOCAL_SYMBOL array array_slice2(array a, int start, int _end, bool end_max);
|
||
VV_LOCAL_SYMBOL array array_clone_static_to_depth(array a, int depth);
|
||
array array_clone(array* a);
|
||
array array_clone_to_depth(array* a, int depth);
|
||
VV_LOCAL_SYMBOL void array_set_unsafe(array* a, int i, voidptr val);
|
||
VV_LOCAL_SYMBOL void array_set(array* a, int i, voidptr val);
|
||
VV_LOCAL_SYMBOL void array_push(array* a, voidptr val);
|
||
void array_push_many(array* a3, voidptr val, int size);
|
||
void array_reverse_in_place(array* a);
|
||
array array_reverse(array a);
|
||
void array_free(array* a);
|
||
array array_filter(array a, bool (*predicate)(voidptr ));
|
||
bool array_any(array a, bool (*predicate)(voidptr ));
|
||
bool array_all(array a, bool (*predicate)(voidptr ));
|
||
array array_map(array a, voidptr (*callback)(voidptr ));
|
||
void array_sort(array* a, int (*callback)(voidptr , voidptr ));
|
||
void array_sort_with_compare(array* a, int (*callback)(voidptr , voidptr ));
|
||
bool array_contains(array a, voidptr value);
|
||
int array_index(array a, voidptr value);
|
||
void Array_string_free(Array_string* a);
|
||
string Array_string_str(Array_string a);
|
||
string Array_u8_hex(Array_u8 b);
|
||
int copy(Array_u8* dst, Array_u8 src);
|
||
int Array_int_reduce(Array_int a, int (*iter)(int , int ), int accum_start);
|
||
void array_grow_cap(array* a, int amount);
|
||
void array_grow_len(array* a, int amount);
|
||
Array_voidptr array_pointers(array a);
|
||
Array_u8 voidptr_vbytes(voidptr data, int len);
|
||
Array_u8 u8_vbytes(u8* data, int len);
|
||
VV_LOCAL_SYMBOL array __new_array_noscan(int mylen, int cap, int elm_size);
|
||
VV_LOCAL_SYMBOL void vhalt(void);
|
||
void _v_exit(int code);
|
||
VV_LOCAL_SYMBOL string vcommithash(void);
|
||
VV_LOCAL_SYMBOL void panic_debug(int line_no, string file, string mod, string fn_name, string s);
|
||
void panic_optional_not_set(string s);
|
||
void panic_result_not_set(string s);
|
||
void _v_panic(string s);
|
||
string c_error_number_str(int errnum);
|
||
void panic_error_number(string basestr, int errnum);
|
||
void eprintln(string s);
|
||
void eprint(string s);
|
||
void flush_stdout(void);
|
||
void flush_stderr(void);
|
||
void print(string s);
|
||
void println(string s);
|
||
VV_LOCAL_SYMBOL void _writeln_to_fd(int fd, string s);
|
||
VV_LOCAL_SYMBOL void _write_buf_to_fd(int fd, u8* buf, int buf_len);
|
||
u8* _v_malloc(isize n);
|
||
u8* malloc_noscan(isize n);
|
||
u8* malloc_uncollectable(isize n);
|
||
u8* v_realloc(u8* b, isize n);
|
||
u8* realloc_data(u8* old_data, int old_size, int new_size);
|
||
u8* vcalloc(isize n);
|
||
u8* vcalloc_noscan(isize n);
|
||
void _v_free(voidptr ptr);
|
||
voidptr memdup(voidptr src, int sz);
|
||
voidptr memdup_noscan(voidptr src, int sz);
|
||
voidptr memdup_uncollectable(voidptr src, int sz);
|
||
VV_LOCAL_SYMBOL int v_fixed_index(int i, int len);
|
||
void print_backtrace(void);
|
||
bool isnil(voidptr v);
|
||
VV_LOCAL_SYMBOL voidptr __as_cast(voidptr obj, int obj_type, int expected_type);
|
||
void VAssertMetaInfo_free(VAssertMetaInfo* ami);
|
||
VV_LOCAL_SYMBOL void __print_assert_failure(VAssertMetaInfo* i);
|
||
VV_LOCAL_SYMBOL void v_segmentation_fault_handler(int signal);
|
||
VV_LOCAL_SYMBOL void builtin_init(void);
|
||
VV_LOCAL_SYMBOL bool print_backtrace_skipping_top_frames(int xskipframes);
|
||
VV_LOCAL_SYMBOL bool print_backtrace_skipping_top_frames_bsd(int skipframes);
|
||
VV_LOCAL_SYMBOL bool print_backtrace_skipping_top_frames_linux(int skipframes);
|
||
VV_LOCAL_SYMBOL void break_if_debugger_attached(void);
|
||
string winapi_lasterr_str(void);
|
||
void panic_lasterr(void);
|
||
void gc_check_leaks(void);
|
||
VV_LOCAL_SYMBOL void print_libbacktrace(int frames_to_skip);
|
||
VV_LOCAL_SYMBOL void eprint_libbacktrace(int frames_to_skip);
|
||
int proc_pidpath(int , voidptr , int );
|
||
int vstrlen(byte* s);
|
||
int vstrlen_char(char* s);
|
||
voidptr vmemcpy(voidptr dest, const voidptr const_src, isize n);
|
||
voidptr vmemmove(voidptr dest, const voidptr const_src, isize n);
|
||
int vmemcmp(const voidptr const_s1, const voidptr const_s2, isize n);
|
||
voidptr vmemset(voidptr s, int c, isize n);
|
||
VV_LOCAL_SYMBOL void vqsort(voidptr base, usize nmemb, usize size, int (*sort_cb)(const voidptr const_a, const voidptr const_b));
|
||
void chan_close(chan ch);
|
||
ChanState chan_try_pop(chan ch, voidptr obj);
|
||
ChanState chan_try_push(chan ch, voidptr obj);
|
||
string f64_str(f64 x);
|
||
string f64_strg(f64 x);
|
||
string float_literal_str(float_literal d);
|
||
string f64_strsci(f64 x, int digit_num);
|
||
string f64_strlong(f64 x);
|
||
string f32_str(f32 x);
|
||
string f32_strg(f32 x);
|
||
string f32_strsci(f32 x, int digit_num);
|
||
string f32_strlong(f32 x);
|
||
f32 f32_abs(f32 a);
|
||
VV_LOCAL_SYMBOL f64 f64_abs(f64 a);
|
||
f32 f32_max(f32 a, f32 b);
|
||
f32 f32_min(f32 a, f32 b);
|
||
f64 f64_max(f64 a, f64 b);
|
||
VV_LOCAL_SYMBOL f64 f64_min(f64 a, f64 b);
|
||
bool f32_eq_epsilon(f32 a, f32 b);
|
||
bool f64_eq_epsilon(f64 a, f64 b);
|
||
VV_LOCAL_SYMBOL void float_test(void);
|
||
string ptr_str(voidptr ptr);
|
||
string isize_str(isize x);
|
||
string usize_str(usize x);
|
||
string char_str(char* cptr);
|
||
VV_LOCAL_SYMBOL string int_str_l(int nn, int max);
|
||
string i8_str(i8 n);
|
||
string i16_str(i16 n);
|
||
string u16_str(u16 n);
|
||
string int_str(int n);
|
||
string u32_str(u32 nn);
|
||
string int_literal_str(int_literal n);
|
||
string i64_str(i64 nn);
|
||
string u64_str(u64 nn);
|
||
string bool_str(bool b);
|
||
VV_LOCAL_SYMBOL string u64_to_hex(u64 nn, u8 len);
|
||
VV_LOCAL_SYMBOL string u64_to_hex_no_leading_zeros(u64 nn, u8 len);
|
||
string u8_hex(u8 nn);
|
||
string i8_hex(i8 nn);
|
||
string u16_hex(u16 nn);
|
||
string i16_hex(i16 nn);
|
||
string u32_hex(u32 nn);
|
||
string int_hex(int nn);
|
||
string int_hex2(int n);
|
||
string u64_hex(u64 nn);
|
||
string i64_hex(i64 nn);
|
||
string int_literal_hex(int_literal nn);
|
||
string voidptr_str(voidptr nn);
|
||
string byteptr_str(byteptr nn);
|
||
string charptr_str(charptr nn);
|
||
string u8_hex_full(u8 nn);
|
||
string i8_hex_full(i8 nn);
|
||
string u16_hex_full(u16 nn);
|
||
string i16_hex_full(i16 nn);
|
||
string u32_hex_full(u32 nn);
|
||
string int_hex_full(int nn);
|
||
string i64_hex_full(i64 nn);
|
||
string voidptr_hex_full(voidptr nn);
|
||
string int_literal_hex_full(int_literal nn);
|
||
string u64_hex_full(u64 nn);
|
||
string u8_str(u8 b);
|
||
string u8_ascii_str(u8 b);
|
||
string u8_str_escaped(u8 b);
|
||
bool u8_is_capital(u8 c);
|
||
Array_u8 Array_u8_clone(Array_u8 b);
|
||
string Array_u8_bytestr(Array_u8 b);
|
||
_option_rune Array_u8_byterune(Array_u8 b);
|
||
string u8_repeat(u8 b, int count);
|
||
VV_LOCAL_SYMBOL string _Atomic__int_str(int x);
|
||
VV_LOCAL_SYMBOL bool fast_string_eq(string a, string b);
|
||
VV_LOCAL_SYMBOL u64 map_hash_string(voidptr pkey);
|
||
VV_LOCAL_SYMBOL u64 map_hash_int_1(voidptr pkey);
|
||
VV_LOCAL_SYMBOL u64 map_hash_int_2(voidptr pkey);
|
||
VV_LOCAL_SYMBOL u64 map_hash_int_4(voidptr pkey);
|
||
VV_LOCAL_SYMBOL u64 map_hash_int_8(voidptr pkey);
|
||
VV_LOCAL_SYMBOL void DenseArray_zeros_to_end(DenseArray* d);
|
||
VV_LOCAL_SYMBOL DenseArray new_dense_array(int key_bytes, int value_bytes);
|
||
VV_LOCAL_SYMBOL voidptr DenseArray_key(DenseArray* d, int i);
|
||
VV_LOCAL_SYMBOL voidptr DenseArray_value(DenseArray* d, int i);
|
||
VV_LOCAL_SYMBOL bool DenseArray_has_index(DenseArray* d, int i);
|
||
VV_LOCAL_SYMBOL int DenseArray_expand(DenseArray* d);
|
||
VV_LOCAL_SYMBOL bool map_eq_string(voidptr a, voidptr b);
|
||
VV_LOCAL_SYMBOL bool map_eq_int_1(voidptr a, voidptr b);
|
||
VV_LOCAL_SYMBOL bool map_eq_int_2(voidptr a, voidptr b);
|
||
VV_LOCAL_SYMBOL bool map_eq_int_4(voidptr a, voidptr b);
|
||
VV_LOCAL_SYMBOL bool map_eq_int_8(voidptr a, voidptr b);
|
||
VV_LOCAL_SYMBOL void map_clone_string(voidptr dest, voidptr pkey);
|
||
VV_LOCAL_SYMBOL void map_clone_int_1(voidptr dest, voidptr pkey);
|
||
VV_LOCAL_SYMBOL void map_clone_int_2(voidptr dest, voidptr pkey);
|
||
VV_LOCAL_SYMBOL void map_clone_int_4(voidptr dest, voidptr pkey);
|
||
VV_LOCAL_SYMBOL void map_clone_int_8(voidptr dest, voidptr pkey);
|
||
VV_LOCAL_SYMBOL void map_free_string(voidptr pkey);
|
||
VV_LOCAL_SYMBOL void map_free_nop(voidptr _d1);
|
||
VV_LOCAL_SYMBOL map new_map(int key_bytes, int value_bytes, u64 (*hash_fn)(voidptr ), bool (*key_eq_fn)(voidptr , voidptr ), void (*clone_fn)(voidptr , voidptr ), void (*free_fn)(voidptr ));
|
||
VV_LOCAL_SYMBOL map new_map_init(u64 (*hash_fn)(voidptr ), bool (*key_eq_fn)(voidptr , voidptr ), void (*clone_fn)(voidptr , voidptr ), void (*free_fn)(voidptr ), int n, int key_bytes, int value_bytes, voidptr keys, voidptr values);
|
||
map map_move(map* m);
|
||
void map_clear(map* m);
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32 map_key_to_index(map* m, voidptr pkey);
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32 map_meta_less(map* m, u32 _index, u32 _metas);
|
||
VV_LOCAL_SYMBOL void map_meta_greater(map* m, u32 _index, u32 _metas, u32 kvi);
|
||
VV_LOCAL_SYMBOL void map_ensure_extra_metas(map* m, u32 probe_count);
|
||
VV_LOCAL_SYMBOL void map_set(map* m, voidptr key, voidptr value);
|
||
VV_LOCAL_SYMBOL void map_expand(map* m);
|
||
VV_LOCAL_SYMBOL void map_rehash(map* m);
|
||
VV_LOCAL_SYMBOL void map_cached_rehash(map* m, u32 old_cap);
|
||
VV_LOCAL_SYMBOL voidptr map_get_and_set(map* m, voidptr key, voidptr zero);
|
||
VV_LOCAL_SYMBOL voidptr map_get(map* m, voidptr key, voidptr zero);
|
||
VV_LOCAL_SYMBOL voidptr map_get_check(map* m, voidptr key);
|
||
VV_LOCAL_SYMBOL bool map_exists(map* m, voidptr key);
|
||
VV_LOCAL_SYMBOL void DenseArray_delete(DenseArray* d, int i);
|
||
void map_delete(map* m, voidptr key);
|
||
array map_keys(map* m);
|
||
array map_values(map* m);
|
||
VV_LOCAL_SYMBOL DenseArray DenseArray_clone(DenseArray* d);
|
||
map map_clone(map* m);
|
||
void map_free(map* m);
|
||
void IError_free(IError* ie);
|
||
string IError_str(IError err);
|
||
string Error_msg(Error err);
|
||
int Error_code(Error err);
|
||
string MessageError_msg(MessageError err);
|
||
int MessageError_code(MessageError err);
|
||
void MessageError_free(MessageError* err);
|
||
VV_LOCAL_SYMBOL string None___str(None__ _d1);
|
||
IError _v_error(string message);
|
||
IError error_with_code(string message, int code);
|
||
VV_LOCAL_SYMBOL void _option_ok(voidptr data, _option* option, int size);
|
||
VV_LOCAL_SYMBOL void opt_ok2(voidptr data, _option* option, int size);
|
||
VV_LOCAL_SYMBOL void _result_ok(voidptr data, _result* res, int size);
|
||
string none_str(none _d2);
|
||
VV_LOCAL_SYMBOL VMemoryBlock* vmemory_block_new(VMemoryBlock* prev, isize at_least);
|
||
VV_LOCAL_SYMBOL byte* vmemory_block_malloc(isize n);
|
||
VV_LOCAL_SYMBOL void prealloc_vinit(void);
|
||
VV_LOCAL_SYMBOL void prealloc_vcleanup(void);
|
||
VV_LOCAL_SYMBOL byte* prealloc_malloc(isize n);
|
||
VV_LOCAL_SYMBOL byte* prealloc_realloc(byte* old_data, isize old_size, isize new_size);
|
||
VV_LOCAL_SYMBOL byte* prealloc_calloc(isize n);
|
||
string rune_str(rune c);
|
||
string Array_rune_string(Array_rune ra);
|
||
string rune_repeat(rune c, int count);
|
||
Array_u8 rune_bytes(rune c);
|
||
int rune_length_in_bytes(rune c);
|
||
VV_LOCAL_SYMBOL SortedMap new_sorted_map(int n, int value_bytes);
|
||
VV_LOCAL_SYMBOL SortedMap new_sorted_map_init(int n, int value_bytes, string* keys, voidptr values);
|
||
VV_LOCAL_SYMBOL mapnode* new_node(void);
|
||
VV_LOCAL_SYMBOL void SortedMap_set(SortedMap* m, string key, voidptr value);
|
||
VV_LOCAL_SYMBOL void mapnode_split_child(mapnode* n, int child_index, mapnode* y);
|
||
VV_LOCAL_SYMBOL bool SortedMap_get(SortedMap m, string key, voidptr out);
|
||
VV_LOCAL_SYMBOL bool SortedMap_exists(SortedMap m, string key);
|
||
VV_LOCAL_SYMBOL int mapnode_find_key(mapnode* n, string k);
|
||
VV_LOCAL_SYMBOL bool mapnode_remove_key(mapnode* n, string k);
|
||
VV_LOCAL_SYMBOL void mapnode_remove_from_leaf(mapnode* n, int idx);
|
||
VV_LOCAL_SYMBOL void mapnode_remove_from_non_leaf(mapnode* n, int idx);
|
||
VV_LOCAL_SYMBOL void mapnode_fill(mapnode* n, int idx);
|
||
VV_LOCAL_SYMBOL void mapnode_borrow_from_prev(mapnode* n, int idx);
|
||
VV_LOCAL_SYMBOL void mapnode_borrow_from_next(mapnode* n, int idx);
|
||
VV_LOCAL_SYMBOL void mapnode_merge(mapnode* n, int idx);
|
||
void SortedMap_delete(SortedMap* m, string key);
|
||
VV_LOCAL_SYMBOL int mapnode_subkeys(mapnode* n, Array_string* keys, int at);
|
||
Array_string SortedMap_keys(SortedMap* m);
|
||
VV_LOCAL_SYMBOL void mapnode_free(mapnode* n);
|
||
void SortedMap_free(SortedMap* m);
|
||
void SortedMap_print(SortedMap m);
|
||
Array_rune string_runes(string s);
|
||
string cstring_to_vstring(char* s);
|
||
string tos_clone(u8* s);
|
||
string tos(u8* s, int len);
|
||
string tos2(u8* s);
|
||
string tos3(char* s);
|
||
string tos4(u8* s);
|
||
string tos5(char* s);
|
||
string u8_vstring(u8* bp);
|
||
string u8_vstring_with_len(u8* bp, int len);
|
||
string char_vstring(char* cp);
|
||
string char_vstring_with_len(char* cp, int len);
|
||
string u8_vstring_literal(u8* bp);
|
||
string u8_vstring_literal_with_len(u8* bp, int len);
|
||
string char_vstring_literal(char* cp);
|
||
string char_vstring_literal_with_len(char* cp, int len);
|
||
int string_len_utf8(string s);
|
||
VV_LOCAL_SYMBOL string string_clone_static(string a);
|
||
string string_clone(string a);
|
||
string string_replace_once(string s, string rep, string with);
|
||
string string_replace(string s, string rep, string with);
|
||
string string_replace_each(string s, Array_string vals);
|
||
VV_LOCAL_SYMBOL int compare_5406533740619829871_RepIndex_by_idx(RepIndex* a, RepIndex* b) {
|
||
if (a->idx < b->idx) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
bool string_bool(string s);
|
||
int string_int(string s);
|
||
i64 string_i64(string s);
|
||
i8 string_i8(string s);
|
||
i16 string_i16(string s);
|
||
f32 string_f32(string s);
|
||
f64 string_f64(string s);
|
||
u8 string_u8(string s);
|
||
u16 string_u16(string s);
|
||
u32 string_u32(string s);
|
||
u64 string_u64(string s);
|
||
_option_u64 string_parse_uint(string s, int _base, int _bit_size);
|
||
_option_i64 string_parse_int(string s, int _base, int _bit_size);
|
||
VV_LOCAL_SYMBOL bool string__eq(string s, string a);
|
||
int string_compare(string s, string a);
|
||
VV_LOCAL_SYMBOL bool string__lt(string s, string a);
|
||
VV_LOCAL_SYMBOL string string__plus(string s, string a);
|
||
Array_string string_split_any(string s, string delim);
|
||
Array_string string_split(string s, string delim);
|
||
Array_string string_split_nth(string s, string delim, int nth);
|
||
Array_string string_split_into_lines(string s);
|
||
VV_LOCAL_SYMBOL string string_substr2(string s, int start, int _end, bool end_max);
|
||
string string_substr(string s, int start, int end);
|
||
_option_string string_substr_with_check(string s, int start, int end);
|
||
string string_substr_ni(string s, int _start, int _end);
|
||
VV_LOCAL_SYMBOL int string_index_(string s, string p);
|
||
_option_int string_index(string s, string p);
|
||
VV_LOCAL_SYMBOL int string_index_kmp(string s, string p);
|
||
int string_index_any(string s, string chars);
|
||
VV_LOCAL_SYMBOL int string_last_index_(string s, string p);
|
||
_option_int string_last_index(string s, string p);
|
||
int string_index_after(string s, string p, int start);
|
||
int string_index_u8(string s, u8 c);
|
||
int string_last_index_u8(string s, u8 c);
|
||
int string_count(string s, string substr);
|
||
bool string_contains(string s, string substr);
|
||
bool string_contains_any(string s, string chars);
|
||
bool string_contains_only(string s, string chars);
|
||
bool string_contains_any_substr(string s, Array_string substrs);
|
||
bool string_starts_with(string s, string p);
|
||
bool string_ends_with(string s, string p);
|
||
string string_to_lower(string s);
|
||
bool string_is_lower(string s);
|
||
string string_to_upper(string s);
|
||
bool string_is_upper(string s);
|
||
string string_capitalize(string s);
|
||
bool string_is_capital(string s);
|
||
bool string_starts_with_capital(string s);
|
||
string string_title(string s);
|
||
bool string_is_title(string s);
|
||
string string_find_between(string s, string start, string end);
|
||
string string_trim_space(string s);
|
||
string string_trim(string s, string cutset);
|
||
string string_trim_left(string s, string cutset);
|
||
string string_trim_right(string s, string cutset);
|
||
string string_trim_string_left(string s, string str);
|
||
string string_trim_string_right(string s, string str);
|
||
string string_trim_prefix(string s, string str);
|
||
string string_trim_suffix(string s, string str);
|
||
int compare_strings(string* a, string* b);
|
||
VV_LOCAL_SYMBOL int compare_strings_by_len(string* a, string* b);
|
||
VV_LOCAL_SYMBOL int compare_lower_strings(string* a, string* b);
|
||
void Array_string_sort_ignore_case(Array_string* s);
|
||
void Array_string_sort_by_len(Array_string* s);
|
||
string string_str(string s);
|
||
VV_LOCAL_SYMBOL byte string_at(string s, int idx);
|
||
VV_LOCAL_SYMBOL _option_u8 string_at_with_check(string s, int idx);
|
||
bool u8_is_space(u8 c);
|
||
bool u8_is_digit(u8 c);
|
||
bool u8_is_hex_digit(u8 c);
|
||
bool u8_is_oct_digit(u8 c);
|
||
bool u8_is_bin_digit(u8 c);
|
||
bool u8_is_letter(u8 c);
|
||
bool u8_is_alnum(u8 c);
|
||
void string_free(string* s);
|
||
string string_before(string s, string sub);
|
||
string string_all_before(string s, string sub);
|
||
string string_all_before_last(string s, string sub);
|
||
string string_all_after(string s, string sub);
|
||
string string_all_after_last(string s, string sub);
|
||
string string_after(string s, string sub);
|
||
string string_after_char(string s, u8 sub);
|
||
string Array_string_join(Array_string a, string sep);
|
||
string Array_string_join_lines(Array_string s);
|
||
string string_reverse(string s);
|
||
string string_limit(string s, int max);
|
||
int string_hash(string s);
|
||
Array_u8 string_bytes(string s);
|
||
string string_repeat(string s, int count);
|
||
Array_string string_fields(string s);
|
||
string string_strip_margin(string s);
|
||
string string_strip_margin_custom(string s, u8 del);
|
||
bool string_match_glob(string name, string pattern);
|
||
bool string_is_ascii(string s);
|
||
Array_u8 byteptr_vbytes(byteptr data, int len);
|
||
string byteptr_vstring(byteptr bp);
|
||
string byteptr_vstring_with_len(byteptr bp, int len);
|
||
string charptr_vstring(charptr cp);
|
||
string charptr_vstring_with_len(charptr cp, int len);
|
||
string byteptr_vstring_literal(byteptr bp);
|
||
string byteptr_vstring_literal_with_len(byteptr bp, int len);
|
||
string charptr_vstring_literal(charptr cp);
|
||
string charptr_vstring_literal_with_len(charptr cp, int len);
|
||
string StrIntpType_str(StrIntpType x);
|
||
VV_LOCAL_SYMBOL f32 fabs32(f32 x);
|
||
VV_LOCAL_SYMBOL f64 fabs64(f64 x);
|
||
VV_LOCAL_SYMBOL u64 abs64(i64 x);
|
||
u64 get_str_intp_u64_format(StrIntpType fmt_type, int in_width, int in_precision, bool in_tail_zeros, bool in_sign, byte in_pad_ch, int in_base, bool in_upper_case);
|
||
u32 get_str_intp_u32_format(StrIntpType fmt_type, int in_width, int in_precision, bool in_tail_zeros, bool in_sign, byte in_pad_ch, int in_base, bool in_upper_case);
|
||
VV_LOCAL_SYMBOL void StrIntpData_process_str_intp_data(StrIntpData* data, strings__Builder* sb);
|
||
string str_intp(int data_len, voidptr in_data);
|
||
string str_intp_sq(string in_str);
|
||
string str_intp_rune(string in_str);
|
||
string str_intp_g32(string in_str);
|
||
string str_intp_g64(string in_str);
|
||
string str_intp_sub(string base_str, string in_str);
|
||
u16* string_to_wide(string _str);
|
||
string string_from_wide(u16* _wstr);
|
||
string string_from_wide2(u16* _wstr, int len);
|
||
int utf8_getchar(void);
|
||
int utf8_char_len(u8 b);
|
||
string utf32_to_str(u32 code);
|
||
string utf32_to_str_no_malloc(u32 code, u8* buf);
|
||
int utf32_decode_to_buffer(u32 code, u8* buf);
|
||
int utf8_str_len(string s);
|
||
int string_utf32_code(string _rune);
|
||
_option_rune Array_u8_utf8_to_utf32(Array_u8 _bytes);
|
||
VV_LOCAL_SYMBOL int utf8_len(u8 c);
|
||
int utf8_str_visible_length(string s);
|
||
bool ArrayFlags_is_empty(ArrayFlags* e);
|
||
bool ArrayFlags_has(ArrayFlags* e, ArrayFlags flag);
|
||
bool ArrayFlags_all(ArrayFlags* e, ArrayFlags flag);
|
||
void ArrayFlags_set(ArrayFlags* e, ArrayFlags flag);
|
||
void ArrayFlags_clear(ArrayFlags* e, ArrayFlags flag);
|
||
void ArrayFlags_toggle(ArrayFlags* e, ArrayFlags flag);
|
||
strings__textscanner__TextScanner strings__textscanner__new(string input);
|
||
void strings__textscanner__TextScanner_free(strings__textscanner__TextScanner* ss);
|
||
int strings__textscanner__TextScanner_remaining(strings__textscanner__TextScanner* ss);
|
||
int strings__textscanner__TextScanner_next(strings__textscanner__TextScanner* ss);
|
||
void strings__textscanner__TextScanner_skip(strings__textscanner__TextScanner* ss);
|
||
void strings__textscanner__TextScanner_skip_n(strings__textscanner__TextScanner* ss, int n);
|
||
int strings__textscanner__TextScanner_peek(strings__textscanner__TextScanner* ss);
|
||
int strings__textscanner__TextScanner_peek_n(strings__textscanner__TextScanner* ss, int n);
|
||
void strings__textscanner__TextScanner_back(strings__textscanner__TextScanner* ss);
|
||
void strings__textscanner__TextScanner_back_n(strings__textscanner__TextScanner* ss, int n);
|
||
int strings__textscanner__TextScanner_peek_back(strings__textscanner__TextScanner* ss);
|
||
int strings__textscanner__TextScanner_peek_back_n(strings__textscanner__TextScanner* ss, int n);
|
||
int strings__textscanner__TextScanner_current(strings__textscanner__TextScanner* ss);
|
||
void strings__textscanner__TextScanner_reset(strings__textscanner__TextScanner* ss);
|
||
void strings__textscanner__TextScanner_goto_end(strings__textscanner__TextScanner* ss);
|
||
Array_string os__cmdline__options(Array_string args, string param);
|
||
string os__cmdline__option(Array_string args, string param, string def);
|
||
Array_string os__cmdline__options_before(Array_string args, Array_string what);
|
||
Array_string os__cmdline__options_after(Array_string args, Array_string what);
|
||
Array_string os__cmdline__only_non_options(Array_string args);
|
||
Array_string os__cmdline__only_options(Array_string args);
|
||
v__token__KeywordsMatcher v__token__new_keywords_matcher_T_v__token__Kind(Map_string_v__token__Kind kw_map);
|
||
VV_LOCAL_SYMBOL int compare_11195941112940057302_v__token__WIndex_by_word(v__token__WIndex* a, v__token__WIndex* b) {
|
||
if (string__lt(a->word, b->word)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
v__token__KeywordsMatcher v__token__new_keywords_matcher_T_int(Map_string_int kw_map);
|
||
VV_LOCAL_SYMBOL void v__token__KeywordsMatcher_add_word(v__token__KeywordsMatcher* km, string word, int kind);
|
||
int v__token__KeywordsMatcher_find(v__token__KeywordsMatcher* km, string word);
|
||
void v__token__Pos_free(v__token__Pos* p);
|
||
string v__token__Pos_line_str(v__token__Pos p);
|
||
v__token__Pos v__token__Pos_extend(v__token__Pos pos, v__token__Pos end);
|
||
v__token__Pos v__token__Pos_extend_with_last_line(v__token__Pos pos, v__token__Pos end, int last_line);
|
||
void v__token__Pos_update_last_line(v__token__Pos* pos, int last_line);
|
||
v__token__Pos v__token__Token_pos(v__token__Token* tok);
|
||
VV_LOCAL_SYMBOL Map_string_v__token__Kind v__token__build_keys(void);
|
||
VV_LOCAL_SYMBOL Array_string v__token__build_token_str(void);
|
||
bool v__token__is_key(string key);
|
||
bool v__token__is_decl(v__token__Kind t);
|
||
bool v__token__Kind_is_assign(v__token__Kind t);
|
||
string v__token__Kind_str(v__token__Kind t);
|
||
string v__token__Token_str(v__token__Token t);
|
||
string v__token__Token_debug(v__token__Token t);
|
||
Array_v__token__Precedence v__token__build_precedences(void);
|
||
int v__token__Token_precedence(v__token__Token tok);
|
||
bool v__token__Token_is_scalar(v__token__Token tok);
|
||
bool v__token__Token_is_unary(v__token__Token tok);
|
||
bool v__token__Kind_is_relational(v__token__Kind tok);
|
||
bool v__token__Kind_is_start_of_type(v__token__Kind k);
|
||
bool v__token__Kind_is_prefix(v__token__Kind kind);
|
||
bool v__token__Kind_is_infix(v__token__Kind kind);
|
||
bool v__token__Kind_is_postfix(v__token__Kind kind);
|
||
string v__token__kind_to_string(v__token__Kind k);
|
||
_option_v__token__Kind v__token__kind_from_string(string s);
|
||
int v__mathutil__min_T_int(int a, int b);
|
||
int v__mathutil__max_T_int(int a, int b);
|
||
i64 time__portable_timegm(struct tm* t);
|
||
int time__days_from_civil(int oy, int m, int d);
|
||
string time__Time_format(time__Time t);
|
||
string time__Time_format_ss(time__Time t);
|
||
string time__Time_format_ss_milli(time__Time t);
|
||
string time__Time_format_ss_micro(time__Time t);
|
||
string time__Time_hhmm(time__Time t);
|
||
string time__Time_hhmmss(time__Time t);
|
||
string time__Time_hhmm12(time__Time t);
|
||
string time__Time_ymmdd(time__Time t);
|
||
string time__Time_ddmmy(time__Time t);
|
||
string time__Time_md(time__Time t);
|
||
VV_LOCAL_SYMBOL string time__ordinal_suffix(int n);
|
||
string time__Time_custom_format(time__Time t, string s);
|
||
string time__Time_clean(time__Time t);
|
||
string time__Time_clean12(time__Time t);
|
||
string time__Time_get_fmt_time_str(time__Time t, time__FormatTime fmt_time);
|
||
string time__Time_get_fmt_date_str(time__Time t, time__FormatDelimiter fmt_dlmtr, time__FormatDate fmt_date);
|
||
string time__Time_get_fmt_str(time__Time t, time__FormatDelimiter fmt_dlmtr, time__FormatTime fmt_time, time__FormatDate fmt_date);
|
||
string time__Time_utc_string(time__Time t);
|
||
VV_LOCAL_SYMBOL f64 time__mceil(f64 x);
|
||
bool time__Time__eq(time__Time t1, time__Time t2);
|
||
bool time__Time__lt(time__Time t1, time__Time t2);
|
||
time__Duration time__Time__minus(time__Time lhs, time__Time rhs);
|
||
_option_time__Time time__parse_rfc3339(string s);
|
||
_option_time__Time time__parse(string s);
|
||
_option_time__Time time__parse_iso8601(string s);
|
||
_option_time__Time time__parse_rfc2822(string s);
|
||
VV_LOCAL_SYMBOL _option_multi_return_int_int_int time__parse_iso8601_date(string s);
|
||
VV_LOCAL_SYMBOL _option_multi_return_int_int_int_int_i64_bool time__parse_iso8601_time(string s);
|
||
string time__TimeParseError_msg(time__TimeParseError err);
|
||
VV_LOCAL_SYMBOL IError time__error_invalid_time(int code);
|
||
time__StopWatch time__new_stopwatch(time__StopWatchOptions opts);
|
||
void time__StopWatch_start(time__StopWatch* t);
|
||
void time__StopWatch_restart(time__StopWatch* t);
|
||
void time__StopWatch_stop(time__StopWatch* t);
|
||
void time__StopWatch_pause(time__StopWatch* t);
|
||
time__Duration time__StopWatch_elapsed(time__StopWatch t);
|
||
time__Time time__now(void);
|
||
time__Time time__utc(void);
|
||
time__Time time__new_time(time__Time t);
|
||
i64 time__ticks(void);
|
||
string time__Time_str(time__Time t);
|
||
VV_LOCAL_SYMBOL time__Time time__convert_ctime(struct tm t, int microsecond);
|
||
string time__Time_strftime(time__Time t, string fmt);
|
||
string time__Time_smonth(time__Time* t);
|
||
i64 time__Time_unix_time(time__Time* t);
|
||
i64 time__Time_unix_time_milli(time__Time* t);
|
||
time__Time time__Time_add(time__Time* t, time__Duration d);
|
||
time__Time time__Time_add_seconds(time__Time* t, int seconds);
|
||
time__Time time__Time_add_days(time__Time* t, int days);
|
||
time__Duration time__since(time__Time t);
|
||
string time__Time_relative(time__Time* t);
|
||
string time__Time_relative_short(time__Time* t);
|
||
int time__day_of_week(int y, int m, int d);
|
||
int time__Time_day_of_week(time__Time* t);
|
||
string time__Time_weekday_str(time__Time* t);
|
||
string time__Time_long_weekday_str(time__Time* t);
|
||
bool time__is_leap_year(int year);
|
||
_option_int time__days_in_month(int month, int year);
|
||
string time__Time_debug(time__Time* t);
|
||
i64 time__Duration_nanoseconds(time__Duration d);
|
||
i64 time__Duration_microseconds(time__Duration d);
|
||
i64 time__Duration_milliseconds(time__Duration d);
|
||
f64 time__Duration_seconds(time__Duration d);
|
||
f64 time__Duration_minutes(time__Duration d);
|
||
f64 time__Duration_hours(time__Duration d);
|
||
string time__Duration_str(time__Duration d);
|
||
int time__offset(void);
|
||
VV_LOCAL_SYMBOL u64 time__sys_mono_now_darwin(void);
|
||
time__Time time__darwin_now(void);
|
||
time__Time time__solaris_now(void);
|
||
time__Time time__darwin_utc(void);
|
||
time__Time time__solaris_utc(void);
|
||
VV_LOCAL_SYMBOL i64 time__make_unix_time(struct tm t);
|
||
time__Time time__Time_local(time__Time* t);
|
||
u64 time__sys_mono_now(void);
|
||
VV_LOCAL_SYMBOL u64 time__vpc_now(void);
|
||
VV_LOCAL_SYMBOL time__Time time__linux_now(void);
|
||
VV_LOCAL_SYMBOL time__Time time__linux_utc(void);
|
||
time__Time time__win_now(void);
|
||
time__Time time__win_utc(void);
|
||
struct timespec time__Duration_timespec(time__Duration d);
|
||
struct timespec time__zero_timespec(void);
|
||
void time__sleep(time__Duration duration);
|
||
int time__Duration_sys_milliseconds(time__Duration d);
|
||
time__Time time__unix(i64 abs);
|
||
time__Time time__unix2(i64 abs, int microsecond);
|
||
VV_LOCAL_SYMBOL multi_return_int_int_int time__calculate_date_from_offset(i64 day_offset_);
|
||
VV_LOCAL_SYMBOL multi_return_int_int_int time__calculate_time_from_offset(i64 second_offset_);
|
||
void v__dotgraph__start_digraph(void);
|
||
VV_LOCAL_SYMBOL void anon_fn_6b7dbc3eb6b094a7__82(void);
|
||
v__dotgraph__DotGraph* v__dotgraph__new(string name, string label, string color);
|
||
void v__dotgraph__DotGraph_writeln(v__dotgraph__DotGraph* d, string line);
|
||
void v__dotgraph__DotGraph_finish(v__dotgraph__DotGraph* d);
|
||
void v__dotgraph__DotGraph_new_node(v__dotgraph__DotGraph* d, string nlabel, v__dotgraph__NewNodeConfig cfg);
|
||
void v__dotgraph__DotGraph_new_edge(v__dotgraph__DotGraph* d, string source, string target, v__dotgraph__NewEdgeConfig cfg);
|
||
string v__dotgraph__node_name(string name, voidptr context);
|
||
u64 hash__wyhash_c(u8* key, u64 len, u64 seed);
|
||
u64 hash__wyhash64_c(u64 a, u64 b);
|
||
u64 hash__sum64_string(string key, u64 seed);
|
||
u64 hash__sum64(Array_u8 key, u64 seed);
|
||
VV_LOCAL_SYMBOL u64 hash__wyrotr(u64 v, u32 k);
|
||
u64 hash__wymum(u64 a, u64 b);
|
||
VV_LOCAL_SYMBOL u64 hash__wyr3(u8* p, u64 k);
|
||
VV_LOCAL_SYMBOL u64 hash__wyr4(u8* p);
|
||
VV_LOCAL_SYMBOL u64 hash__wyr8(u8* p);
|
||
u32 hash__fnv1a__sum32_string(string data);
|
||
u32 hash__fnv1a__sum32(Array_u8 data);
|
||
u32 hash__fnv1a__sum32_bytes(u8* data, int data_len);
|
||
u64 hash__fnv1a__sum64_string(string data);
|
||
u64 hash__fnv1a__sum64(Array_u8 data);
|
||
u64 hash__fnv1a__sum64_bytes(u8* data, int data_len);
|
||
VV_LOCAL_SYMBOL string flag__UnkownFlagError_msg(flag__UnkownFlagError err);
|
||
VV_LOCAL_SYMBOL string flag__ArgsCountError_msg(flag__ArgsCountError err);
|
||
VV_LOCAL_SYMBOL void flag__Flag_free(flag__Flag* f);
|
||
string flag__Flag_str(flag__Flag f);
|
||
string Array_flag__Flag_str(Array_flag__Flag af);
|
||
VV_LOCAL_SYMBOL void flag__FlagParser_free(flag__FlagParser* f);
|
||
flag__FlagParser* flag__new_flag_parser(Array_string args);
|
||
void flag__FlagParser_usage_example(flag__FlagParser* fs, string example);
|
||
void flag__FlagParser_footer(flag__FlagParser* fs, string footer);
|
||
void flag__FlagParser_application(flag__FlagParser* fs, string name);
|
||
void flag__FlagParser_version(flag__FlagParser* fs, string vers);
|
||
void flag__FlagParser_description(flag__FlagParser* fs, string desc);
|
||
void flag__FlagParser_skip_executable(flag__FlagParser* fs);
|
||
void flag__FlagParser_allow_unknown_args(flag__FlagParser* fs);
|
||
VV_LOCAL_SYMBOL void flag__FlagParser_add_flag(flag__FlagParser* fs, string name, u8 abbr, string usage, string desc);
|
||
VV_LOCAL_SYMBOL Array_string flag__FlagParser_parse_value(flag__FlagParser* fs, string longhand, u8 shorthand);
|
||
VV_LOCAL_SYMBOL _option_string flag__FlagParser_parse_bool_value(flag__FlagParser* fs, string longhand, u8 shorthand);
|
||
_option_bool flag__FlagParser_bool_opt(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
bool flag__FlagParser_bool(flag__FlagParser* fs, string name, u8 abbr, bool bdefault, string usage);
|
||
Array_int flag__FlagParser_int_multi(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
_option_int flag__FlagParser_int_opt(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
int flag__FlagParser_int(flag__FlagParser* fs, string name, u8 abbr, int idefault, string usage);
|
||
Array_f64 flag__FlagParser_float_multi(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
_option_f64 flag__FlagParser_float_opt(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
f64 flag__FlagParser_float(flag__FlagParser* fs, string name, u8 abbr, f64 fdefault, string usage);
|
||
Array_string flag__FlagParser_string_multi(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
_option_string flag__FlagParser_string_opt(flag__FlagParser* fs, string name, u8 abbr, string usage);
|
||
string flag__FlagParser_string(flag__FlagParser* fs, string name, u8 abbr, string sdefault, string usage);
|
||
_option_void flag__FlagParser_limit_free_args_to_at_least(flag__FlagParser* fs, int n);
|
||
_option_void flag__FlagParser_limit_free_args_to_exactly(flag__FlagParser* fs, int n);
|
||
_option_void flag__FlagParser_limit_free_args(flag__FlagParser* fs, int min, int max);
|
||
void flag__FlagParser_arguments_description(flag__FlagParser* fs, string description);
|
||
string flag__FlagParser_usage(flag__FlagParser* fs);
|
||
VV_LOCAL_SYMBOL _option_flag__Flag flag__FlagParser_find_existing_flag(flag__FlagParser* fs, string fname);
|
||
VV_LOCAL_SYMBOL void flag__FlagParser_handle_builtin_options(flag__FlagParser* fs);
|
||
_option_Array_string flag__FlagParser_finalize(flag__FlagParser* fs);
|
||
Array_string flag__FlagParser_remaining_parameters(flag__FlagParser* fs);
|
||
VV_LOCAL_SYMBOL bool semver__version_satisfies(semver__Version ver, string input);
|
||
VV_LOCAL_SYMBOL bool semver__compare_eq(semver__Version v1, semver__Version v2);
|
||
VV_LOCAL_SYMBOL bool semver__compare_gt(semver__Version v1, semver__Version v2);
|
||
VV_LOCAL_SYMBOL bool semver__compare_lt(semver__Version v1, semver__Version v2);
|
||
VV_LOCAL_SYMBOL bool semver__compare_ge(semver__Version v1, semver__Version v2);
|
||
VV_LOCAL_SYMBOL bool semver__compare_le(semver__Version v1, semver__Version v2);
|
||
VV_LOCAL_SYMBOL semver__RawVersion semver__parse(string input);
|
||
VV_LOCAL_SYMBOL bool semver__RawVersion_is_valid(semver__RawVersion ver);
|
||
VV_LOCAL_SYMBOL bool semver__RawVersion_is_missing(semver__RawVersion ver, int typ);
|
||
VV_LOCAL_SYMBOL _option_semver__Version semver__RawVersion_coerce(semver__RawVersion raw_ver);
|
||
VV_LOCAL_SYMBOL semver__RawVersion semver__RawVersion_complete(semver__RawVersion raw_ver);
|
||
VV_LOCAL_SYMBOL _option_semver__Version semver__RawVersion_validate(semver__RawVersion raw_ver);
|
||
VV_LOCAL_SYMBOL semver__Version semver__RawVersion_to_version(semver__RawVersion raw_ver);
|
||
VV_LOCAL_SYMBOL bool semver__Range_satisfies(semver__Range r, semver__Version ver);
|
||
VV_LOCAL_SYMBOL bool semver__ComparatorSet_satisfies(semver__ComparatorSet set, semver__Version ver);
|
||
VV_LOCAL_SYMBOL bool semver__Comparator_satisfies(semver__Comparator c, semver__Version ver);
|
||
VV_LOCAL_SYMBOL _option_semver__Range semver__parse_range(string input);
|
||
VV_LOCAL_SYMBOL _option_semver__ComparatorSet semver__parse_comparator_set(string input);
|
||
VV_LOCAL_SYMBOL _option_semver__Comparator semver__parse_comparator(string input);
|
||
VV_LOCAL_SYMBOL _option_semver__Version semver__parse_xrange(string input);
|
||
VV_LOCAL_SYMBOL bool semver__can_expand(string input);
|
||
VV_LOCAL_SYMBOL _option_semver__ComparatorSet semver__expand_comparator_set(string input);
|
||
VV_LOCAL_SYMBOL _option_semver__ComparatorSet semver__expand_tilda(string raw_version);
|
||
VV_LOCAL_SYMBOL _option_semver__ComparatorSet semver__expand_caret(string raw_version);
|
||
VV_LOCAL_SYMBOL _option_semver__ComparatorSet semver__expand_hyphen(string raw_range);
|
||
VV_LOCAL_SYMBOL _option_semver__ComparatorSet semver__expand_xrange(string raw_range);
|
||
VV_LOCAL_SYMBOL semver__ComparatorSet semver__make_comparator_set_ge_lt(semver__Version min, semver__Version max);
|
||
VV_LOCAL_SYMBOL semver__ComparatorSet semver__make_comparator_set_ge_le(semver__Version min, semver__Version max);
|
||
string semver__EmptyInputError_msg(semver__EmptyInputError err);
|
||
string semver__InvalidVersionFormatError_msg(semver__InvalidVersionFormatError err);
|
||
_option_semver__Version semver__from(string input);
|
||
semver__Version semver__build(int major, int minor, int patch);
|
||
semver__Version semver__Version_increment(semver__Version ver, semver__Increment typ);
|
||
bool semver__Version_satisfies(semver__Version ver, string input);
|
||
bool semver__Version_eq(semver__Version v1, semver__Version v2);
|
||
bool semver__Version_gt(semver__Version v1, semver__Version v2);
|
||
bool semver__Version_lt(semver__Version v1, semver__Version v2);
|
||
bool semver__Version_ge(semver__Version v1, semver__Version v2);
|
||
bool semver__Version_le(semver__Version v1, semver__Version v2);
|
||
string semver__Version_str(semver__Version ver);
|
||
_option_semver__Version semver__coerce(string input);
|
||
bool semver__is_valid(string input);
|
||
VV_LOCAL_SYMBOL bool semver__is_version_valid(string input);
|
||
VV_LOCAL_SYMBOL _option_semver__Version semver__coerce_version(string input);
|
||
VV_LOCAL_SYMBOL semver__Version semver__increment_version(semver__Version ver, semver__Increment typ);
|
||
VV_LOCAL_SYMBOL bool semver__is_valid_string(string input);
|
||
VV_LOCAL_SYMBOL bool semver__is_valid_number(string input);
|
||
bool sync__stdatomic__add_u64(u64* ptr, int delta);
|
||
bool sync__stdatomic__sub_u64(u64* ptr, int delta);
|
||
bool sync__stdatomic__add_i64(i64* ptr, int delta);
|
||
bool sync__stdatomic__sub_i64(i64* ptr, int delta);
|
||
void sync__stdatomic__store_u64(u64* ptr, u64 val);
|
||
u64 sync__stdatomic__load_u64(u64* ptr);
|
||
void sync__stdatomic__store_i64(i64* ptr, i64 val);
|
||
i64 sync__stdatomic__load_i64(i64* ptr);
|
||
Array_string os__args_after(string cut_word);
|
||
Array_string os__args_before(string cut_word);
|
||
string os__getenv(string key);
|
||
_option_string os__getenv_opt(string key);
|
||
int os__setenv(string name, string value, bool overwrite);
|
||
int os__unsetenv(string name);
|
||
VV_LOCAL_SYMBOL char** os__unix_environ(void);
|
||
Map_string_string os__environ(void);
|
||
int os__fd_close(int fd);
|
||
void os__fd_write(int fd, string s);
|
||
Array_string os__fd_slurp(int fd);
|
||
multi_return_string_int os__fd_read(int fd, int maxbytes);
|
||
_option_os__File os__open_file(string path, string mode, Array_int options);
|
||
_option_os__File os__open(string path);
|
||
_option_os__File os__create(string path);
|
||
os__File os__stdin(void);
|
||
os__File os__stdout(void);
|
||
os__File os__stderr(void);
|
||
_option_int os__File_read(os__File* f, Array_u8* buf);
|
||
_option_int os__File_write(os__File* f, Array_u8 buf);
|
||
_option_int os__File_writeln(os__File* f, string s);
|
||
_option_int os__File_write_string(os__File* f, string s);
|
||
_option_int os__File_write_to(os__File* f, u64 pos, Array_u8 buf);
|
||
int os__File_write_ptr(os__File* f, voidptr data, int size);
|
||
_option_void os__File_write_full_buffer(os__File* f, voidptr buffer, usize buffer_len);
|
||
int os__File_write_ptr_at(os__File* f, voidptr data, int size, u64 pos);
|
||
VV_LOCAL_SYMBOL _option_int os__fread(voidptr ptr, int item_size, int items, FILE* stream);
|
||
Array_u8 os__File_read_bytes(os__File* f, int size);
|
||
Array_u8 os__File_read_bytes_at(os__File* f, int size, u64 pos);
|
||
_option_int os__File_read_bytes_into_newline(os__File* f, Array_u8* buf);
|
||
_option_int os__File_read_bytes_into(os__File* f, u64 pos, Array_u8* buf);
|
||
_option_int os__File_read_from(os__File* f, u64 pos, Array_u8* buf);
|
||
_option_int os__File_read_into_ptr(os__File* f, u8* ptr, int max_size);
|
||
void os__File_flush(os__File* f);
|
||
string os__FileNotOpenedError_msg(os__FileNotOpenedError err);
|
||
string os__SizeOfTypeIs0Error_msg(os__SizeOfTypeIs0Error err);
|
||
VV_LOCAL_SYMBOL IError os__error_file_not_opened(void);
|
||
VV_LOCAL_SYMBOL IError os__error_size_of_type_0(void);
|
||
_option_void os__File_seek(os__File* f, i64 pos, os__SeekMode mode);
|
||
_option_i64 os__File_tell(os__File* f);
|
||
bool os__is_abs_path(string path);
|
||
string os__abs_path(string path);
|
||
string os__norm_path(string path);
|
||
_option_string os__existing_path(string path);
|
||
VV_LOCAL_SYMBOL string os__clean_path(string path);
|
||
VV_LOCAL_SYMBOL int os__win_volume_len(string path);
|
||
VV_LOCAL_SYMBOL bool os__is_slash(u8 b);
|
||
VV_LOCAL_SYMBOL bool os__is_unc_path(string path);
|
||
VV_LOCAL_SYMBOL bool os__has_drive_letter(string path);
|
||
VV_LOCAL_SYMBOL bool os__starts_w_slash_slash(string path);
|
||
VV_LOCAL_SYMBOL bool os__is_drive_rooted(string path);
|
||
VV_LOCAL_SYMBOL bool os__is_normal_path(string path);
|
||
VV_LOCAL_SYMBOL bool os__is_curr_dir_ref(int byte_one, int byte_two, int byte_three);
|
||
u32 os__FilePermission_bitmask(os__FilePermission p);
|
||
u32 os__FileMode_bitmask(os__FileMode m);
|
||
os__FileMode os__inode(string path);
|
||
_option_Array_u8 os__read_bytes(string path);
|
||
_option_string os__read_file(string path);
|
||
_option_void os__truncate(string path, u64 len);
|
||
VV_LOCAL_SYMBOL void os__eprintln_unknown_file_size(void);
|
||
u64 os__file_size(string path);
|
||
_option_void os__mv(string src, string dst);
|
||
_option_void os__cp(string src, string dst);
|
||
_option_FILE_ptr os__vfopen(string path, string mode);
|
||
int os__fileno(voidptr cfile);
|
||
VV_LOCAL_SYMBOL voidptr os__vpopen(string path);
|
||
VV_LOCAL_SYMBOL multi_return_int_bool os__posix_wait4_to_exit_status(int waitret);
|
||
string os__posix_get_error_msg(int code);
|
||
VV_LOCAL_SYMBOL int os__vpclose(voidptr f);
|
||
int os__system(string cmd);
|
||
bool os__exists(string path);
|
||
bool os__is_executable(string path);
|
||
bool os__is_writable(string path);
|
||
bool os__is_readable(string path);
|
||
_option_void os__rm(string path);
|
||
_option_void os__rmdir(string path);
|
||
VV_LOCAL_SYMBOL void os__print_c_errno(void);
|
||
string os__get_raw_line(void);
|
||
Array_u8 os__get_raw_stdin(void);
|
||
string os__executable(void);
|
||
bool os__is_dir(string path);
|
||
bool os__is_link(string path);
|
||
_option_void os__chdir(string path);
|
||
VV_LOCAL_SYMBOL int os__max_path_bufffer_size(void);
|
||
string os__getwd(void);
|
||
string os__real_path(string fpath);
|
||
VV_LOCAL_SYMBOL void os__normalize_drive_letter(string path);
|
||
int os__fork(void);
|
||
int os__wait(void);
|
||
i64 os__file_last_mod_unix(string path);
|
||
void os__flush(void);
|
||
_option_void os__chmod(string path, int mode);
|
||
_option_void os__chown(string path, int owner, int group);
|
||
_option_os__File os__open_append(string path);
|
||
_option_void os__execvp(string cmdpath, Array_string cmdargs);
|
||
_option_void os__execve(string cmdpath, Array_string cmdargs, Array_string envs);
|
||
int os__is_atty(int fd);
|
||
_option_void os__write_file_array(string path, array buffer);
|
||
_option_Array_string os__glob(Array_string patterns);
|
||
VV_LOCAL_SYMBOL int compare_5811885252942183168_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
IError os__last_error(void);
|
||
void os__Result_free(os__Result* result);
|
||
_option_void os__cp_all(string src, string dst, bool overwrite);
|
||
_option_void os__mv_by_cp(string source, string target);
|
||
_option_Array_string os__read_lines(string path);
|
||
string os__sigint_to_signal_name(int si);
|
||
_option_void os__rmdir_all(string path);
|
||
bool os__is_dir_empty(string path);
|
||
string os__file_ext(string path);
|
||
string os__dir(string opath);
|
||
string os__base(string opath);
|
||
string os__file_name(string opath);
|
||
_option_string os__input_opt(string prompt);
|
||
string os__input(string prompt);
|
||
string os__get_line(void);
|
||
Array_string os__get_lines(void);
|
||
string os__get_lines_joined(void);
|
||
string os__get_raw_lines_joined(void);
|
||
string os__user_os(void);
|
||
_option_Array_string os__user_names(void);
|
||
string os__home_dir(void);
|
||
string os__expand_tilde_to_home(string path);
|
||
_option_void os__write_file(string path, string text);
|
||
VV_LOCAL_SYMBOL string os__executable_fallback(void);
|
||
string os__ExecutableNotFoundError_msg(os__ExecutableNotFoundError err);
|
||
VV_LOCAL_SYMBOL IError os__error_failed_to_find_executable(void);
|
||
_option_string os__find_abs_path_of_executable(string exepath);
|
||
bool os__exists_in_system_path(string prog);
|
||
bool os__is_file(string path);
|
||
string os__join_path(string base, Array_string dirs);
|
||
string os__join_path_single(string base, string elem);
|
||
Array_string os__walk_ext(string path, string ext);
|
||
VV_LOCAL_SYMBOL void os__impl_walk_ext(string path, string ext, Array_string* out);
|
||
void os__walk(string path, void (*f)(string ));
|
||
void os__walk_with_context(string path, voidptr context, void (*fcb)(voidptr , string ));
|
||
void os__log(string s);
|
||
_option_void os__mkdir_all(string opath);
|
||
string os__cache_dir(void);
|
||
string os__temp_dir(void);
|
||
VV_LOCAL_SYMBOL string os__default_vmodules_path(void);
|
||
string os__vmodules_dir(void);
|
||
Array_string os__vmodules_paths(void);
|
||
string os__resource_abs_path(string path);
|
||
os__Result os__execute_or_panic(string cmd);
|
||
os__Result os__execute_or_exit(string cmd);
|
||
string os__quoted_path(string path);
|
||
_option_string os__config_dir(void);
|
||
VV_LOCAL_SYMBOL Array_string os__glob_match(string dir, string pattern, string next_pattern, Array_string* matches);
|
||
VV_LOCAL_SYMBOL _option_void os__native_glob_pattern(string pattern, Array_string* matches);
|
||
_option_void os__utime(string path, int actime, int modtime);
|
||
os__Uname os__uname(void);
|
||
string os__hostname(void);
|
||
string os__loginname(void);
|
||
VV_LOCAL_SYMBOL Array_string os__init_os_args(int argc, u8** argv);
|
||
_option_Array_string os__ls(string path);
|
||
_option_bool os__mkdir(string path);
|
||
os__Result os__execute(string cmd);
|
||
os__Result os__raw_execute(string cmd);
|
||
_option_void os__Command_start(os__Command* c);
|
||
string os__Command_read_line(os__Command* c);
|
||
_option_void os__Command_close(os__Command* c);
|
||
_option_bool os__symlink(string origin, string target);
|
||
_option_bool os__link(string origin, string target);
|
||
string os__get_error_msg(int code);
|
||
void os__File_close(os__File* f);
|
||
bool os__debugger_present(void);
|
||
_option_bool os__is_writable_folder(string folder);
|
||
int os__getpid(void);
|
||
int os__getppid(void);
|
||
int os__getuid(void);
|
||
int os__geteuid(void);
|
||
int os__getgid(void);
|
||
int os__getegid(void);
|
||
void os__posix_set_permission_bit(string path_s, u32 mode, bool enable);
|
||
void os__Process_signal_kill(os__Process* p);
|
||
void os__Process_signal_pgkill(os__Process* p);
|
||
void os__Process_signal_stop(os__Process* p);
|
||
void os__Process_signal_continue(os__Process* p);
|
||
void os__Process_wait(os__Process* p);
|
||
void os__Process_close(os__Process* p);
|
||
void os__Process_free(os__Process* p);
|
||
VV_LOCAL_SYMBOL int os__Process__spawn(os__Process* p);
|
||
bool os__Process_is_alive(os__Process* p);
|
||
void os__Process_set_redirect_stdio(os__Process* p);
|
||
void os__Process_stdin_write(os__Process* p, string s);
|
||
string os__Process_stdout_slurp(os__Process* p);
|
||
string os__Process_stderr_slurp(os__Process* p);
|
||
string os__Process_stdout_read(os__Process* p);
|
||
string os__Process_stderr_read(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process__check_redirection_call(os__Process* p, string fn_name);
|
||
VV_LOCAL_SYMBOL void os__Process__signal_stop(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process__signal_continue(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process__signal_kill(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process__signal_pgkill(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process__wait(os__Process* p);
|
||
VV_LOCAL_SYMBOL bool os__Process__is_alive(os__Process* p);
|
||
void os__Process_run(os__Process* p);
|
||
os__Process* os__new_process(string filename);
|
||
void os__Process_set_args(os__Process* p, Array_string pargs);
|
||
void os__Process_set_environment(os__Process* p, Map_string_string envs);
|
||
VV_LOCAL_SYMBOL int os__Process_unix_spawn_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_unix_stop_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_unix_resume_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_unix_kill_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_unix_kill_pgroup(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_unix_wait(os__Process* p);
|
||
VV_LOCAL_SYMBOL bool os__Process_unix_is_alive(os__Process* p);
|
||
VV_LOCAL_SYMBOL int os__Process_win_spawn_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_win_stop_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_win_resume_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_win_kill_process(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_win_kill_pgroup(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_win_wait(os__Process* p);
|
||
VV_LOCAL_SYMBOL bool os__Process_win_is_alive(os__Process* p);
|
||
VV_LOCAL_SYMBOL void os__Process_win_write_string(os__Process* p, int idx, string s);
|
||
VV_LOCAL_SYMBOL multi_return_string_int os__Process_win_read_string(os__Process* p, int idx, int maxbytes);
|
||
VV_LOCAL_SYMBOL string os__Process_win_slurp(os__Process* p, int idx);
|
||
_option_os__SignalHandler os__signal_opt(os__Signal signum, void (*handler)(os__Signal ));
|
||
_option_void os__open_uri(string uri);
|
||
v__depgraph__OrderedDepMap v__depgraph__new_ordered_dependency_map(void);
|
||
void v__depgraph__OrderedDepMap_set(v__depgraph__OrderedDepMap* o, string name, Array_string deps);
|
||
void v__depgraph__OrderedDepMap_add(v__depgraph__OrderedDepMap* o, string name, Array_string deps);
|
||
Array_string v__depgraph__OrderedDepMap_get(v__depgraph__OrderedDepMap* o, string name);
|
||
void v__depgraph__OrderedDepMap_delete(v__depgraph__OrderedDepMap* o, string name);
|
||
void v__depgraph__OrderedDepMap_apply_diff(v__depgraph__OrderedDepMap* o, string name, Array_string deps);
|
||
int v__depgraph__OrderedDepMap_size(v__depgraph__OrderedDepMap* o);
|
||
v__depgraph__DepGraph* v__depgraph__new_dep_graph(void);
|
||
void v__depgraph__DepGraph_add(v__depgraph__DepGraph* graph, string mod, Array_string deps);
|
||
void v__depgraph__DepGraph_add_with_value(v__depgraph__DepGraph* graph, string mod, Array_string deps, i64 value);
|
||
v__depgraph__DepGraph* v__depgraph__DepGraph_resolve(v__depgraph__DepGraph* graph);
|
||
v__depgraph__DepGraphNode v__depgraph__DepGraph_last_node(v__depgraph__DepGraph* graph);
|
||
string v__depgraph__DepGraph_display(v__depgraph__DepGraph* graph);
|
||
string v__depgraph__DepGraph_display_cycles(v__depgraph__DepGraph* graph);
|
||
VV_LOCAL_SYMBOL multi_return_bool_Array_string v__depgraph__NodeNames_is_part_of_cycle(v__depgraph__NodeNames* nn, string name, Array_string already_seen);
|
||
void v__depgraph__show(v__depgraph__DepGraph* graph, string path);
|
||
VV_LOCAL_SYMBOL u32 rand__seed__nr_next(u32 prev);
|
||
Array_u32 rand__seed__time_seed_array(int count);
|
||
u32 rand__seed__time_seed_32(void);
|
||
u64 rand__seed__time_seed_64(void);
|
||
string term__format(string msg, string open, string close);
|
||
string term__format_rgb(int r, int g, int b, string msg, string open, string close);
|
||
string term__rgb(int r, int g, int b, string msg);
|
||
string term__bg_rgb(int r, int g, int b, string msg);
|
||
string term__hex(int hex, string msg);
|
||
string term__bg_hex(int hex, string msg);
|
||
string term__reset(string msg);
|
||
string term__bold(string msg);
|
||
string term__dim(string msg);
|
||
string term__italic(string msg);
|
||
string term__underline(string msg);
|
||
string term__inverse(string msg);
|
||
string term__hidden(string msg);
|
||
string term__strikethrough(string msg);
|
||
string term__black(string msg);
|
||
string term__red(string msg);
|
||
string term__green(string msg);
|
||
string term__yellow(string msg);
|
||
string term__blue(string msg);
|
||
string term__magenta(string msg);
|
||
string term__cyan(string msg);
|
||
string term__white(string msg);
|
||
string term__bg_black(string msg);
|
||
string term__bg_red(string msg);
|
||
string term__bg_green(string msg);
|
||
string term__bg_yellow(string msg);
|
||
string term__bg_blue(string msg);
|
||
string term__bg_magenta(string msg);
|
||
string term__bg_cyan(string msg);
|
||
string term__bg_white(string msg);
|
||
string term__gray(string msg);
|
||
string term__bright_black(string msg);
|
||
string term__bright_red(string msg);
|
||
string term__bright_green(string msg);
|
||
string term__bright_yellow(string msg);
|
||
string term__bright_blue(string msg);
|
||
string term__bright_magenta(string msg);
|
||
string term__bright_cyan(string msg);
|
||
string term__bright_white(string msg);
|
||
string term__bright_bg_black(string msg);
|
||
string term__bright_bg_red(string msg);
|
||
string term__bright_bg_green(string msg);
|
||
string term__bright_bg_yellow(string msg);
|
||
string term__bright_bg_blue(string msg);
|
||
string term__bright_bg_magenta(string msg);
|
||
string term__bright_bg_cyan(string msg);
|
||
string term__bright_bg_white(string msg);
|
||
string term__highlight_command(string command);
|
||
void term__set_cursor_position(term__Coord c);
|
||
void term__move(int n, string direction);
|
||
void term__cursor_up(int n);
|
||
void term__cursor_down(int n);
|
||
void term__cursor_forward(int n);
|
||
void term__cursor_back(int n);
|
||
void term__erase_display(string t);
|
||
void term__erase_toend(void);
|
||
void term__erase_tobeg(void);
|
||
void term__erase_clear(void);
|
||
void term__erase_del_clear(void);
|
||
void term__erase_line(string t);
|
||
void term__erase_line_toend(void);
|
||
void term__erase_line_tobeg(void);
|
||
void term__erase_line_clear(void);
|
||
void term__show_cursor(void);
|
||
void term__hide_cursor(void);
|
||
void term__clear_previous_line(void);
|
||
bool term__can_show_color_on_stdout(void);
|
||
bool term__can_show_color_on_stderr(void);
|
||
string term__failed(string s);
|
||
string term__ok_message(string s);
|
||
string term__fail_message(string s);
|
||
string term__warn_message(string s);
|
||
string term__colorize(string (*cfn)(string ), string s);
|
||
string term__ecolorize(string (*cfn)(string ), string s);
|
||
string term__strip_ansi(string text);
|
||
string term__h_divider(string divider);
|
||
string term__header_left(string text, string divider);
|
||
string term__header(string text, string divider);
|
||
VV_LOCAL_SYMBOL int term__imax(int x, int y);
|
||
VV_LOCAL_SYMBOL bool term__supports_escape_sequences(int fd);
|
||
multi_return_int_int term__get_terminal_size(void);
|
||
_option_term__Coord term__get_cursor_position(void);
|
||
bool term__set_terminal_title(string title);
|
||
void term__clear(void);
|
||
string v__util__version__vhash(void);
|
||
string v__util__version__full_hash(void);
|
||
string v__util__version__full_v_version(bool is_verbose);
|
||
string v__util__version__githash(bool should_get_from_filesystem);
|
||
v__vcache__CacheManager v__vcache__new_cache_manager(Array_string opts);
|
||
void v__vcache__CacheManager_set_temporary_options(v__vcache__CacheManager* cm, Array_string new_opts);
|
||
string v__vcache__CacheManager_key2cpath(v__vcache__CacheManager* cm, string key);
|
||
string v__vcache__CacheManager_postfix_with_key2cpath(v__vcache__CacheManager* cm, string postfix, string key);
|
||
_option_string v__vcache__CacheManager_exists(v__vcache__CacheManager* cm, string postfix, string key);
|
||
_option_string v__vcache__CacheManager_save(v__vcache__CacheManager* cm, string postfix, string key, string content);
|
||
_option_string v__vcache__CacheManager_load(v__vcache__CacheManager* cm, string postfix, string key);
|
||
VV_LOCAL_SYMBOL void v__vcache__xlog(string fname, string s);
|
||
VV_LOCAL_SYMBOL int v__vcache__mypid(void);
|
||
_option_string v__util__diff__find_working_diff_command(void);
|
||
VV_LOCAL_SYMBOL bool v__util__diff__opendiff_exists(void);
|
||
string v__util__diff__color_compare_files(string diff_cmd, string file1, string file2);
|
||
string v__util__diff__color_compare_strings(string diff_cmd, string unique_prefix, string expected, string found);
|
||
_option_v__vmod__Manifest v__vmod__from_file(string vmod_path);
|
||
_option_v__vmod__Manifest v__vmod__decode(string contents);
|
||
VV_LOCAL_SYMBOL void v__vmod__Scanner_tokenize(v__vmod__Scanner* s, v__vmod__TokenKind t_type, string val);
|
||
VV_LOCAL_SYMBOL void v__vmod__Scanner_skip_whitespace(v__vmod__Scanner* s);
|
||
VV_LOCAL_SYMBOL bool v__vmod__is_name_alpha(u8 chr);
|
||
VV_LOCAL_SYMBOL string v__vmod__Scanner_create_string(v__vmod__Scanner* s, u8 q);
|
||
VV_LOCAL_SYMBOL string v__vmod__Scanner_create_ident(v__vmod__Scanner* s);
|
||
VV_LOCAL_SYMBOL bool v__vmod__Scanner_peek_char(v__vmod__Scanner s, u8 c);
|
||
VV_LOCAL_SYMBOL void v__vmod__Scanner_scan_all(v__vmod__Scanner* s);
|
||
VV_LOCAL_SYMBOL _option_multi_return_Array_string_int v__vmod__get_array_content(Array_v__vmod__Token tokens, int st_idx);
|
||
VV_LOCAL_SYMBOL _option_v__vmod__Manifest v__vmod__Parser_parse(v__vmod__Parser* p);
|
||
v__vmod__ModFileCacher* v__vmod__new_mod_file_cacher(void);
|
||
void v__vmod__ModFileCacher_debug(v__vmod__ModFileCacher* mcache);
|
||
v__vmod__ModFileAndFolder v__vmod__ModFileCacher_get_by_file(v__vmod__ModFileCacher* mcache, string vfile);
|
||
v__vmod__ModFileAndFolder v__vmod__ModFileCacher_get_by_folder(v__vmod__ModFileCacher* mcache, string vfolder);
|
||
VV_LOCAL_SYMBOL void v__vmod__ModFileCacher_add(v__vmod__ModFileCacher* cacher, string path, v__vmod__ModFileAndFolder result);
|
||
VV_LOCAL_SYMBOL multi_return_Array_string_v__vmod__ModFileAndFolder v__vmod__ModFileCacher_traverse(v__vmod__ModFileCacher* mcache, string mfolder);
|
||
VV_LOCAL_SYMBOL void v__vmod__ModFileCacher_mark_folders_with_vmod(v__vmod__ModFileCacher* mcache, Array_string folders_so_far, v__vmod__ModFileAndFolder vmod);
|
||
VV_LOCAL_SYMBOL void v__vmod__ModFileCacher_mark_folders_as_vmod_free(v__vmod__ModFileCacher* mcache, Array_string folders_so_far);
|
||
VV_LOCAL_SYMBOL bool v__vmod__ModFileCacher_check_for_stop(v__vmod__ModFileCacher* mcache, string cfolder, Array_string files);
|
||
VV_LOCAL_SYMBOL Array_string v__vmod__ModFileCacher_get_files(v__vmod__ModFileCacher* mcache, string cfolder);
|
||
v__vmod__ModFileCacher* v__vmod__get_cache(void);
|
||
string v__util__recompilation__disabling_file(string vroot);
|
||
void v__util__recompilation__must_be_enabled(string vroot, string error_message);
|
||
string v__cflag__CFlag_str(v__cflag__CFlag* c);
|
||
string v__cflag__CFlag_eval(v__cflag__CFlag* cf);
|
||
string v__cflag__CFlag_format(v__cflag__CFlag* cf);
|
||
Array_string Array_v__cflag__CFlag_c_options_before_target_msvc(Array_v__cflag__CFlag cflags);
|
||
Array_string Array_v__cflag__CFlag_c_options_after_target_msvc(Array_v__cflag__CFlag cflags);
|
||
Array_string Array_v__cflag__CFlag_c_options_before_target(Array_v__cflag__CFlag cflags);
|
||
Array_string Array_v__cflag__CFlag_c_options_after_target(Array_v__cflag__CFlag cflags);
|
||
Array_string Array_v__cflag__CFlag_c_options_without_object_files(Array_v__cflag__CFlag cflags);
|
||
Array_string Array_v__cflag__CFlag_c_options_only_object_files(Array_v__cflag__CFlag cflags);
|
||
multi_return_Array_string_Array_string_Array_string Array_v__cflag__CFlag_defines_others_libs(Array_v__cflag__CFlag cflags);
|
||
void rand__wyrand__WyRandRNG_seed(rand__wyrand__WyRandRNG* rng, Array_u32 seed_data);
|
||
u8 rand__wyrand__WyRandRNG_u8(rand__wyrand__WyRandRNG* rng);
|
||
u16 rand__wyrand__WyRandRNG_u16(rand__wyrand__WyRandRNG* rng);
|
||
u32 rand__wyrand__WyRandRNG_u32(rand__wyrand__WyRandRNG* rng);
|
||
u64 rand__wyrand__WyRandRNG_u64(rand__wyrand__WyRandRNG* rng);
|
||
int rand__wyrand__WyRandRNG_block_size(rand__wyrand__WyRandRNG* rng);
|
||
void rand__wyrand__WyRandRNG_free(rand__wyrand__WyRandRNG* rng);
|
||
VV_LOCAL_SYMBOL _option_string v__pkgconfig__desc(string mod);
|
||
_option_v__pkgconfig__Main_ptr v__pkgconfig__main(Array_string args);
|
||
VV_LOCAL_SYMBOL int compare_10487185186218018245_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
_option_string v__pkgconfig__Main_run(v__pkgconfig__Main* m);
|
||
VV_LOCAL_SYMBOL string v__pkgconfig__filter(Array_string libs, string prefix, string prefix2);
|
||
VV_LOCAL_SYMBOL v__pkgconfig__MainOptions* v__pkgconfig__parse_options(flag__FlagParser* fp);
|
||
VV_LOCAL_SYMBOL Array_string v__pkgconfig__PkgConfig_parse_list_no_comma(v__pkgconfig__PkgConfig* pc, string s);
|
||
VV_LOCAL_SYMBOL Array_string v__pkgconfig__PkgConfig_parse_list(v__pkgconfig__PkgConfig* pc, string s);
|
||
VV_LOCAL_SYMBOL string v__pkgconfig__PkgConfig_parse_line(v__pkgconfig__PkgConfig* pc, string s);
|
||
VV_LOCAL_SYMBOL void v__pkgconfig__PkgConfig_setvar(v__pkgconfig__PkgConfig* pc, string line);
|
||
VV_LOCAL_SYMBOL bool v__pkgconfig__PkgConfig_parse(v__pkgconfig__PkgConfig* pc, string file);
|
||
VV_LOCAL_SYMBOL _option_string v__pkgconfig__PkgConfig_resolve(v__pkgconfig__PkgConfig* pc, string pkgname);
|
||
bool v__pkgconfig__atleast(string v);
|
||
bool v__pkgconfig__PkgConfig_atleast(v__pkgconfig__PkgConfig* pc, string v);
|
||
_option_string v__pkgconfig__PkgConfig_extend(v__pkgconfig__PkgConfig* pc, v__pkgconfig__PkgConfig* pcdep);
|
||
VV_LOCAL_SYMBOL _option_void v__pkgconfig__PkgConfig_load_requires(v__pkgconfig__PkgConfig* pc);
|
||
VV_LOCAL_SYMBOL _option_void v__pkgconfig__PkgConfig_load_require(v__pkgconfig__PkgConfig* pc, string dep);
|
||
VV_LOCAL_SYMBOL void v__pkgconfig__PkgConfig_add_path(v__pkgconfig__PkgConfig* pc, string path);
|
||
VV_LOCAL_SYMBOL void v__pkgconfig__PkgConfig_load_paths(v__pkgconfig__PkgConfig* pc);
|
||
_option_v__pkgconfig__PkgConfig_ptr v__pkgconfig__load(string pkgname, v__pkgconfig__Options options);
|
||
Array_string v__pkgconfig__list(void);
|
||
int runtime__nr_jobs(void);
|
||
bool runtime__is_32bit(void);
|
||
bool runtime__is_64bit(void);
|
||
bool runtime__is_little_endian(void);
|
||
bool runtime__is_big_endian(void);
|
||
int runtime__nr_cpus(void);
|
||
VV_LOCAL_SYMBOL f64 rand__msqrt(f64 a);
|
||
VV_LOCAL_SYMBOL f64 rand__mlog(f64 a);
|
||
VV_LOCAL_SYMBOL multi_return_f64_int rand__frexp(f64 x);
|
||
VV_LOCAL_SYMBOL f64 rand__scalbn(f64 x, int n_);
|
||
VV_LOCAL_SYMBOL f64 rand__f64_from_bits(u64 b);
|
||
VV_LOCAL_SYMBOL u64 rand__f64_bits(f64 f);
|
||
string rand__uuid_v4(void);
|
||
VV_LOCAL_SYMBOL string rand__internal_uuid_v4(rand__PRNG* rng);
|
||
VV_LOCAL_SYMBOL string rand__internal_ulid_at_millisecond(rand__PRNG* rng, u64 unix_time_milli);
|
||
VV_LOCAL_SYMBOL string rand__internal_string_from_set(rand__PRNG* rng, string charset, int len);
|
||
VV_LOCAL_SYMBOL void rand__deinit(void);
|
||
VV_LOCAL_SYMBOL void rand__init(void);
|
||
VV_LOCAL_SYMBOL void rand__read_32(rand__PRNG* rng, Array_u8* buf);
|
||
VV_LOCAL_SYMBOL void rand__read_64(rand__PRNG* rng, Array_u8* buf);
|
||
VV_LOCAL_SYMBOL void rand__read_internal(rand__PRNG* rng, Array_u8* buf);
|
||
_option_Array_u8 rand__PRNG_bytes(rand__PRNG* rng, int bytes_needed);
|
||
void rand__PRNG_read(rand__PRNG* rng, Array_u8* buf);
|
||
_option_u32 rand__PRNG_u32n(rand__PRNG* rng, u32 max);
|
||
_option_u64 rand__PRNG_u64n(rand__PRNG* rng, u64 max);
|
||
_option_u32 rand__PRNG_u32_in_range(rand__PRNG* rng, u32 min, u32 max);
|
||
_option_u64 rand__PRNG_u64_in_range(rand__PRNG* rng, u64 min, u64 max);
|
||
i8 rand__PRNG_i8(rand__PRNG* rng);
|
||
i16 rand__PRNG_i16(rand__PRNG* rng);
|
||
int rand__PRNG_int(rand__PRNG* rng);
|
||
i64 rand__PRNG_i64(rand__PRNG* rng);
|
||
int rand__PRNG_int31(rand__PRNG* rng);
|
||
i64 rand__PRNG_int63(rand__PRNG* rng);
|
||
_option_int rand__PRNG_intn(rand__PRNG* rng, int max);
|
||
_option_i64 rand__PRNG_i64n(rand__PRNG* rng, i64 max);
|
||
_option_int rand__PRNG_int_in_range(rand__PRNG* rng, int min, int max);
|
||
_option_i64 rand__PRNG_i64_in_range(rand__PRNG* rng, i64 min, i64 max);
|
||
f32 rand__PRNG_f32(rand__PRNG* rng);
|
||
f64 rand__PRNG_f64(rand__PRNG* rng);
|
||
_option_f32 rand__PRNG_f32n(rand__PRNG* rng, f32 max);
|
||
_option_f64 rand__PRNG_f64n(rand__PRNG* rng, f64 max);
|
||
_option_f32 rand__PRNG_f32_in_range(rand__PRNG* rng, f32 min, f32 max);
|
||
_option_f64 rand__PRNG_f64_in_range(rand__PRNG* rng, f64 min, f64 max);
|
||
string rand__PRNG_ulid(rand__PRNG* rng);
|
||
string rand__PRNG_ulid_at_millisecond(rand__PRNG* rng, u64 unix_time_milli);
|
||
string rand__PRNG_string_from_set(rand__PRNG* rng, string charset, int len);
|
||
string rand__PRNG_string(rand__PRNG* rng, int len);
|
||
string rand__PRNG_hex(rand__PRNG* rng, int len);
|
||
string rand__PRNG_ascii(rand__PRNG* rng, int len);
|
||
_option_bool rand__PRNG_bernoulli(rand__PRNG* rng, f64 p);
|
||
_option_f64 rand__PRNG_normal(rand__PRNG* rng, rand__config__NormalConfigStruct conf);
|
||
_option_multi_return_f64_f64 rand__PRNG_normal_pair(rand__PRNG* rng, rand__config__NormalConfigStruct conf);
|
||
_option_int rand__PRNG_binomial(rand__PRNG* rng, int n, f64 p);
|
||
f64 rand__PRNG_exponential(rand__PRNG* rng, f64 lambda);
|
||
rand__PRNG* rand__new_default(rand__config__PRNGConfigStruct config);
|
||
rand__PRNG* rand__get_current_rng(void);
|
||
void rand__set_rng(rand__PRNG* rng);
|
||
void rand__seed(Array_u32 seed);
|
||
u32 rand__u32(void);
|
||
u64 rand__u64(void);
|
||
_option_u32 rand__u32n(u32 max);
|
||
_option_u64 rand__u64n(u64 max);
|
||
_option_u32 rand__u32_in_range(u32 min, u32 max);
|
||
_option_u64 rand__u64_in_range(u64 min, u64 max);
|
||
i16 rand__i16(void);
|
||
int rand__int(void);
|
||
_option_int rand__intn(int max);
|
||
u8 rand__u8(void);
|
||
_option_int rand__int_in_range(int min, int max);
|
||
int rand__int31(void);
|
||
i64 rand__i64(void);
|
||
_option_i64 rand__i64n(i64 max);
|
||
_option_i64 rand__i64_in_range(i64 min, i64 max);
|
||
i64 rand__int63(void);
|
||
f32 rand__f32(void);
|
||
f64 rand__f64(void);
|
||
_option_f32 rand__f32n(f32 max);
|
||
_option_f64 rand__f64n(f64 max);
|
||
_option_f32 rand__f32_in_range(f32 min, f32 max);
|
||
_option_f64 rand__f64_in_range(f64 min, f64 max);
|
||
_option_Array_u8 rand__bytes(int bytes_needed);
|
||
void rand__read(Array_u8* buf);
|
||
string rand__ulid(void);
|
||
string rand__ulid_at_millisecond(u64 unix_time_milli);
|
||
string rand__string_from_set(string charset, int len);
|
||
string rand__string(int len);
|
||
string rand__hex(int len);
|
||
string rand__ascii(int len);
|
||
_option_bool rand__bernoulli(f64 p);
|
||
_option_f64 rand__normal(rand__config__NormalConfigStruct conf);
|
||
_option_multi_return_f64_f64 rand__normal_pair(rand__config__NormalConfigStruct conf);
|
||
_option_int rand__binomial(int n, f64 p);
|
||
f64 rand__exponential(f64 lambda);
|
||
v__pref__Preferences* v__pref__new_preferences(void);
|
||
VV_LOCAL_SYMBOL void v__pref__Preferences_expand_lookup_paths(v__pref__Preferences* p);
|
||
void v__pref__Preferences_fill_with_defaults(v__pref__Preferences* p);
|
||
VV_LOCAL_SYMBOL void v__pref__Preferences_find_cc_if_cross_compiling(v__pref__Preferences* p);
|
||
VV_LOCAL_SYMBOL void v__pref__Preferences_try_to_use_tcc_by_default(v__pref__Preferences* p);
|
||
string v__pref__default_tcc_compiler(void);
|
||
void v__pref__Preferences_default_c_compiler(v__pref__Preferences* p);
|
||
string v__pref__vexe_path(void);
|
||
string v__pref__Preferences_vcross_compiler_name(v__pref__Preferences* p);
|
||
_option_v__pref__OS v__pref__os_from_string(string os_str);
|
||
string v__pref__OS_str(v__pref__OS o);
|
||
v__pref__OS v__pref__get_host_os(void);
|
||
bool v__pref__Backend_is_js(v__pref__Backend b);
|
||
multi_return_ref_v__pref__Preferences_string v__pref__parse_args(Array_string known_external_commands, Array_string args);
|
||
VV_LOCAL_SYMBOL void v__pref__detect_musl(v__pref__Preferences* res);
|
||
multi_return_ref_v__pref__Preferences_string v__pref__parse_args_and_show_errors(Array_string known_external_commands, Array_string args, bool show_output);
|
||
void v__pref__eprintln_cond(bool condition, string s);
|
||
void v__pref__Preferences_vrun_elog(v__pref__Preferences* pref, string s);
|
||
bool v__pref__Preferences_should_output_to_stdout(v__pref__Preferences* pref);
|
||
_option_v__pref__Arch v__pref__arch_from_string(string arch_str);
|
||
VV_LOCAL_SYMBOL void v__pref__must_exist(string path);
|
||
VV_LOCAL_SYMBOL bool v__pref__is_source_file(string path);
|
||
_option_v__pref__Backend v__pref__backend_from_string(string s);
|
||
v__pref__CompilerType v__pref__cc_from_string(string cc_str);
|
||
v__pref__Arch v__pref__get_host_arch(void);
|
||
VV_LOCAL_SYMBOL void v__pref__Preferences_parse_define(v__pref__Preferences* prefs, string define);
|
||
VV_LOCAL_SYMBOL void v__pref__Preferences_diagnose_deprecated_defines(v__pref__Preferences* prefs, Array_string define_parts);
|
||
Array_string v__pref__Preferences_should_compile_filtered_files(v__pref__Preferences* prefs, string dir, Array_string files_);
|
||
VV_LOCAL_SYMBOL int compare_15729605724654494396_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL string v__pref__fname_without_platform_postfix(string file);
|
||
bool v__pref__Preferences_should_compile_native(v__pref__Preferences* prefs, string file);
|
||
bool v__pref__Preferences_should_compile_c(v__pref__Preferences* prefs, string file);
|
||
bool v__pref__Preferences_should_compile_asm(v__pref__Preferences* prefs, string path);
|
||
bool v__pref__Preferences_should_compile_js(v__pref__Preferences* prefs, string file);
|
||
VV_LOCAL_SYMBOL sync__Channel* sync__new_channel_st(u32 n, u32 st);
|
||
VV_LOCAL_SYMBOL sync__Channel* sync__new_channel_st_noscan(u32 n, u32 st);
|
||
string sync__Channel_auto_str(sync__Channel* ch, string _v_typename);
|
||
void sync__Channel_close(sync__Channel* ch);
|
||
int sync__Channel_len(sync__Channel* ch);
|
||
bool sync__Channel_closed(sync__Channel* ch);
|
||
void sync__Channel_push(sync__Channel* ch, voidptr src);
|
||
ChanState sync__Channel_try_push(sync__Channel* ch, voidptr src);
|
||
VV_LOCAL_SYMBOL ChanState sync__Channel_try_push_priv(sync__Channel* ch, voidptr src, bool no_block);
|
||
bool sync__Channel_pop(sync__Channel* ch, voidptr dest);
|
||
ChanState sync__Channel_try_pop(sync__Channel* ch, voidptr dest);
|
||
VV_LOCAL_SYMBOL ChanState sync__Channel_try_pop_priv(sync__Channel* ch, voidptr dest, bool no_block);
|
||
int sync__channel_select(Array_sync__Channel_ptr* channels, Array_sync__Direction dir, Array_voidptr* objrefs, time__Duration timeout);
|
||
sync__ManyTimes* sync__new_many_times(u64 times);
|
||
void sync__ManyTimes_do(sync__ManyTimes* m, void (*f)());
|
||
VV_LOCAL_SYMBOL void sync__ManyTimes_do_slow(sync__ManyTimes* m, void (*f)());
|
||
sync__Once* sync__new_once(void);
|
||
void sync__Once_do(sync__Once* o, void (*f)());
|
||
VV_LOCAL_SYMBOL void sync__Once_do_slow(sync__Once* o, void (*f)());
|
||
void sync__Once_do_with_param(sync__Once* o, void (*f)(voidptr ), voidptr param);
|
||
VV_LOCAL_SYMBOL void sync__Once_do_slow_with_param(sync__Once* o, void (*f)(voidptr ), voidptr param);
|
||
sync__WaitGroup* sync__new_waitgroup(void);
|
||
void sync__WaitGroup_init(sync__WaitGroup* wg);
|
||
void sync__WaitGroup_add(sync__WaitGroup* wg, int delta);
|
||
void sync__WaitGroup_done(sync__WaitGroup* wg);
|
||
void sync__WaitGroup_wait(sync__WaitGroup* wg);
|
||
sync__Mutex* sync__new_mutex(void);
|
||
void sync__Mutex_init(sync__Mutex* m);
|
||
sync__RwMutex* sync__new_rwmutex(void);
|
||
void sync__RwMutex_init(sync__RwMutex* m);
|
||
void sync__Mutex_lock(sync__Mutex* m);
|
||
void sync__Mutex_unlock(sync__Mutex* m);
|
||
void sync__RwMutex_rlock(sync__RwMutex* m);
|
||
void sync__RwMutex_lock(sync__RwMutex* m);
|
||
void sync__RwMutex_runlock(sync__RwMutex* m);
|
||
void sync__RwMutex_unlock(sync__RwMutex* m);
|
||
sync__Semaphore* sync__new_semaphore(void);
|
||
sync__Semaphore* sync__new_semaphore_init(u32 n);
|
||
void sync__Semaphore_init(sync__Semaphore* sem, u32 n);
|
||
void sync__Semaphore_post(sync__Semaphore* sem);
|
||
void sync__Semaphore_wait(sync__Semaphore* sem);
|
||
bool sync__Semaphore_try_wait(sync__Semaphore* sem);
|
||
bool sync__Semaphore_timed_wait(sync__Semaphore* sem, time__Duration timeout);
|
||
void sync__Semaphore_destroy(sync__Semaphore _v_toheap_sem);
|
||
u64 sync__thread_id(void);
|
||
void help__print_and_exit(string topic);
|
||
VV_LOCAL_SYMBOL string help__known_topics(string topicdir);
|
||
VV_LOCAL_SYMBOL int compare_13139793989557853369_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
_option_string v__util__find_working_diff_command(void);
|
||
string v__util__color_compare_files(string diff_cmd, string file1, string file2);
|
||
string v__util__color_compare_strings(string diff_cmd, string unique_prefix, string expected, string found);
|
||
v__util__EManager* v__util__new_error_manager(void);
|
||
void v__util__EManager_set_support_color(v__util__EManager* e, bool b);
|
||
string v__util__bold(string msg);
|
||
VV_LOCAL_SYMBOL string v__util__color(string kind, string msg);
|
||
string v__util__formatted_error(string kind, string omsg, string filepath, v__token__Pos pos);
|
||
Array_string v__util__cached_file2sourcelines(string path);
|
||
Array_string v__util__set_source_for_path(string path, string source);
|
||
Array_string v__util__source_file_context(string kind, string filepath, v__token__Pos pos);
|
||
void v__util__verror(string kind, string s);
|
||
string v__util__vlines_escape_path(string path, string ccompiler);
|
||
string v__util__qualify_import(v__pref__Preferences* pref, string mod, string file_path);
|
||
string v__util__qualify_module(v__pref__Preferences* pref, string mod, string file_path);
|
||
VV_LOCAL_SYMBOL _option_string v__util__mod_path_to_full_name(v__pref__Preferences* pref, string mod, string path);
|
||
string v__util__smart_quote(string str, bool raw);
|
||
bool v__util__is_name_char(u8 c);
|
||
bool v__util__is_func_char(u8 c);
|
||
bool v__util__contains_capital(string s);
|
||
bool v__util__good_type_name(string s);
|
||
bool v__util__is_generic_type_name(string name);
|
||
string v__util__cescaped_path(string s);
|
||
v__util__Suggestion v__util__new_suggestion(string wanted, Array_string possibilities);
|
||
void v__util__Suggestion_add(v__util__Suggestion* s, string val);
|
||
void v__util__Suggestion_add_many(v__util__Suggestion* s, Array_string many);
|
||
void v__util__Suggestion_sort(v__util__Suggestion* s);
|
||
VV_LOCAL_SYMBOL int compare_14781029812553904099_v__util__Possibility_by_similarity(v__util__Possibility* a, v__util__Possibility* b) {
|
||
if (a->similarity < b->similarity) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
string v__util__Suggestion_say(v__util__Suggestion s, string msg);
|
||
VV_LOCAL_SYMBOL int compare_14781029812553904099_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
string v__util__short_module_name(string name);
|
||
string v__util__highlight_suggestion(string message);
|
||
v__util__Surrounder v__util__new_surrounder(int expected_length);
|
||
void v__util__Surrounder_add(v__util__Surrounder* s, string before, string after);
|
||
string v__util__Surrounder_before(v__util__Surrounder* s);
|
||
string v__util__Surrounder_after(v__util__Surrounder* s);
|
||
void v__util__Surrounder_builder_write_befores(v__util__Surrounder* s, strings__Builder* sb);
|
||
void v__util__Surrounder_builder_write_afters(v__util__Surrounder* s, strings__Builder* sb);
|
||
void v__util__Surrounder_free(v__util__Surrounder* s);
|
||
v__util__Timers* v__util__new_timers(v__util__TimerParams params);
|
||
v__util__Timers* v__util__get_timers(void);
|
||
void v__util__timing_start(string label);
|
||
void v__util__timing_measure(string label);
|
||
void v__util__timing_measure_cumulative(string label);
|
||
void v__util__timing_set_should_print(bool should_print);
|
||
void v__util__Timers_start(v__util__Timers* t, string name);
|
||
i64 v__util__Timers_measure(v__util__Timers* t, string name);
|
||
i64 v__util__Timers_measure_cumulative(v__util__Timers* t, string name);
|
||
void v__util__Timers_measure_pause(v__util__Timers* t, string name);
|
||
void v__util__Timers_measure_resume(v__util__Timers* t, string name);
|
||
string v__util__Timers_message(v__util__Timers* t, string name);
|
||
void v__util__Timers_show(v__util__Timers* t, string label);
|
||
void v__util__Timers_show_if_exists(v__util__Timers* t, string label);
|
||
void v__util__Timers_show_remaining(v__util__Timers* t);
|
||
void v__util__Timers_dump_all(v__util__Timers* t);
|
||
string v__util__skip_bom(string file_content);
|
||
bool v__util__module_is_builtin(string mod);
|
||
string v__util__tabs(int n);
|
||
void v__util__set_vroot_folder(string vroot_path);
|
||
_option_string v__util__resolve_vmodroot(string str, string dir);
|
||
_option_string v__util__resolve_env_value(string str, bool check_for_presence);
|
||
void v__util__launch_tool(bool is_verbose, string tool_name, Array_string args);
|
||
bool v__util__should_recompile_tool(string vexe, string tool_source, string tool_name, string tool_exe);
|
||
VV_LOCAL_SYMBOL multi_return_string_string v__util__tool_source2name_and_exe(string tool_source);
|
||
string v__util__quote_path(string s);
|
||
string v__util__args_quote_paths(Array_string args);
|
||
string v__util__path_of_executable(string path);
|
||
_option_string v__util__cached_read_source_file(string path);
|
||
string v__util__replace_op(string s);
|
||
Array_string v__util__join_env_vflags_and_os_args(void);
|
||
VV_LOCAL_SYMBOL Array_string v__util__non_empty(Array_string arg);
|
||
_option_bool v__util__check_module_is_installed(string modulename, bool is_verbose);
|
||
void v__util__ensure_modules_for_all_tools_are_installed(bool is_verbose);
|
||
string v__util__strip_mod_name(string name);
|
||
string v__util__strip_main_name(string name);
|
||
string v__util__no_dots(string s);
|
||
string v__util__no_cur_mod(string _v_typename, string cur_mod);
|
||
void v__util__prepare_tool_when_needed(string source_name);
|
||
void v__util__recompile_file(string vexe, string file);
|
||
string v__util__get_vtmp_folder(void);
|
||
bool v__util__should_bundle_module(string mod);
|
||
_option_Array_string v__util__find_all_v_files(Array_string roots);
|
||
void v__util__free_caches(void);
|
||
_option_string v__util__read_file(string file_path);
|
||
sync__pool__PoolProcessor* sync__pool__new_pool_processor(sync__pool__PoolProcessorConfig context);
|
||
void sync__pool__PoolProcessor_set_max_jobs(sync__pool__PoolProcessor* pool, int njobs);
|
||
void sync__pool__PoolProcessor_work_on_items_T___ptr__v__ast__File(sync__pool__PoolProcessor* pool, Array_v__ast__File_ptr items);
|
||
void sync__pool__PoolProcessor_work_on_pointers(sync__pool__PoolProcessor* pool, Array_voidptr items);
|
||
VV_LOCAL_SYMBOL void sync__pool__process_in_thread(sync__pool__PoolProcessor* pool, int task_id);
|
||
v__ast__File* sync__pool__PoolProcessor_get_item_T___ptr__v__ast__File(sync__pool__PoolProcessor* pool, int idx);
|
||
Array_v__gen__c__Gen_ptr sync__pool__PoolProcessor_get_results_ref_T_v__gen__c__Gen(sync__pool__PoolProcessor* pool);
|
||
void sync__pool__PoolProcessor_set_shared_context(sync__pool__PoolProcessor* pool, voidptr context);
|
||
voidptr sync__pool__PoolProcessor_get_shared_context(sync__pool__PoolProcessor* pool);
|
||
void sync__pool__PoolProcessor_set_thread_context(sync__pool__PoolProcessor* pool, int idx, voidptr context);
|
||
voidptr sync__pool__PoolProcessor_get_thread_context(sync__pool__PoolProcessor* pool, int idx);
|
||
string v__ast__ComptimeType_str(v__ast__ComptimeType cty);
|
||
v__ast__Expr v__ast__empty_expr(void);
|
||
v__ast__Stmt v__ast__empty_stmt(void);
|
||
v__ast__Node v__ast__empty_node(void);
|
||
_option_v__ast__Ident v__ast__SelectorExpr_root_ident(v__ast__SelectorExpr* e);
|
||
bool v__ast__StructField_equals(v__ast__StructField* f, v__ast__StructField* o);
|
||
void v__ast__File_free(v__ast__File* f);
|
||
bool v__ast__Ident_is_mut(v__ast__Ident* i);
|
||
v__ast__IdentVar v__ast__Ident_var_info(v__ast__Ident* i);
|
||
bool v__ast__Expr_is_blank_ident(v__ast__Expr expr);
|
||
v__token__Pos v__ast__Expr_pos(v__ast__Expr expr);
|
||
bool v__ast__Expr_is_lvalue(v__ast__Expr expr);
|
||
bool v__ast__Expr_is_expr(v__ast__Expr expr);
|
||
bool v__ast__Expr_is_pure_literal(v__ast__Expr expr);
|
||
bool v__ast__Expr_is_auto_deref_var(v__ast__Expr expr);
|
||
bool v__ast__Expr_is_lockable(v__ast__Expr* e);
|
||
_option_void v__ast__Stmt_check_c_expr(v__ast__Stmt stmt);
|
||
v__token__Pos v__ast__Node_pos(v__ast__Node node);
|
||
Array_v__ast__Node v__ast__Node_children(v__ast__Node node);
|
||
void v__ast__IndexExpr_recursive_mapset_is_setter(v__ast__IndexExpr* lx, bool val);
|
||
void v__ast__IndexExpr_recursive_arraymap_set_is_setter(v__ast__IndexExpr* lx);
|
||
Map_string_v__ast__ScopeObject v__ast__all_registers(v__ast__Table* t, v__pref__Arch arch);
|
||
VV_LOCAL_SYMBOL Map_string_v__ast__ScopeObject v__ast__gen_all_registers(v__ast__Table* t, Array_string without_numbers, Map_string_int with_numbers, int bit_size);
|
||
bool v__ast__Expr_is_literal(v__ast__Expr expr);
|
||
bool v__ast__type_can_start_with_token(v__token__Token* tok);
|
||
VV_LOCAL_SYMBOL v__token__KeywordsMatcher v__ast__build_builtin_type_names_matcher(void);
|
||
string v__ast__Attr_debug(v__ast__Attr* a);
|
||
string v__ast__Attr_str(v__ast__Attr* a);
|
||
bool Array_v__ast__Attr_contains(Array_v__ast__Attr attrs, string str);
|
||
_option_v__ast__Attr Array_v__ast__Attr_find_first(Array_v__ast__Attr attrs, string aname);
|
||
_option_v__ast__Attr Array_v__ast__Attr_find_last(Array_v__ast__Attr attrs, string aname);
|
||
_option_int Array_v__ast__Attr_find_comptime_define(Array_v__ast__Attr attrs);
|
||
VV_LOCAL_SYMBOL bool v__ast__Table_has_cflag(v__ast__Table* t, v__cflag__CFlag flag);
|
||
_option_bool v__ast__Table_parse_cflag(v__ast__Table* t, string cflg, string mod, Array_string ctimedefines);
|
||
v__ast__ComptTimeConstValue v__ast__empty_comptime_const_expr(void);
|
||
_option_i8 v__ast__ComptTimeConstValue_i8(v__ast__ComptTimeConstValue val);
|
||
_option_i16 v__ast__ComptTimeConstValue_i16(v__ast__ComptTimeConstValue val);
|
||
_option_int v__ast__ComptTimeConstValue_int(v__ast__ComptTimeConstValue val);
|
||
_option_i64 v__ast__ComptTimeConstValue_i64(v__ast__ComptTimeConstValue val);
|
||
_option_u8 v__ast__ComptTimeConstValue_u8(v__ast__ComptTimeConstValue val);
|
||
_option_u16 v__ast__ComptTimeConstValue_u16(v__ast__ComptTimeConstValue val);
|
||
_option_u32 v__ast__ComptTimeConstValue_u32(v__ast__ComptTimeConstValue val);
|
||
_option_u64 v__ast__ComptTimeConstValue_u64(v__ast__ComptTimeConstValue val);
|
||
_option_f32 v__ast__ComptTimeConstValue_f32(v__ast__ComptTimeConstValue val);
|
||
_option_f64 v__ast__ComptTimeConstValue_f64(v__ast__ComptTimeConstValue val);
|
||
_option_string v__ast__ComptTimeConstValue_string(v__ast__ComptTimeConstValue val);
|
||
_option_v__ast__ComptTimeConstValue v__ast__ConstField_comptime_expr_value(v__ast__ConstField* obj);
|
||
bool v__ast__ConstField_is_simple_define_const(v__ast__ConstField* obj);
|
||
bool v__ast__ScopeObject_is_simple_define_const(v__ast__ScopeObject obj);
|
||
u64 v__ast__EmbeddedFile_hash(v__ast__EmbeddedFile e);
|
||
v__ast__Expr v__ast__resolve_init(v__ast__StructInit node, v__ast__Type typ, v__ast__Table* t);
|
||
void v__ast__Scope_free(v__ast__Scope* s);
|
||
VV_LOCAL_SYMBOL bool v__ast__Scope_dont_lookup_parent(v__ast__Scope* s);
|
||
_option_v__ast__ScopeObject v__ast__Scope_find(v__ast__Scope* s, string name);
|
||
_option_v__ast__ScopeStructField v__ast__Scope_find_struct_field(v__ast__Scope* s, string name, v__ast__Type struct_type, string field_name);
|
||
_option_v__ast__Var_ptr v__ast__Scope_find_var(v__ast__Scope* s, string name);
|
||
_option_v__ast__GlobalField_ptr v__ast__Scope_find_global(v__ast__Scope* s, string name);
|
||
_option_v__ast__ConstField_ptr v__ast__Scope_find_const(v__ast__Scope* s, string name);
|
||
bool v__ast__Scope_known_var(v__ast__Scope* s, string name);
|
||
bool v__ast__Scope_known_const(v__ast__Scope* s, string name);
|
||
void v__ast__Scope_update_var_type(v__ast__Scope* s, string name, v__ast__Type typ);
|
||
void v__ast__Scope_register_struct_field(v__ast__Scope* s, string name, v__ast__ScopeStructField field);
|
||
void v__ast__Scope_register(v__ast__Scope* s, v__ast__ScopeObject obj);
|
||
v__ast__Scope* v__ast__Scope_innermost(v__ast__Scope* s, int pos);
|
||
bool v__ast__Scope_contains(v__ast__Scope* s, int pos);
|
||
bool v__ast__Scope_has_inherited_vars(v__ast__Scope* s);
|
||
string v__ast__Scope_show(v__ast__Scope _v_toheap_sc, int depth, int max_depth);
|
||
string v__ast__Scope_str(v__ast__Scope _v_toheap_sc);
|
||
string v__ast__FnDecl_modname(v__ast__FnDecl* node);
|
||
string v__ast__FnDecl_fkey(v__ast__FnDecl* node);
|
||
string v__ast__Fn_fkey(v__ast__Fn* node);
|
||
string v__ast__CallExpr_fkey(v__ast__CallExpr* node);
|
||
string v__ast__AnonFn_stringify(v__ast__AnonFn* node, v__ast__Table* t, string cur_mod, Map_string_string m2a);
|
||
string v__ast__FnDecl_stringify(v__ast__FnDecl* node, v__ast__Table* t, string cur_mod, Map_string_string m2a);
|
||
VV_LOCAL_SYMBOL void v__ast__stringify_fn_after_name(v__ast__FnDecl* node, strings__Builder* f, v__ast__Table* t, string cur_mod, Map_string_string m2a);
|
||
multi_return_string_bool v__ast__StringInterLiteral_get_fspec_braces(v__ast__StringInterLiteral* lit, int i);
|
||
string v__ast__Expr_str(v__ast__Expr x);
|
||
string v__ast__CallArg_str(v__ast__CallArg a);
|
||
string v__ast__args2str(Array_v__ast__CallArg args);
|
||
string v__ast__BranchStmt_str(v__ast__BranchStmt* node);
|
||
string v__ast__Stmt_str(v__ast__Stmt node);
|
||
VV_LOCAL_SYMBOL string v__ast__field_to_string(v__ast__ConstField f);
|
||
string v__ast__ComptimeForKind_str(v__ast__ComptimeForKind e);
|
||
void v__ast__Table_free(v__ast__Table* t);
|
||
VV_LOCAL_SYMBOL void v__ast__default_table_panic_handler(v__ast__Table* t, string message);
|
||
void v__ast__Table_panic(v__ast__Table* t, string message);
|
||
VV_LOCAL_SYMBOL bool v__ast__Fn_method_equals(v__ast__Fn* f, v__ast__Fn* o);
|
||
v__ast__Fn v__ast__Fn_new_method_with_receiver_type(v__ast__Fn* f, v__ast__Type new_type);
|
||
v__ast__FnDecl v__ast__FnDecl_new_method_with_receiver_type(v__ast__FnDecl* f, v__ast__Type new_type);
|
||
VV_LOCAL_SYMBOL bool v__ast__Param_equals(v__ast__Param* p, v__ast__Param* o);
|
||
VV_LOCAL_SYMBOL bool Array_v__ast__Param_equals(Array_v__ast__Param p, Array_v__ast__Param o);
|
||
v__ast__Table* v__ast__new_table(void);
|
||
void v__ast__set_global_table(v__ast__Table* t);
|
||
string v__ast__Table_fn_type_signature(v__ast__Table* t, v__ast__Fn* f);
|
||
string v__ast__Table_fn_type_source_signature(v__ast__Table* t, v__ast__Fn* f);
|
||
string v__ast__Table_is_same_method(v__ast__Table* t, v__ast__Fn* f, v__ast__Fn* func);
|
||
_option_v__ast__Fn v__ast__Table_find_fn(v__ast__Table* t, string name);
|
||
bool v__ast__Table_known_fn(v__ast__Table* t, string name);
|
||
void v__ast__Table_mark_module_as_deprecated(v__ast__Table* t, string mname, string message);
|
||
void v__ast__Table_mark_module_as_deprecated_after(v__ast__Table* t, string mname, string after_date);
|
||
void v__ast__Table_register_fn(v__ast__Table* t, v__ast__Fn new_fn);
|
||
void v__ast__Table_register_interface(v__ast__Table* t, v__ast__InterfaceDecl idecl);
|
||
int v__ast__TypeSymbol_register_method(v__ast__TypeSymbol* t, v__ast__Fn new_fn);
|
||
_option_v__ast__Fn v__ast__Table_register_aggregate_method(v__ast__Table* t, v__ast__TypeSymbol* sym, string name);
|
||
bool v__ast__Table_has_method(v__ast__Table* t, v__ast__TypeSymbol* s, string name);
|
||
_option_v__ast__Fn v__ast__Table_find_method(v__ast__Table* t, v__ast__TypeSymbol* s, string name);
|
||
Array_Array_v__ast__Type v__ast__Table_get_embeds(v__ast__Table* t, v__ast__TypeSymbol* sym, v__ast__GetEmbedsOptions options);
|
||
_option_multi_return_v__ast__Fn_Array_v__ast__Type v__ast__Table_find_method_from_embeds(v__ast__Table* t, v__ast__TypeSymbol* sym, string method_name);
|
||
_option_v__ast__Fn v__ast__Table_find_method_with_embeds(v__ast__Table* t, v__ast__TypeSymbol* sym, string method_name);
|
||
Array_v__ast__Fn v__ast__Table_get_embed_methods(v__ast__Table* t, v__ast__TypeSymbol* sym);
|
||
VV_LOCAL_SYMBOL _option_v__ast__StructField v__ast__Table_register_aggregate_field(v__ast__Table* t, v__ast__TypeSymbol* sym, string name);
|
||
bool v__ast__Table_struct_has_field(v__ast__Table* t, v__ast__TypeSymbol* struct_, string name);
|
||
Array_v__ast__StructField v__ast__Table_struct_fields(v__ast__Table* t, v__ast__TypeSymbol* sym);
|
||
_option_v__ast__StructField v__ast__Table_find_field(v__ast__Table* t, v__ast__TypeSymbol* s, string name);
|
||
_option_multi_return_v__ast__StructField_Array_v__ast__Type v__ast__Table_find_field_from_embeds(v__ast__Table* t, v__ast__TypeSymbol* sym, string field_name);
|
||
_option_v__ast__StructField v__ast__Table_find_field_with_embeds(v__ast__Table* t, v__ast__TypeSymbol* sym, string field_name);
|
||
void v__ast__Table_resolve_common_sumtype_fields(v__ast__Table* t, v__ast__TypeSymbol* sym_);
|
||
int v__ast__Table_find_type_idx(v__ast__Table* t, string name);
|
||
_option_v__ast__TypeSymbol_ptr v__ast__Table_find_sym(v__ast__Table* t, string name);
|
||
multi_return_ref_v__ast__TypeSymbol_int v__ast__Table_find_sym_and_type_idx(v__ast__Table* t, string name);
|
||
v__ast__TypeSymbol* v__ast__Table_sym_by_idx(v__ast__Table* t, int idx);
|
||
v__ast__TypeSymbol* v__ast__Table_sym(v__ast__Table* t, v__ast__Type typ);
|
||
v__ast__TypeSymbol* v__ast__Table_final_sym(v__ast__Table* t, v__ast__Type typ);
|
||
string v__ast__Table_get_type_name(v__ast__Table* t, v__ast__Type typ);
|
||
v__ast__Type v__ast__Table_unalias_num_type(v__ast__Table* t, v__ast__Type typ);
|
||
v__ast__Type v__ast__Table_unaliased_type(v__ast__Table* t, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL int v__ast__Table_rewrite_already_registered_symbol(v__ast__Table* t, v__ast__TypeSymbol typ, int existing_idx);
|
||
int v__ast__Table_register_sym(v__ast__Table* t, v__ast__TypeSymbol sym);
|
||
void v__ast__Table_register_enum_decl(v__ast__Table* t, v__ast__EnumDecl enum_decl);
|
||
bool v__ast__Table_known_type(v__ast__Table* t, string name);
|
||
void v__ast__Table_start_parsing_type(v__ast__Table* t, string type_name);
|
||
void v__ast__Table_reset_parsing_type(v__ast__Table* t);
|
||
bool v__ast__Table_known_type_idx(v__ast__Table* t, v__ast__Type typ);
|
||
string v__ast__Table_array_name(v__ast__Table* t, v__ast__Type elem_type);
|
||
string v__ast__Table_array_cname(v__ast__Table* t, v__ast__Type elem_type);
|
||
string v__ast__Table_array_fixed_name(v__ast__Table* t, v__ast__Type elem_type, int size, v__ast__Expr size_expr);
|
||
string v__ast__Table_array_fixed_cname(v__ast__Table* t, v__ast__Type elem_type, int size);
|
||
string v__ast__Table_chan_name(v__ast__Table* t, v__ast__Type elem_type, bool is_mut);
|
||
string v__ast__Table_chan_cname(v__ast__Table* t, v__ast__Type elem_type, bool is_mut);
|
||
string v__ast__Table_promise_name(v__ast__Table* t, v__ast__Type return_type);
|
||
string v__ast__Table_promise_cname(v__ast__Table* t, v__ast__Type return_type);
|
||
string v__ast__Table_thread_name(v__ast__Table* t, v__ast__Type return_type);
|
||
string v__ast__Table_thread_cname(v__ast__Table* t, v__ast__Type return_type);
|
||
string v__ast__Table_map_name(v__ast__Table* t, v__ast__Type key_type, v__ast__Type value_type);
|
||
string v__ast__Table_map_cname(v__ast__Table* t, v__ast__Type key_type, v__ast__Type value_type);
|
||
int v__ast__Table_find_or_register_chan(v__ast__Table* t, v__ast__Type elem_type, bool is_mut);
|
||
int v__ast__Table_find_or_register_map(v__ast__Table* t, v__ast__Type key_type, v__ast__Type value_type);
|
||
int v__ast__Table_find_or_register_thread(v__ast__Table* t, v__ast__Type return_type);
|
||
int v__ast__Table_find_or_register_promise(v__ast__Table* t, v__ast__Type return_type);
|
||
int v__ast__Table_find_or_register_array(v__ast__Table* t, v__ast__Type elem_type);
|
||
int v__ast__Table_find_or_register_array_with_dims(v__ast__Table* t, v__ast__Type elem_type, int nr_dims);
|
||
int v__ast__Table_find_or_register_array_fixed(v__ast__Table* t, v__ast__Type elem_type, int size, v__ast__Expr size_expr);
|
||
int v__ast__Table_find_or_register_multi_return(v__ast__Table* t, Array_v__ast__Type mr_typs);
|
||
int v__ast__Table_find_or_register_fn_type(v__ast__Table* t, string mod, v__ast__Fn f, bool is_anon, bool has_decl);
|
||
int v__ast__Table_add_placeholder_type(v__ast__Table* t, string name, v__ast__Language language);
|
||
v__ast__Type v__ast__Table_value_type(v__ast__Table* t, v__ast__Type typ);
|
||
void v__ast__Table_register_fn_generic_types(v__ast__Table* t, string fn_name);
|
||
bool v__ast__Table_register_fn_concrete_types(v__ast__Table* t, string fn_name, Array_v__ast__Type types);
|
||
bool v__ast__Table_sumtype_has_variant(v__ast__Table* t, v__ast__Type parent, v__ast__Type variant, bool is_as);
|
||
VV_LOCAL_SYMBOL bool v__ast__Table_sumtype_check_variant_in_type(v__ast__Table* t, v__ast__SumType parent_info, v__ast__Type variant, bool is_as);
|
||
VV_LOCAL_SYMBOL bool v__ast__Table_sumtype_check_aggregate_variant(v__ast__Table* t, v__ast__Type parent_type, v__ast__Type* aggregate_type, bool is_as);
|
||
VV_LOCAL_SYMBOL bool v__ast__Table_sumtype_check_alias_variant(v__ast__Table* t, v__ast__Type parent_type, v__ast__Type alias_type, bool is_as);
|
||
bool v__ast__Table_is_sumtype_or_in_variant(v__ast__Table* t, v__ast__Type parent, v__ast__Type typ);
|
||
Array_string v__ast__Table_known_type_names(v__ast__Table* t);
|
||
bool v__ast__Table_has_deep_child_no_ref(v__ast__Table* t, v__ast__TypeSymbol* ts, string name);
|
||
void v__ast__Table_complete_interface_check(v__ast__Table* t);
|
||
v__ast__Type v__ast__Table_bitsize_to_type(v__ast__Table* t, int bit_size);
|
||
bool v__ast__Table_does_type_implement_interface(v__ast__Table* t, v__ast__Type typ, v__ast__Type inter_typ);
|
||
_option_v__ast__Type v__ast__Table_resolve_generic_to_concrete(v__ast__Table* t, v__ast__Type generic_type, Array_string generic_names, Array_v__ast__Type concrete_types);
|
||
v__ast__Type v__ast__Table_unwrap_generic_type(v__ast__Table* t, v__ast__Type typ, Array_string generic_names, Array_v__ast__Type concrete_types);
|
||
void v__ast__Table_replace_generic_type(v__ast__Table* t, v__ast__Type typ, Array_v__ast__Type generic_types);
|
||
void v__ast__Table_generic_insts_to_concrete(v__ast__Table* t);
|
||
bool v__ast__Table_is_comptime_type(v__ast__Table* t, v__ast__Type x, v__ast__ComptimeType y);
|
||
Array_string v__ast__Table_dependent_names_in_expr(v__ast__Table* t, v__ast__Expr expr);
|
||
Array_string v__ast__Table_dependent_names_in_stmt(v__ast__Table* t, v__ast__Stmt stmt);
|
||
v__ast__Language v__ast__pref_arch_to_table_language(v__pref__Arch pref_arch);
|
||
string v__ast__ShareType_str(v__ast__ShareType t);
|
||
string v__ast__Type_atomic_typename(v__ast__Type t);
|
||
v__ast__ShareType v__ast__sharetype_from_flags(bool is_shared, bool is_atomic);
|
||
v__ast__ShareType v__ast__Type_share(v__ast__Type t);
|
||
int v__ast__Type_idx(v__ast__Type t);
|
||
bool v__ast__Type_is_void(v__ast__Type t);
|
||
bool v__ast__Type_is_full(v__ast__Type t);
|
||
int v__ast__Type_nr_muls(v__ast__Type t);
|
||
bool v__ast__Type_is_ptr(v__ast__Type t);
|
||
bool v__ast__Type_is_any_kind_of_pointer(v__ast__Type t);
|
||
v__ast__Type v__ast__Type_set_nr_muls(v__ast__Type t, int nr_muls);
|
||
v__ast__Type v__ast__Type_ref(v__ast__Type t);
|
||
v__ast__Type v__ast__Type_deref(v__ast__Type t);
|
||
v__ast__Type v__ast__Type_set_flag(v__ast__Type t, v__ast__TypeFlag flag);
|
||
v__ast__Type v__ast__Type_clear_flag(v__ast__Type t, v__ast__TypeFlag flag);
|
||
v__ast__Type v__ast__Type_clear_flags(v__ast__Type t);
|
||
bool v__ast__Type_has_flag(v__ast__Type t, v__ast__TypeFlag flag);
|
||
Array_string v__ast__TypeSymbol_debug(v__ast__TypeSymbol* ts);
|
||
Array_string v__ast__TypeSymbol_dbg(v__ast__TypeSymbol* ts);
|
||
VV_LOCAL_SYMBOL void v__ast__TypeSymbol_dbg_common(v__ast__TypeSymbol* ts, Array_string* res);
|
||
string v__ast__Type_str(v__ast__Type t);
|
||
string v__ast__Table_type_str(v__ast__Table* t, v__ast__Type typ);
|
||
Array_string v__ast__Type_debug(v__ast__Type t);
|
||
v__ast__Type v__ast__Type_derive(v__ast__Type t, v__ast__Type t_from);
|
||
v__ast__Type v__ast__Type_derive_add_muls(v__ast__Type t, v__ast__Type t_from);
|
||
v__ast__Type v__ast__new_type(int idx);
|
||
v__ast__Type v__ast__new_type_ptr(int idx, int nr_muls);
|
||
bool v__ast__Type_is_pointer(v__ast__Type typ);
|
||
bool v__ast__Type_is_real_pointer(v__ast__Type typ);
|
||
bool v__ast__Type_is_float(v__ast__Type typ);
|
||
bool v__ast__Type_is_int(v__ast__Type typ);
|
||
bool v__ast__Type_is_int_valptr(v__ast__Type typ);
|
||
bool v__ast__Type_is_float_valptr(v__ast__Type typ);
|
||
bool v__ast__Type_is_pure_int(v__ast__Type typ);
|
||
bool v__ast__Type_is_pure_float(v__ast__Type typ);
|
||
bool v__ast__Type_is_signed(v__ast__Type typ);
|
||
bool v__ast__Type_is_unsigned(v__ast__Type typ);
|
||
v__ast__Type v__ast__Type_flip_signedness(v__ast__Type typ);
|
||
bool v__ast__Type_is_int_literal(v__ast__Type typ);
|
||
bool v__ast__Type_is_number(v__ast__Type typ);
|
||
bool v__ast__Type_is_string(v__ast__Type typ);
|
||
bool v__ast__Type_is_bool(v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL Array_v__ast__Type v__ast__new_charptr_types(void);
|
||
VV_LOCAL_SYMBOL Array_v__ast__Type v__ast__new_byteptr_types(void);
|
||
VV_LOCAL_SYMBOL Array_v__ast__Type v__ast__new_voidptr_types(void);
|
||
Array_v__ast__Type v__ast__merge_types(Array_Array_v__ast__Type params);
|
||
v__ast__Type v__ast__mktyp(v__ast__Type typ);
|
||
v__ast__Kind v__ast__Table_type_kind(v__ast__Table* t, v__ast__Type typ);
|
||
bool v__ast__Table_type_is_for_pointer_arithmetic(v__ast__Table* t, v__ast__Type typ);
|
||
string v__ast__TypeSymbol_str(v__ast__TypeSymbol* t);
|
||
VV_LOCAL_SYMBOL void v__ast__TypeSymbol_no_info_panic(v__ast__TypeSymbol* t, string fname);
|
||
v__ast__Enum v__ast__TypeSymbol_enum_info(v__ast__TypeSymbol* t);
|
||
v__ast__MultiReturn v__ast__TypeSymbol_mr_info(v__ast__TypeSymbol* t);
|
||
v__ast__Array v__ast__TypeSymbol_array_info(v__ast__TypeSymbol* t);
|
||
v__ast__ArrayFixed v__ast__TypeSymbol_array_fixed_info(v__ast__TypeSymbol* t);
|
||
v__ast__Chan v__ast__TypeSymbol_chan_info(v__ast__TypeSymbol* t);
|
||
v__ast__Thread v__ast__TypeSymbol_thread_info(v__ast__TypeSymbol* t);
|
||
v__ast__Map v__ast__TypeSymbol_map_info(v__ast__TypeSymbol* t);
|
||
v__ast__Struct v__ast__TypeSymbol_struct_info(v__ast__TypeSymbol* t);
|
||
v__ast__SumType v__ast__TypeSymbol_sumtype_info(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_heap(v__ast__TypeSymbol* t);
|
||
void v__ast__Table_register_builtin_type_symbols(v__ast__Table* t);
|
||
bool v__ast__TypeSymbol_is_pointer(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_int(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_float(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_string(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_number(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_primitive(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_is_builtin(v__ast__TypeSymbol* t);
|
||
multi_return_int_int v__ast__Table_type_size(v__ast__Table* t, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL int v__ast__round_up(int n, int multiple);
|
||
string v__ast__Kind_str(v__ast__Kind k);
|
||
string Array_v__ast__Kind_str(Array_v__ast__Kind kinds);
|
||
string v__ast__Table_type_to_str(v__ast__Table* t, v__ast__Type typ);
|
||
string v__ast__Table_type_to_code(v__ast__Table* mytable, v__ast__Type t);
|
||
string v__ast__Table_clean_generics_type_str(v__ast__Table* t, v__ast__Type typ);
|
||
string v__ast__Table_type_to_str_using_aliases(v__ast__Table* t, v__ast__Type typ, Map_string_string import_aliases);
|
||
VV_LOCAL_SYMBOL string v__ast__Table_shorten_user_defined_typenames(v__ast__Table* t, string originalname, Map_string_string import_aliases);
|
||
string v__ast__Table_fn_signature(v__ast__Table* t, v__ast__Fn* func, v__ast__FnSignatureOpts opts);
|
||
string v__ast__Table_fn_signature_using_aliases(v__ast__Table* t, v__ast__Fn* func, Map_string_string import_aliases, v__ast__FnSignatureOpts opts);
|
||
string v__ast__TypeSymbol_symbol_name_except_generic(v__ast__TypeSymbol* t);
|
||
string v__ast__TypeSymbol_embed_name(v__ast__TypeSymbol* t);
|
||
bool v__ast__TypeSymbol_has_method(v__ast__TypeSymbol* t, string name);
|
||
bool v__ast__TypeSymbol_has_method_with_generic_parent(v__ast__TypeSymbol* t, string name);
|
||
_option_v__ast__Fn v__ast__TypeSymbol_find_method(v__ast__TypeSymbol* t, string name);
|
||
_option_v__ast__Fn v__ast__TypeSymbol_find_method_with_generic_parent(v__ast__TypeSymbol* t, string name);
|
||
bool v__ast__TypeSymbol_is_js_compatible(v__ast__TypeSymbol* t);
|
||
multi_return_bool_bool_int v__ast__TypeSymbol_str_method_info(v__ast__TypeSymbol* t);
|
||
_option_v__ast__StructField v__ast__TypeSymbol_find_field(v__ast__TypeSymbol* t, string name);
|
||
VV_LOCAL_SYMBOL _option_v__ast__StructField v__ast__Aggregate_find_field(v__ast__Aggregate* a, string name);
|
||
_option_v__ast__StructField v__ast__Interface_find_field(v__ast__Interface* i, string name);
|
||
_option_v__ast__Fn v__ast__Interface_find_method(v__ast__Interface* i, string name);
|
||
bool v__ast__Interface_has_method(v__ast__Interface* i, string name);
|
||
_option_v__ast__StructField v__ast__Struct_find_field(v__ast__Struct* s, string name);
|
||
v__ast__StructField v__ast__Struct_get_field(v__ast__Struct* s, string name);
|
||
_option_v__ast__StructField v__ast__SumType_find_field(v__ast__SumType* s, string name);
|
||
bool v__ast__Interface_defines_method(v__ast__Interface* i, string name);
|
||
void v__checker__Checker_assign_stmt(v__checker__Checker* c, v__ast__AssignStmt* node);
|
||
bool v__checker__Checker_check_types(v__checker__Checker* c, v__ast__Type got, v__ast__Type expected);
|
||
_option_void v__checker__Checker_check_expected_call_arg(v__checker__Checker* c, v__ast__Type got, v__ast__Type expected_, v__ast__Language language, v__ast__CallArg arg);
|
||
VV_LOCAL_SYMBOL multi_return_string_string v__checker__Checker_get_string_names_of(v__checker__Checker _v_toheap_c, v__ast__Type got, v__ast__Type expected);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_check_same_module(v__checker__Checker _v_toheap_c, v__ast__Type got, v__ast__Type expected);
|
||
bool v__checker__Checker_check_basic(v__checker__Checker* c, v__ast__Type got, v__ast__Type expected);
|
||
bool v__checker__Checker_check_matching_function_symbols(v__checker__Checker* c, v__ast__TypeSymbol* got_type_sym, v__ast__TypeSymbol* exp_type_sym);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_check_shift(v__checker__Checker* c, v__ast__InfixExpr* node, v__ast__Type left_type, v__ast__Type right_type);
|
||
v__ast__Type v__checker__Checker_promote(v__checker__Checker* c, v__ast__Type left_type, v__ast__Type right_type);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_promote_num(v__checker__Checker* c, v__ast__Type left_type, v__ast__Type right_type);
|
||
_option_void v__checker__Checker_check_expected(v__checker__Checker* c, v__ast__Type got, v__ast__Type expected);
|
||
VV_LOCAL_SYMBOL string v__checker__Checker_expected_msg(v__checker__Checker* c, v__ast__Type got, v__ast__Type expected);
|
||
bool v__checker__Checker_symmetric_check(v__checker__Checker* c, v__ast__Type left, v__ast__Type right);
|
||
void v__checker__Checker_infer_fn_generic_types(v__checker__Checker* c, v__ast__Fn func, v__ast__CallExpr* node);
|
||
VV_LOCAL_SYMBOL Array_string v__checker__all_valid_comptime_idents(void);
|
||
v__checker__Checker* v__checker__new_checker(v__ast__Table* table, v__pref__Preferences* pref);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_reset_checker_state_at_start_of_new_file(v__checker__Checker* c);
|
||
void v__checker__Checker_check(v__checker__Checker* c, v__ast__File* ast_file_);
|
||
void v__checker__Checker_check_scope_vars(v__checker__Checker* c, v__ast__Scope* sc);
|
||
Array_v__errors__Error v__checker__Checker_check2(v__checker__Checker* c, v__ast__File* ast_file);
|
||
void v__checker__Checker_change_current_file(v__checker__Checker* c, v__ast__File* file);
|
||
void v__checker__Checker_check_files(v__checker__Checker* c, Array_v__ast__File_ptr ast_files);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_file_has_main_fn(v__checker__Checker* c, v__ast__File* file);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_valid_snake_case(v__checker__Checker* c, string name, string identifier, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL string v__checker__stripped_name(string name);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_valid_pascal_case(v__checker__Checker* c, string name, string identifier, v__token__Pos pos);
|
||
void v__checker__Checker_type_decl(v__checker__Checker* c, v__ast__TypeDecl node);
|
||
void v__checker__Checker_alias_type_decl(v__checker__Checker* c, v__ast__AliasTypeDecl node);
|
||
void v__checker__Checker_fn_type_decl(v__checker__Checker* c, v__ast__FnTypeDecl node);
|
||
void v__checker__Checker_sum_type_decl(v__checker__Checker* c, v__ast__SumTypeDecl node);
|
||
Array_v__ast__InterfaceEmbedding v__checker__Checker_expand_iface_embeds(v__checker__Checker* c, v__ast__InterfaceDecl* idecl, int level, Array_v__ast__InterfaceEmbedding iface_embeds);
|
||
VV_LOCAL_SYMBOL multi_return_string_v__token__Pos v__checker__Checker_fail_if_immutable(v__checker__Checker* c, v__ast__Expr expr_);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_type_implements(v__checker__Checker* c, v__ast__Type typ, v__ast__Type interface_type, v__token__Pos pos);
|
||
v__ast__Type v__checker__Checker_check_expr_opt_call(v__checker__Checker* c, v__ast__Expr expr, v__ast__Type ret_type);
|
||
void v__checker__Checker_check_or_expr(v__checker__Checker* c, v__ast__OrExpr node, v__ast__Type ret_type, v__ast__Type expr_return_type);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_or_last_stmt(v__checker__Checker* c, v__ast__Stmt stmt, v__ast__Type ret_type, v__ast__Type expr_return_type);
|
||
v__ast__Type v__checker__Checker_selector_expr(v__checker__Checker* c, v__ast__SelectorExpr* node);
|
||
void v__checker__Checker_const_decl(v__checker__Checker* c, v__ast__ConstDecl* node);
|
||
void v__checker__Checker_enum_decl(v__checker__Checker* c, v__ast__EnumDecl* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_loop_label(v__checker__Checker* c, string label, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_stmt(v__checker__Checker* c, v__ast__Stmt node_);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_assert_stmt(v__checker__Checker* c, v__ast__AssertStmt node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_block(v__checker__Checker* c, v__ast__Block node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_branch_stmt(v__checker__Checker* c, v__ast__BranchStmt node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_global_decl(v__checker__Checker* c, v__ast__GlobalDecl* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_asm_stmt(v__checker__Checker* c, v__ast__AsmStmt* stmt);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_asm_arg(v__checker__Checker* c, v__ast__AsmArg arg, v__ast__AsmStmt stmt, Array_string aliases);
|
||
VV_LOCAL_SYMBOL Array_string v__checker__Checker_asm_ios(v__checker__Checker* c, Array_v__ast__AsmIO ios, v__ast__Scope* scope, bool output);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_hash_stmt(v__checker__Checker* c, v__ast__HashStmt* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_import_stmt(v__checker__Checker* c, v__ast__Import node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_stmts(v__checker__Checker* c, Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_stmts_ending_with_expression(v__checker__Checker* c, Array_v__ast__Stmt stmts);
|
||
v__ast__Type v__checker__Checker_unwrap_generic(v__checker__Checker* c, v__ast__Type typ);
|
||
v__ast__Type v__checker__Checker_expr(v__checker__Checker* c, v__ast__Expr node_);
|
||
v__ast__Type v__checker__Checker_cast_expr(v__checker__Checker* c, v__ast__CastExpr* node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_at_expr(v__checker__Checker* c, v__ast__AtExpr* node);
|
||
v__ast__Type v__checker__Checker_ident(v__checker__Checker* c, v__ast__Ident* node);
|
||
v__ast__Type v__checker__Checker_concat_expr(v__checker__Checker* c, v__ast__ConcatExpr* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_smartcast(v__checker__Checker* c, v__ast__Expr expr_, v__ast__Type cur_type, v__ast__Type to_type_, v__ast__Scope* scope);
|
||
v__ast__Type v__checker__Checker_select_expr(v__checker__Checker* c, v__ast__SelectExpr* node);
|
||
v__ast__Type v__checker__Checker_lock_expr(v__checker__Checker* c, v__ast__LockExpr* node);
|
||
v__ast__Type v__checker__Checker_unsafe_expr(v__checker__Checker* c, v__ast__UnsafeExpr* node);
|
||
VV_LOCAL_SYMBOL _option_v__ast__Expr v__checker__Checker_find_definition(v__checker__Checker* c, v__ast__Ident ident);
|
||
VV_LOCAL_SYMBOL _option_v__ast__Expr v__checker__Checker_find_obj_definition(v__checker__Checker* c, v__ast__ScopeObject obj);
|
||
VV_LOCAL_SYMBOL _option_bool v__checker__Checker_has_return(v__checker__Checker* c, Array_v__ast__Stmt stmts);
|
||
v__ast__Type v__checker__Checker_postfix_expr(v__checker__Checker* c, v__ast__PostfixExpr* node);
|
||
void v__checker__Checker_mark_as_referenced(v__checker__Checker* c, v__ast__Expr* node, bool as_interface);
|
||
string v__checker__Checker_get_base_name(v__checker__Checker* c, v__ast__Expr* node);
|
||
v__ast__Type v__checker__Checker_prefix_expr(v__checker__Checker* c, v__ast__PrefixExpr* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_index(v__checker__Checker* c, v__ast__TypeSymbol* typ_sym, v__ast__Expr index, v__ast__Type index_type, v__token__Pos pos, bool range_index, bool is_gated);
|
||
v__ast__Type v__checker__Checker_index_expr(v__checker__Checker* c, v__ast__IndexExpr* node);
|
||
v__ast__Type v__checker__Checker_enum_val(v__checker__Checker* c, v__ast__EnumVal* node);
|
||
v__ast__Type v__checker__Checker_chan_init(v__checker__Checker* c, v__ast__ChanInit* node);
|
||
v__ast__Type v__checker__Checker_offset_of(v__checker__Checker* c, v__ast__OffsetOf node);
|
||
void v__checker__Checker_check_dup_keys(v__checker__Checker* c, v__ast__MapInit* node, int i);
|
||
void v__checker__Checker_add_error_detail(v__checker__Checker* c, string s);
|
||
void v__checker__Checker_warn(v__checker__Checker* c, string s, v__token__Pos pos);
|
||
void v__checker__Checker_error(v__checker__Checker* c, string message, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_check_struct_signature(v__checker__Checker* c, v__ast__Struct from, v__ast__Struct to);
|
||
void v__checker__Checker_note(v__checker__Checker* c, string message, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_warn_or_error(v__checker__Checker* c, string message, v__token__Pos pos, bool warn);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_fileis(v__checker__Checker* c, string s);
|
||
VV_LOCAL_SYMBOL string v__checker__Checker_fetch_field_name(v__checker__Checker* c, v__ast__StructField field);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_trace(v__checker__Checker* c, string fbase, string message);
|
||
VV_LOCAL_SYMBOL _option_void v__checker__Checker_ensure_type_exists(v__checker__Checker* c, v__ast__Type typ, v__token__Pos pos);
|
||
void v__checker__Checker_fail_if_unreadable(v__checker__Checker* c, v__ast__Expr expr, v__ast__Type typ, string what);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_comptime_call(v__checker__Checker* c, v__ast__ComptimeCall* node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_comptime_selector(v__checker__Checker* c, v__ast__ComptimeSelector* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_comptime_for(v__checker__Checker* c, v__ast__ComptimeFor node);
|
||
VV_LOCAL_SYMBOL _option_v__ast__ComptTimeConstValue v__checker__Checker_eval_comptime_const_expr(v__checker__Checker* c, v__ast__Expr expr, int nlevel);
|
||
VV_LOCAL_SYMBOL multi_return_bool_int_int v__checker__Checker_verify_vweb_params_for_method(v__checker__Checker* c, v__ast__Fn node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_verify_all_vweb_routes(v__checker__Checker* c);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_evaluate_once_comptime_if_attribute(v__checker__Checker* c, v__ast__Attr* node);
|
||
VV_LOCAL_SYMBOL v__checker__ComptimeBranchSkipState v__checker__Checker_comptime_if_branch(v__checker__Checker* c, v__ast__Expr cond, v__token__Pos pos);
|
||
v__ast__Type v__checker__Checker_array_init(v__checker__Checker* c, v__ast__ArrayInit* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_array_init_para_type(v__checker__Checker* c, string para, v__ast__Expr expr, v__token__Pos pos);
|
||
void v__checker__Checker_ensure_sumtype_array_has_default_value(v__checker__Checker* c, v__ast__ArrayInit node);
|
||
v__ast__Type v__checker__Checker_map_init(v__checker__Checker* c, v__ast__MapInit* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_fn_decl(v__checker__Checker* c, v__ast__FnDecl* node);
|
||
VV_LOCAL_SYMBOL bool v__checker__Checker_check_same_type_ignoring_pointers(v__checker__Checker* c, v__ast__Type type_a, v__ast__Type type_b);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_anon_fn(v__checker__Checker* c, v__ast__AnonFn* node);
|
||
v__ast__Type v__checker__Checker_call_expr(v__checker__Checker* c, v__ast__CallExpr* node);
|
||
v__ast__Type v__checker__Checker_fn_call(v__checker__Checker* c, v__ast__CallExpr* node, bool* continue_check);
|
||
v__ast__Type v__checker__Checker_method_call(v__checker__Checker* c, v__ast__CallExpr* node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_go_expr(v__checker__Checker* c, v__ast__GoExpr* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_set_node_expected_arg_types(v__checker__Checker* c, v__ast__CallExpr* node, v__ast__Fn* func);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_deprecate_fnmethod(v__checker__Checker* c, string kind, string name, v__ast__Fn the_fn, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_deprecate(v__checker__Checker* c, string kind, string name, string deprecation_message, time__Time now, time__Time after_time, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL string v__checker__semicolonize(string main, string details);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_post_process_generic_fns(v__checker__Checker* c);
|
||
_option_void v__checker__Checker_check_expected_arg_count(v__checker__Checker* c, v__ast__CallExpr* node, v__ast__Fn* f);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_map_and_filter(v__checker__Checker* c, bool is_map, v__ast__Type elem_typ, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_map_builtin_method_call(v__checker__Checker* c, v__ast__CallExpr* node, v__ast__Type left_type, v__ast__TypeSymbol left_sym);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_array_builtin_method_call(v__checker__Checker* c, v__ast__CallExpr* node, v__ast__Type left_type, v__ast__TypeSymbol left_sym);
|
||
VV_LOCAL_SYMBOL void v__checker__scope_register_it(v__ast__Scope* s, v__token__Pos pos, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__checker__scope_register_a_b(v__ast__Scope* s, v__token__Pos pos, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_for_c_stmt(v__checker__Checker* c, v__ast__ForCStmt node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_for_in_stmt(v__checker__Checker* c, v__ast__ForInStmt* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_for_stmt(v__checker__Checker* c, v__ast__ForStmt* node);
|
||
v__ast__Type v__checker__Checker_if_expr(v__checker__Checker* c, v__ast__IfExpr* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_smartcast_if_conds(v__checker__Checker* c, v__ast__Expr node, v__ast__Scope* scope);
|
||
v__ast__Type v__checker__Checker_infix_expr(v__checker__Checker* c, v__ast__InfixExpr* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_div_mod_by_zero(v__checker__Checker* c, v__ast__Expr expr, v__token__Kind op_kind);
|
||
void v__checker__Checker_interface_decl(v__checker__Checker* c, v__ast__InterfaceDecl* node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_resolve_generic_interface(v__checker__Checker* c, v__ast__Type typ, v__ast__Type interface_type, v__token__Pos pos);
|
||
v__ast__Type v__checker__Checker_match_expr(v__checker__Checker* c, v__ast__MatchExpr* node);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_match_exprs(v__checker__Checker* c, v__ast__MatchExpr* node, v__ast__TypeSymbol cond_type_sym);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_sql_expr(v__checker__Checker* c, v__ast__SqlExpr* node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_sql_stmt(v__checker__Checker* c, v__ast__SqlStmt* node);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__checker__Checker_sql_stmt_line(v__checker__Checker* c, v__ast__SqlStmtLine* node);
|
||
VV_LOCAL_SYMBOL Array_v__ast__StructField v__checker__Checker_fetch_and_verify_orm_fields(v__checker__Checker* c, v__ast__Struct info, v__token__Pos pos, string table_name);
|
||
void v__checker__Checker_return_stmt(v__checker__Checker* c, v__ast__Return* node);
|
||
void v__checker__Checker_find_unreachable_statements_after_noreturn_calls(v__checker__Checker* c, Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL bool v__checker__has_top_return(Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL void v__checker__Checker_check_noreturn_fn_decl(v__checker__Checker* c, v__ast__FnDecl* node);
|
||
VV_LOCAL_SYMBOL bool v__checker__uses_return_stmt(Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL bool v__checker__is_noreturn_callexpr(v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL int v__checker__imin(int a, int b);
|
||
VV_LOCAL_SYMBOL int v__checker__imax(int a, int b);
|
||
u8 v__checker__Checker_get_default_fmt(v__checker__Checker* c, v__ast__Type ftyp, v__ast__Type typ);
|
||
v__ast__Type v__checker__Checker_string_inter_lit(v__checker__Checker* c, v__ast__StringInterLiteral* node);
|
||
v__ast__Type v__checker__Checker_string_lit(v__checker__Checker* c, v__ast__StringLiteral* node);
|
||
v__ast__Type v__checker__Checker_int_lit(v__checker__Checker* c, v__ast__IntegerLiteral* node);
|
||
void v__checker__Checker_struct_decl(v__checker__Checker* c, v__ast__StructDecl* node);
|
||
VV_LOCAL_SYMBOL int v__checker__minify_sort_fn(v__ast__StructField* a, v__ast__StructField* b);
|
||
v__ast__Type v__checker__Checker_struct_init(v__checker__Checker* c, v__ast__StructInit* node);
|
||
VV_LOCAL_SYMBOL int compare_6602916910409314308_v__ast__StructField_by_i(v__ast__StructField* a, v__ast__StructField* b) {
|
||
if (a->i < b->i) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL bool v__transformer__IndexState_safe_access(v__transformer__IndexState* i, string key, int _v_new);
|
||
VV_LOCAL_SYMBOL int v__transformer__IndexState_safe_offset(v__transformer__IndexState* i, string key);
|
||
VV_LOCAL_SYMBOL void v__transformer__IndexState_indent(v__transformer__IndexState* i, bool is_function);
|
||
VV_LOCAL_SYMBOL void v__transformer__IndexState_unindent(v__transformer__IndexState* i);
|
||
v__transformer__Transformer* v__transformer__new_transformer(v__pref__Preferences* pref);
|
||
v__transformer__Transformer* v__transformer__new_transformer_with_table(v__ast__Table* table, v__pref__Preferences* pref);
|
||
void v__transformer__Transformer_transform_files(v__transformer__Transformer* t, Array_v__ast__File_ptr ast_files);
|
||
void v__transformer__Transformer_transform(v__transformer__Transformer* t, v__ast__File* ast_file);
|
||
void v__transformer__Transformer_find_new_array_len(v__transformer__Transformer* t, v__ast__AssignStmt node);
|
||
void v__transformer__Transformer_find_new_range(v__transformer__Transformer* t, v__ast__AssignStmt node);
|
||
void v__transformer__Transformer_find_mut_self_assign(v__transformer__Transformer* t, v__ast__AssignStmt node);
|
||
void v__transformer__Transformer_check_safe_array(v__transformer__Transformer* t, v__ast__IndexExpr* node);
|
||
v__ast__Stmt v__transformer__Transformer_stmt(v__transformer__Transformer* t, v__ast__Stmt* node);
|
||
v__ast__Stmt v__transformer__Transformer_assert_stmt(v__transformer__Transformer* t, v__ast__AssertStmt* node);
|
||
v__ast__Expr v__transformer__Transformer_expr_stmt_if_expr(v__transformer__Transformer* t, v__ast__IfExpr* node);
|
||
v__ast__Expr v__transformer__Transformer_expr_stmt_match_expr(v__transformer__Transformer* t, v__ast__MatchExpr* node);
|
||
v__ast__Stmt v__transformer__Transformer_for_c_stmt(v__transformer__Transformer* t, v__ast__ForCStmt* node);
|
||
v__ast__Stmt v__transformer__Transformer_for_stmt(v__transformer__Transformer* t, v__ast__ForStmt* node);
|
||
v__ast__Stmt v__transformer__Transformer_interface_decl(v__transformer__Transformer* t, v__ast__InterfaceDecl* node);
|
||
v__ast__Expr v__transformer__Transformer_expr(v__transformer__Transformer* t, v__ast__Expr* node);
|
||
v__ast__Expr v__transformer__Transformer_call_expr(v__transformer__Transformer* t, v__ast__CallExpr* node);
|
||
v__ast__Expr v__transformer__Transformer_infix_expr(v__transformer__Transformer* t, v__ast__InfixExpr* node);
|
||
v__ast__Expr v__transformer__Transformer_if_expr(v__transformer__Transformer* t, v__ast__IfExpr* node);
|
||
v__ast__Expr v__transformer__Transformer_match_expr(v__transformer__Transformer* t, v__ast__MatchExpr* node);
|
||
v__ast__Expr v__transformer__Transformer_sql_expr(v__transformer__Transformer* t, v__ast__SqlExpr* node);
|
||
void v__markused__mark_used(v__ast__Table* table, v__pref__Preferences* pref, Array_v__ast__File_ptr ast_files);
|
||
VV_LOCAL_SYMBOL multi_return_Map_string_v__ast__FnDecl_Map_string_v__ast__ConstField_Map_string_v__ast__GlobalField v__markused__all_fn_const_and_global(Array_v__ast__File_ptr ast_files);
|
||
void v__markused__Walker_mark_fn_as_used(v__markused__Walker* w, string fkey);
|
||
void v__markused__Walker_mark_const_as_used(v__markused__Walker* w, string ckey);
|
||
void v__markused__Walker_mark_global_as_used(v__markused__Walker* w, string ckey);
|
||
void v__markused__Walker_mark_root_fns(v__markused__Walker* w, Array_string all_fn_root_names);
|
||
void v__markused__Walker_mark_exported_fns(v__markused__Walker* w);
|
||
void v__markused__Walker_mark_markused_fns(v__markused__Walker* w);
|
||
void v__markused__Walker_mark_markused_consts(v__markused__Walker* w);
|
||
void v__markused__Walker_mark_markused_globals(v__markused__Walker* w);
|
||
void v__markused__Walker_stmt(v__markused__Walker* w, v__ast__Stmt node_);
|
||
VV_LOCAL_SYMBOL void v__markused__Walker_asm_io(v__markused__Walker* w, Array_v__ast__AsmIO ios);
|
||
VV_LOCAL_SYMBOL void v__markused__Walker_defer_stmts(v__markused__Walker* w, Array_v__ast__DeferStmt stmts);
|
||
VV_LOCAL_SYMBOL void v__markused__Walker_stmts(v__markused__Walker* w, Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL void v__markused__Walker_exprs(v__markused__Walker* w, Array_v__ast__Expr exprs);
|
||
VV_LOCAL_SYMBOL void v__markused__Walker_expr(v__markused__Walker* w, v__ast__Expr node_);
|
||
void v__markused__Walker_fn_decl(v__markused__Walker* w, v__ast__FnDecl* node);
|
||
void v__markused__Walker_call_expr(v__markused__Walker* w, v__ast__CallExpr* node);
|
||
void v__markused__Walker_fn_by_name(v__markused__Walker* w, string fn_name);
|
||
void v__markused__Walker_struct_fields(v__markused__Walker* w, Array_v__ast__StructField sfields);
|
||
void v__markused__Walker_const_fields(v__markused__Walker* w, Array_v__ast__ConstField cfields);
|
||
void v__markused__Walker_or_block(v__markused__Walker* w, v__ast__OrExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_array_init(v__gen__c__Gen* g, v__ast__ArrayInit node, string var_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_fixed_array_init(v__gen__c__Gen* g, v__ast__ArrayInit node, v__gen__c__Type array_type, string var_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_array_init_with_fields(v__gen__c__Gen* g, v__ast__ArrayInit node, v__gen__c__Type elem_type, bool is_amp, string shared_styp, string var_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_map(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_sort(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_sort_call(v__gen__c__Gen* g, v__ast__CallExpr node, string compare_fn);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_filter(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_insert(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_prepend(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_array_contains_method(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_contains_methods(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_contains(v__gen__c__Gen* g, v__ast__Type typ, v__ast__Expr left, v__ast__Expr right);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_array_index_method(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_index_methods(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_index(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_wait(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_any(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_array_all(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_assert_stmt(v__gen__c__Gen* g, v__ast__AssertStmt original_assert_statement);
|
||
VV_LOCAL_SYMBOL _option_v__ast__Expr v__gen__c__Gen_assert_subexpression_to_ctemp(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type expr_type);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_assert_postfailure_mode(v__gen__c__Gen* g, v__ast__AssertStmt node);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_assert_metainfo(v__gen__c__Gen* g, v__ast__AssertStmt node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_assert_single_expr(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_assign_stmt(v__gen__c__Gen* g, v__ast__AssignStmt node_);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_multi_return_assign(v__gen__c__Gen* g, v__ast__AssignStmt* node, v__ast__Type return_type);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_assign_vars_autofree(v__gen__c__Gen* g, v__ast__AssignStmt* node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_cross_var_assign(v__gen__c__Gen* g, v__ast__AssignStmt* node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_cross_tmp_variable(v__gen__c__Gen* g, Array_v__ast__Expr left, v__ast__Expr val);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_equality_fn(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_equality_fns(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_sumtype_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_struct_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_alias_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_array_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_fixed_array_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_map_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_interface_equality_fn(v__gen__c__Gen* g, v__ast__Type left_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_free_method(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_free_methods(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_gen_free_method(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_free_for_struct(v__gen__c__Gen* g, v__ast__Struct info, string styp, string fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_free_for_array(v__gen__c__Gen* g, v__ast__Array info, string styp, string fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_free_for_map(v__gen__c__Gen* g, v__ast__Map info, string styp, string fn_name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__styp_to_free_fn_name(string styp);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_default(v__gen__c__Gen* g, v__ast__TypeSymbol sym, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_str_fn(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_final_gen_str(v__gen__c__Gen* g, v__gen__c__StrType typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_option(v__gen__c__Gen* g, v__ast__Type typ, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_result(v__gen__c__Gen* g, v__ast__Type typ, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_alias(v__gen__c__Gen* g, v__ast__Alias info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_multi_return(v__gen__c__Gen* g, v__ast__MultiReturn info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_enum(v__gen__c__Gen* g, v__ast__Enum info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_interface(v__gen__c__Gen* g, v__ast__Interface info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_union_sum_type(v__gen__c__Gen* g, v__ast__SumType info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_fn_decl_str(v__gen__c__Gen* g, v__ast__FnType info);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_fn_type(v__gen__c__Gen* g, v__ast__FnType info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_chan(v__gen__c__Gen* g, v__ast__Chan info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_thread(v__gen__c__Gen* g, v__ast__Thread info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__styp_to_str_fn_name(string styp);
|
||
VV_LOCAL_SYMBOL multi_return_string_string v__gen__c__deref_kind(bool str_method_expects_ptr, bool is_elem_ptr, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_array(v__gen__c__Gen* g, v__ast__Array info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_array_fixed(v__gen__c__Gen* g, v__ast__ArrayFixed info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_map(v__gen__c__Gen* g, v__ast__Map info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL StrIntpType v__gen__c__Gen_type_to_fmt(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_str_for_struct(v__gen__c__Gen* g, v__ast__Struct info, string styp, string str_fn_name);
|
||
VV_LOCAL_SYMBOL multi_return_string_bool v__gen__c__struct_auto_str_func(v__ast__TypeSymbol* sym, v__ast__Type _field_type, string fn_name, string field_name, bool has_custom_str, bool expects_ptr);
|
||
VV_LOCAL_SYMBOL string v__gen__c__data_str(StrIntpType x);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__should_use_indent_func(v__ast__Kind kind);
|
||
VV_LOCAL_SYMBOL Map_string_bool v__gen__c__string_array_to_map(Array_string a);
|
||
string v__gen__c__gen(Array_v__ast__File_ptr files, v__ast__Table* table, v__pref__Preferences* pref);
|
||
VV_LOCAL_SYMBOL v__gen__c__Gen* v__gen__c__cgen_process_one_file_cb(sync__pool__PoolProcessor* p, int idx, int wid);
|
||
void v__gen__c__Gen_free_builders(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_gen_file(v__gen__c__Gen* g);
|
||
string v__gen__c__Gen_hashes(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_init(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_finish(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_write_typeof_functions(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_typ(v__gen__c__Gen* g, v__ast__Type t);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_base_type(v__gen__c__Gen* g, v__ast__Type _t);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_generic_fn_name(v__gen__c__Gen* g, Array_v__ast__Type types, string before, bool is_decl);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_expr_string(v__gen__c__Gen* g, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_expr_string_with_cast(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type typ, v__ast__Type exp);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_expr_string_surround(v__gen__c__Gen* g, string prepend, v__ast__Expr expr, string append);
|
||
VV_LOCAL_SYMBOL multi_return_string_string v__gen__c__Gen_optional_type_name(v__gen__c__Gen* g, v__ast__Type t);
|
||
VV_LOCAL_SYMBOL multi_return_string_string v__gen__c__Gen_result_type_name(v__gen__c__Gen* g, v__ast__Type t);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_optional_type_text(v__gen__c__Gen* g, string styp, string base);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_result_type_text(v__gen__c__Gen* g, string styp, string base);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_register_optional(v__gen__c__Gen* g, v__ast__Type t);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_register_result(v__gen__c__Gen* g, v__ast__Type t);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_optionals(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_results(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_find_or_register_shared(v__gen__c__Gen* g, v__ast__Type t, string base);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_shareds(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_register_thread_void_wait_call(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_register_thread_array_wait_call(v__gen__c__Gen* g, string eltyp);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_register_chan_pop_optional_call(v__gen__c__Gen* g, string opt_el_type, string styp);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_chan_pop_optional_fns(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_register_chan_push_optional_fn(v__gen__c__Gen* g, string el_type, string styp);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_chan_push_optional_fns(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_cc_type(v__gen__c__Gen* g, v__ast__Type typ, bool is_prefix_struct);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_type_sidx(v__gen__c__Gen* g, v__ast__Type t);
|
||
void v__gen__c__Gen_write_typedef_types(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_write_alias_typesymbol_declaration(v__gen__c__Gen* g, v__ast__TypeSymbol sym);
|
||
void v__gen__c__Gen_write_interface_typedef(v__gen__c__Gen* g, v__ast__TypeSymbol sym);
|
||
void v__gen__c__Gen_write_interface_typesymbol_declaration(v__gen__c__Gen* g, v__ast__TypeSymbol sym);
|
||
void v__gen__c__Gen_write_fn_typesymbol_declaration(v__gen__c__Gen* g, v__ast__TypeSymbol sym);
|
||
void v__gen__c__Gen_write_multi_return_types(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_write(v__gen__c__Gen* g, string s);
|
||
void v__gen__c__Gen_writeln(v__gen__c__Gen* g, string s);
|
||
string v__gen__c__Gen_new_tmp_var(v__gen__c__Gen* g);
|
||
string v__gen__c__Gen_new_global_tmp_var(v__gen__c__Gen* g);
|
||
string v__gen__c__Gen_new_tmp_declaration_name(v__gen__c__Gen* g);
|
||
string v__gen__c__Gen_current_tmp_var(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_reset_tmp_count(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_decrement_inside_ternary(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_stmts(v__gen__c__Gen* g, Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__is_noreturn_callexpr(v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_stmts_with_tmp_var(v__gen__c__Gen* g, Array_v__ast__Stmt stmts, string tmp_var);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_v_source_line_info(v__gen__c__Gen* g, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_stmt(v__gen__c__Gen* g, v__ast__Stmt node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_defer_stmts(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_sumtype_casting_fn(v__gen__c__Gen* g, v__ast__Type got_, v__ast__Type exp_);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_sumtype_casting_fn(v__gen__c__Gen* g, v__gen__c__SumtypeCastingFn fun);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_call_cfn_for_casting_expr(v__gen__c__Gen* g, string fname, v__ast__Expr expr, bool exp_is_ptr, string exp_styp, bool got_is_ptr, string got_styp);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_expr_with_cast(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type got_type_raw, v__ast__Type expected_type);
|
||
VV_LOCAL_SYMBOL void v__gen__c__write_octal_escape(strings__Builder* b, u8 c);
|
||
VV_LOCAL_SYMBOL string v__gen__c__cescape_nonascii(string original);
|
||
VV_LOCAL_SYMBOL string v__gen__c__cestring(string s);
|
||
VV_LOCAL_SYMBOL string v__gen__c__ctoslit(string s);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_attrs(v__gen__c__Gen* g, Array_v__ast__Attr attrs);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_asm_stmt(v__gen__c__Gen* g, v__ast__AsmStmt stmt);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_asm_arg(v__gen__c__Gen* g, v__ast__AsmArg arg, v__ast__AsmStmt stmt);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_asm_ios(v__gen__c__Gen* g, Array_v__ast__AsmIO ios);
|
||
VV_LOCAL_SYMBOL string v__gen__c__cnewlines(string s);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_fn_ptr_decl(v__gen__c__Gen* g, v__ast__FnType* func, string ptr_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_register_ternary_name(v__gen__c__Gen* g, string name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_ternary_name(v__gen__c__Gen* g, string name);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_gen_clone_assignment(v__gen__c__Gen* g, v__ast__Expr val, v__ast__Type typ, bool add_eq);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_scope_vars(v__gen__c__Gen* g, int pos, int line_nr, bool free_parent_scopes);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_scope_vars_stop(v__gen__c__Gen* g, int pos, int line_nr, bool free_parent_scopes, int stop_pos);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_scope_vars2(v__gen__c__Gen* g, v__ast__Scope* scope, int start_pos, int end_pos, int line_nr, bool free_parent_scopes, int stop_pos);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_variable(v__gen__c__Gen* g, v__ast__Var v);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_var_call(v__gen__c__Gen* g, string free_fn_name, v__ast__Var v);
|
||
VV_LOCAL_SYMBOL multi_return_string_string_string_string v__gen__c__Gen_map_fn_ptrs(v__gen__c__Gen* g, v__ast__TypeSymbol key_typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_expr(v__gen__c__Gen* g, v__ast__Expr node_);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_char_literal(v__gen__c__Gen* g, v__ast__CharLiteral node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_type_name(v__gen__c__Gen* g, v__ast__Type raw_type);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_typeof_expr(v__gen__c__Gen* g, v__ast__TypeOf node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_selector_expr(v__gen__c__Gen* g, v__ast__SelectorExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_enum_decl(v__gen__c__Gen* g, v__ast__EnumDecl node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_enum_expr(v__gen__c__Gen* g, v__ast__Expr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_lock_expr(v__gen__c__Gen* g, v__ast__LockExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_unlock_locks(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_map_init(v__gen__c__Gen* g, v__ast__MapInit node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_select_expr(v__gen__c__Gen* g, v__ast__SelectExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_ident(v__gen__c__Gen* g, v__ast__Ident node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_cast_expr(v__gen__c__Gen* g, v__ast__CastExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_concat_expr(v__gen__c__Gen* g, v__ast__ConcatExpr node);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_expr_is_multi_return_call(v__gen__c__Gen* g, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_result_error(v__gen__c__Gen* g, v__ast__Type target_type, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_optional_error(v__gen__c__Gen* g, v__ast__Type target_type, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_return_stmt(v__gen__c__Gen* g, v__ast__Return node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_const_decl(v__gen__c__Gen* g, v__ast__ConstDecl node);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_const_decl_precomputed(v__gen__c__Gen* g, string mod, string name, string field_name, v__ast__ComptTimeConstValue ct_value, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_const_decl_write_precomputed(v__gen__c__Gen* g, string mod, string styp, string cname, string field_name, string ct_value);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_const_decl_simple_define(v__gen__c__Gen* g, string mod, string name, string val);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_const_decl_init_later(v__gen__c__Gen* g, string mod, string name, v__ast__Expr expr, v__ast__Type typ, bool unwrap_option);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_global_decl(v__gen__c__Gen* g, v__ast__GlobalDecl node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_assoc(v__gen__c__Gen* g, v__ast__Assoc node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__verror(string s);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_error(v__gen__c__Gen* g, string s, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_checker_bug(v__gen__c__Gen* g, string s, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_init_function(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_builtin_types(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_sorted_types(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_types(v__gen__c__Gen* g, Array_v__ast__TypeSymbol_ptr symbols);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sort_globals_consts(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL Array_v__ast__TypeSymbol_ptr v__gen__c__Gen_sort_structs(v__gen__c__Gen* g, Array_v__ast__TypeSymbol_ptr typesa);
|
||
VV_LOCAL_SYMBOL int v__gen__c__Gen_nth_stmt_pos(v__gen__c__Gen* g, int n);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_set_current_pos_as_last_stmt_pos(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_go_before_stmt(v__gen__c__Gen* g, int n);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_go_before_ternary(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_insert_before_stmt(v__gen__c__Gen* g, string s);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_insert_at(v__gen__c__Gen* g, int pos, string s);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_or_block(v__gen__c__Gen* g, string var_name, v__ast__OrExpr or_block, v__ast__Type return_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__c_name(string name_);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_type_default(v__gen__c__Gen* g, v__ast__Type typ_);
|
||
VV_LOCAL_SYMBOL Array_string v__gen__c__Gen_get_all_test_function_names(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_size_of(v__gen__c__Gen* g, v__ast__SizeOf node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_enum_val(v__gen__c__Gen* g, v__ast__EnumVal node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_as_cast(v__gen__c__Gen* g, v__ast__AsCast node);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_as_cast_name_table(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_has_been_referenced(v__gen__c__Gen* g, string fn_name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_interface_table(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL multi_return_int_string_string_string v__gen__c__Gen_panic_debug_info(v__gen__c__Gen* g, v__token__Pos pos);
|
||
string v__gen__c__get_guarded_include_text(string iname, string imessage);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_trace(v__gen__c__Gen* g, string fbase, string message);
|
||
int v__gen__c__Gen_get_array_depth(v__gen__c__Gen* g, v__ast__Type el_typ);
|
||
bool v__gen__c__Gen_contains_ptr(v__gen__c__Gen* g, v__ast__Type el_typ);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_check_noscan(v__gen__c__Gen* g, v__ast__Type elem_typ);
|
||
VV_LOCAL_SYMBOL string v__gen__c__c_closure_helpers(v__pref__Preferences* pref);
|
||
void v__gen__c__Gen_gen_c_main(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_vlines_reset(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_c_main_function_only_header(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_c_main_function_header(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_c_main_header(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_gen_c_main_footer(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_gen_c_android_sokol_main(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_write_tests_definitions(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_gen_failing_error_propagation_for_test_fn(v__gen__c__Gen* g, v__ast__OrExpr or_block, string cvar_name);
|
||
void v__gen__c__Gen_gen_failing_return_error_for_test_fn(v__gen__c__Gen* g, v__ast__Return return_stmt, string cvar_name);
|
||
void v__gen__c__Gen_gen_c_main_profile_hook(v__gen__c__Gen* g);
|
||
void v__gen__c__Gen_gen_c_main_for_tests(v__gen__c__Gen* g);
|
||
Array_string v__gen__c__Gen_filter_only_matching_fn_names(v__gen__c__Gen* g, Array_string fnames);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_comptime_selector(v__gen__c__Gen* g, v__ast__ComptimeSelector node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_comptime_call(v__gen__c__Gen* g, v__ast__ComptimeCall* node);
|
||
VV_LOCAL_SYMBOL Array_string v__gen__c__cgen_attrs(Array_v__ast__Attr attrs);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_comptime_at(v__gen__c__Gen* g, v__ast__AtExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_comptime_if(v__gen__c__Gen* g, v__ast__IfExpr node);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_comptime_if_cond(v__gen__c__Gen* g, v__ast__Expr cond, bool pkg_exist);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_comptime_for(v__gen__c__Gen* g, v__ast__ComptimeFor node);
|
||
VV_LOCAL_SYMBOL _option_string v__gen__c__Gen_comptime_if_to_ifdef(v__gen__c__Gen* g, string name, bool is_comptime_optional);
|
||
VV_LOCAL_SYMBOL v__ast__CTempVar v__gen__c__Gen_new_ctemp_var(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type expr_type);
|
||
VV_LOCAL_SYMBOL v__ast__CTempVar v__gen__c__Gen_new_ctemp_var_then_gen(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type expr_type);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_ctemp_var(v__gen__c__Gen* g, v__ast__CTempVar tvar);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_dump_expr(v__gen__c__Gen* g, v__ast__DumpExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_dump_expr_definitions(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_writeln_fn_header(v__gen__c__Gen* g, string s, strings__Builder* sb);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_should_really_embed_file(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_handle_embedded_files_finish(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_embed_file_init(v__gen__c__Gen* g, v__ast__ComptimeCall* node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_embedded_metadata(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_embedded_data(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_is_used_by_main(v__gen__c__Gen* g, v__ast__FnDecl node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_fn_decl(v__gen__c__Gen* g, v__ast__FnDecl node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_fn_decl(v__gen__c__Gen* g, v__ast__FnDecl* node, bool skip);
|
||
VV_LOCAL_SYMBOL _option_string v__gen__c__Gen_c_fn_name(v__gen__c__Gen* g, v__ast__FnDecl* node);
|
||
VV_LOCAL_SYMBOL string v__gen__c__closure_ctx(v__ast__FnDecl node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_anon_fn(v__gen__c__Gen* g, v__ast__AnonFn* node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_anon_fn_decl(v__gen__c__Gen* g, v__ast__AnonFn* node);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_defer_flag_var(v__gen__c__Gen* g, v__ast__DeferStmt* stmt);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_write_defer_stmts_when_needed(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL multi_return_Array_string_Array_string_Array_bool v__gen__c__Gen_fn_decl_params(v__gen__c__Gen* g, Array_v__ast__Param params, v__ast__Scope* scope, bool is_variadic);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_anon_fn_type_name(v__gen__c__Gen* g, v__ast__AnonFn* node, string var_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_call_expr(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_conversion_function_call(v__gen__c__Gen* g, string prefix, string postfix, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_method_call(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_fn_call(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_call_pregen(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_autofree_call_postgen(v__gen__c__Gen* g, int node_pos);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_call_args(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_go_expr(v__gen__c__Gen* g, v__ast__GoExpr node);
|
||
VV_LOCAL_SYMBOL int v__gen__c__Gen_keep_alive_call_pregen(v__gen__c__Gen* g, v__ast__CallExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_keep_alive_call_postgen(v__gen__c__Gen* g, v__ast__CallExpr node, int tmp_cnt_save);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_ref_or_deref_arg(v__gen__c__Gen* g, v__ast__CallArg arg, v__ast__Type expected_type, v__ast__Language lang);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_is_gui_app(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_fileis(v__gen__c__Gen* g, string s);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_write_fn_attrs(v__gen__c__Gen* g, Array_v__ast__Attr attrs);
|
||
VV_LOCAL_SYMBOL string v__gen__c__call_convention_attribute(string cconvention, bool is_cc_msvc);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_for_c_stmt(v__gen__c__Gen* g, v__ast__ForCStmt node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_for_stmt(v__gen__c__Gen* g, v__ast__ForStmt node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_for_in_stmt(v__gen__c__Gen* g, v__ast__ForInStmt node);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_need_tmp_var_in_if(v__gen__c__Gen* g, v__ast__IfExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_if_expr(v__gen__c__Gen* g, v__ast__IfExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_index_expr(v__gen__c__Gen* g, v__ast__IndexExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_range_expr(v__gen__c__Gen* g, v__ast__IndexExpr node, v__ast__RangeExpr range);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_index_of_array(v__gen__c__Gen* g, v__ast__IndexExpr node, v__ast__TypeSymbol sym);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_index_of_fixed_array(v__gen__c__Gen* g, v__ast__IndexExpr node, v__ast__TypeSymbol sym);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_index_of_map(v__gen__c__Gen* g, v__ast__IndexExpr node, v__ast__TypeSymbol sym);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_arrow_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_eq_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_cmp_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_in_sumtype_interface_array(v__gen__c__Gen* g, Array_v__ast__InfixExpr infix_exprs);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_in_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_in_optimization(v__gen__c__Gen* g, v__ast__Expr left, v__ast__ArrayInit right);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_is_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_interface_is_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_arithmetic_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_left_shift_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_need_tmp_var_in_array_call(v__gen__c__Gen* g, v__ast__Expr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_infix_expr_and_or_op(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_plain_infix_expr(v__gen__c__Gen* g, v__ast__InfixExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_op_arg(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type expected, v__ast__Type got);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_safe_integer_infix_expr(v__gen__c__Gen* g, v__gen__c__GenSafeIntegerCfg cfg);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_json_for_type(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_jsons(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_sumtype_enc_dec(v__gen__c__Gen* g, v__ast__TypeSymbol sym, strings__Builder* enc, strings__Builder* dec);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_struct_enc_dec(v__gen__c__Gen* g, v__ast__TypeInfo type_info, string styp, strings__Builder* enc, strings__Builder* dec);
|
||
VV_LOCAL_SYMBOL void v__gen__c__gen_js_get(string styp, string tmp, string name, strings__Builder* dec, bool is_required);
|
||
VV_LOCAL_SYMBOL void v__gen__c__gen_js_get_opt(string dec_name, string field_type, string styp, string tmp, string name, strings__Builder* dec, bool is_required);
|
||
VV_LOCAL_SYMBOL string v__gen__c__js_enc_name(string typ);
|
||
VV_LOCAL_SYMBOL string v__gen__c__js_dec_name(string typ);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__is_js_prim(string typ);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_decode_array(v__gen__c__Gen* g, v__ast__Type value_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_encode_array(v__gen__c__Gen* g, v__ast__Type value_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_decode_map(v__gen__c__Gen* g, v__ast__Type key_type, v__ast__Type value_type);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_encode_map(v__gen__c__Gen* g, v__ast__Type key_type, v__ast__Type value_type);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_generate_hotcode_reloading_declarations(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_generate_hotcode_reloader_code(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_generate_hotcode_reloading_main_caller(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_need_tmp_var_in_match(v__gen__c__Gen* g, v__ast__MatchExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_match_expr(v__gen__c__Gen* g, v__ast__MatchExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_match_expr_sumtype(v__gen__c__Gen* g, v__ast__MatchExpr node, bool is_expr, string cond_var, string tmp_var);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_match_expr_switch(v__gen__c__Gen* g, v__ast__MatchExpr node, bool is_expr, string cond_var, string tmp_var, v__ast__TypeSymbol enum_typ);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_match_expr_classic(v__gen__c__Gen* g, v__ast__MatchExpr node, bool is_expr, string cond_var, string tmp_var);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_profile_fn(v__gen__c__Gen* g, v__ast__FnDecl fn_decl);
|
||
void v__gen__c__Gen_gen_vprint_profile_stats(v__gen__c__Gen* g);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_stmt(v__gen__c__Gen* g, v__ast__SqlStmt node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_stmt_line(v__gen__c__Gen* g, v__ast__SqlStmtLine nd, string expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_create_table(v__gen__c__Gen* g, v__ast__SqlStmtLine node, string expr, string table_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_insert(v__gen__c__Gen* g, v__ast__SqlStmtLine node, string expr, string table_name, string last_ids_arr, string res, string pid, bool is_array, string fkey);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_update(v__gen__c__Gen* g, v__ast__SqlStmtLine node, string expr, string table_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_delete(v__gen__c__Gen* g, v__ast__SqlStmtLine node, string expr, string table_name);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_expr_to_orm_primitive(v__gen__c__Gen* g, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_write_orm_primitive(v__gen__c__Gen* g, v__ast__Type t, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_where_data(v__gen__c__Gen* g, v__ast__Expr expr, Array_string* fields, Array_string* kinds, Array_v__ast__Expr* data, Array_bool* is_and);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_gen_where_data(v__gen__c__Gen* g, v__ast__Expr where_expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_select_expr(v__gen__c__Gen* g, v__ast__SqlExpr node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_sql_select(v__gen__c__Gen* g, v__ast__SqlExpr node, string expr, string left);
|
||
VV_LOCAL_SYMBOL v__gen__c__SqlType v__gen__c__Gen_parse_db_type(v__gen__c__Gen* g, v__ast__Expr expr);
|
||
VV_LOCAL_SYMBOL v__gen__c__SqlType v__gen__c__Gen_parse_db_from_type_string(v__gen__c__Gen* g, string name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_table_name(v__gen__c__Gen* g, v__ast__TypeNode table_expr);
|
||
VV_LOCAL_SYMBOL v__ast__StructField v__gen__c__Gen_get_struct_field(v__gen__c__Gen* g, string name);
|
||
VV_LOCAL_SYMBOL string v__gen__c__Gen_get_field_name(v__gen__c__Gen* g, v__ast__StructField field);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_string_literal(v__gen__c__Gen* g, v__ast__StringLiteral node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_string_inter_literal_sb_optimized(v__gen__c__Gen* g, v__ast__CallExpr call_expr);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_gen_expr_to_string(v__gen__c__Gen* g, v__ast__Expr expr, v__ast__Type etype);
|
||
VV_LOCAL_SYMBOL multi_return_u64_string v__gen__c__Gen_str_format(v__gen__c__Gen* g, v__ast__StringInterLiteral node, int i);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_str_val(v__gen__c__Gen* g, v__ast__StringInterLiteral node, int i);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_string_inter_literal(v__gen__c__Gen* g, v__ast__StringInterLiteral node);
|
||
VV_LOCAL_SYMBOL void v__gen__c__Gen_struct_init(v__gen__c__Gen* g, v__ast__StructInit node);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_zero_struct_field(v__gen__c__Gen* g, v__ast__StructField field);
|
||
VV_LOCAL_SYMBOL bool v__gen__c__Gen_is_empty_struct(v__gen__c__Gen* g, v__gen__c__Type t);
|
||
VV_LOCAL_SYMBOL v__ast__Type v__gen__c__Gen_unwrap_generic(v__gen__c__Gen* g, v__ast__Type typ);
|
||
VV_LOCAL_SYMBOL v__gen__c__Type v__gen__c__Gen_unwrap(v__gen__c__Gen* g, v__ast__Type typ);
|
||
_option_v__scanner__Scanner_ptr v__scanner__new_scanner_file(string file_path, v__scanner__CommentsMode comments_mode, v__pref__Preferences* pref);
|
||
v__scanner__Scanner* v__scanner__new_scanner(string text, v__scanner__CommentsMode comments_mode, v__pref__Preferences* pref);
|
||
void v__scanner__Scanner_free(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL bool v__scanner__Scanner_should_parse_comment(v__scanner__Scanner* s);
|
||
void v__scanner__Scanner_set_is_inside_toplevel_statement(v__scanner__Scanner* s, bool newstate);
|
||
void v__scanner__Scanner_set_current_tidx(v__scanner__Scanner* s, int cidx);
|
||
VV_LOCAL_SYMBOL v__token__Token v__scanner__Scanner_new_token(v__scanner__Scanner* s, v__token__Kind tok_kind, string lit, int len);
|
||
VV_LOCAL_SYMBOL v__token__Token v__scanner__Scanner_new_eof_token(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL v__token__Token v__scanner__Scanner_new_multiline_token(v__scanner__Scanner* s, v__token__Kind tok_kind, string lit, int len, int start_line);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_name(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_num_lit(v__scanner__Scanner* s, int start, int end);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_bin_number(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_hex_number(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_oct_number(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_dec_number(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_number(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_skip_whitespace(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL v__token__Token v__scanner__Scanner_end_of_file(v__scanner__Scanner* s);
|
||
void v__scanner__Scanner_scan_all_tokens_in_buffer(v__scanner__Scanner* s);
|
||
void v__scanner__Scanner_scan_remaining_text(v__scanner__Scanner* s);
|
||
v__token__Token v__scanner__Scanner_scan(v__scanner__Scanner* s);
|
||
v__token__Token v__scanner__Scanner_peek_token(v__scanner__Scanner* s, int n);
|
||
VV_LOCAL_SYMBOL u8 v__scanner__Scanner_look_ahead(v__scanner__Scanner* s, int n);
|
||
VV_LOCAL_SYMBOL v__token__Token v__scanner__Scanner_text_scan(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_invalid_character(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL int v__scanner__Scanner_current_column(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL int v__scanner__Scanner_count_symbol_before(v__scanner__Scanner* s, int p, u8 sym);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_string(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL string v__scanner__decode_h_escapes(string s, int start, Array_int escapes_pos);
|
||
VV_LOCAL_SYMBOL string v__scanner__decode_o_escapes(string s, int start, Array_int escapes_pos);
|
||
VV_LOCAL_SYMBOL string v__scanner__decode_u_escapes(string s, int start, Array_int escapes_pos);
|
||
VV_LOCAL_SYMBOL string v__scanner__trim_slash_line_break(string s);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_ident_char(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL bool v__scanner__Scanner_expect(v__scanner__Scanner* s, string want, int start_pos);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_ignore_line(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_eat_to_end_of_line(v__scanner__Scanner* s);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_inc_line_number(v__scanner__Scanner* s);
|
||
void v__scanner__Scanner_note(v__scanner__Scanner* s, string msg);
|
||
void v__scanner__Scanner_add_error_detail(v__scanner__Scanner* s, string msg);
|
||
void v__scanner__Scanner_add_error_detail_with_pos(v__scanner__Scanner* s, string msg, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL string v__scanner__Scanner_eat_details(v__scanner__Scanner* s);
|
||
void v__scanner__Scanner_warn(v__scanner__Scanner* s, string msg);
|
||
void v__scanner__Scanner_error(v__scanner__Scanner* s, string msg);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_vet_error(v__scanner__Scanner* s, string msg, v__vet__FixKind fix);
|
||
VV_LOCAL_SYMBOL void v__scanner__Scanner_trace(v__scanner__Scanner* s, string fbase, string message);
|
||
_option_void v__ast__walker__Inspector_visit(v__ast__walker__Inspector* i, v__ast__Node* node);
|
||
void v__ast__walker__inspect(v__ast__Node* node, voidptr data, bool (*inspector_callback)(v__ast__Node* node, voidptr data));
|
||
void v__ast__walker__walk(v__ast__walker__Visitor* visitor, v__ast__Node* node);
|
||
VV_LOCAL_SYMBOL v__ast__Stmt v__parser__Parser_assign_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL _option_void v__parser__Parser_check_undefined_variables(v__parser__Parser* p, Array_v__ast__Expr exprs, v__ast__Expr val);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_check_cross_variables(v__parser__Parser* p, Array_v__ast__Expr exprs, v__ast__Expr val);
|
||
VV_LOCAL_SYMBOL v__ast__Stmt v__parser__Parser_partial_assign_stmt(v__parser__Parser* p, Array_v__ast__Expr left, Array_v__ast__Comment left_comments);
|
||
v__ast__ComptimeType v__parser__Parser_parse_comptime_type(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__HashStmt v__parser__Parser_hash(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__ComptimeCall v__parser__Parser_comptime_call(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__ComptimeFor v__parser__Parser_comptime_for(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__AtExpr v__parser__Parser_at(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_comptime_selector(v__parser__Parser* p, v__ast__Expr left);
|
||
VV_LOCAL_SYMBOL v__ast__ArrayInit v__parser__Parser_array_init(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__MapInit v__parser__Parser_map_init(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_scope_register_it_as_index(v__parser__Parser* p);
|
||
v__ast__Expr v__parser__Parser_expr(v__parser__Parser* p, int precedence);
|
||
_option_v__ast__Expr v__parser__Parser_check_expr(v__parser__Parser* p, int precedence);
|
||
v__ast__Expr v__parser__Parser_expr_with_left(v__parser__Parser* p, v__ast__Expr left, int precedence, bool is_stmt_ident);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_infix_expr(v__parser__Parser* p, v__ast__Expr left);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_fileis(v__parser__Parser* p, string s);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_prefix_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_recast_as_pointer(v__parser__Parser* p, v__ast__CastExpr* cast_expr, v__token__Pos pos);
|
||
v__ast__CallExpr v__parser__Parser_call_expr(v__parser__Parser* p, v__ast__Language language, string mod);
|
||
Array_v__ast__CallArg v__parser__Parser_call_args(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__FnDecl v__parser__Parser_fn_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL _option_void v__parser__Parser_fn_receiver(v__parser__Parser* p, Array_v__ast__Param* params, v__parser__ReceiverParsingInfo* rec);
|
||
VV_LOCAL_SYMBOL v__ast__AnonFn v__parser__Parser_anon_fn(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL multi_return_Array_v__ast__Param_bool_bool v__parser__Parser_fn_args(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__GoExpr v__parser__Parser_go_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL Array_v__ast__Param v__parser__Parser_closure_vars(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_check_fn_mutable_arguments(v__parser__Parser* p, v__ast__Type typ, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_check_fn_shared_arguments(v__parser__Parser* p, v__ast__Type typ, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_check_fn_atomic_arguments(v__parser__Parser* p, v__ast__Type typ, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL bool v__parser__have_fn_main(Array_v__ast__Stmt stmts);
|
||
VV_LOCAL_SYMBOL v__ast__Stmt v__parser__Parser_for_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__IfExpr v__parser__Parser_if_expr(v__parser__Parser* p, bool is_comptime);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_only_array_type(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__MatchExpr v__parser__Parser_match_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__SelectExpr v__parser__Parser_select_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_lockable(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL multi_return_Array_v__ast__Expr_Array_v__ast__Comment v__parser__Parser_lockable_list(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__LockExpr v__parser__Parser_lock_expr(v__parser__Parser* p);
|
||
bool v__parser__Parser_known_import(v__parser__Parser* p, string mod);
|
||
VV_LOCAL_SYMBOL string v__parser__Parser_prepend_mod(v__parser__Parser* p, string name);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_used_import(v__parser__Parser* p, string alias);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_register_used_import(v__parser__Parser* p, string alias);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_register_auto_import(v__parser__Parser* p, string alias);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_check_unused_imports(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_array_type(v__parser__Parser* p, v__token__Kind expecting);
|
||
v__ast__Type v__parser__Parser_parse_map_type(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_chan_type(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_thread_type(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_multi_return_type(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_fn_type(v__parser__Parser* p, string name);
|
||
v__ast__Type v__parser__Parser_parse_type_with_mut(v__parser__Parser* p, bool is_mut);
|
||
v__ast__Language v__parser__Parser_parse_language(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_inline_sum_type(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL int compare_16311103228414776939_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
Array_v__ast__TypeNode v__parser__Parser_parse_sum_type_variants(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_type(v__parser__Parser* p);
|
||
v__ast__Type v__parser__Parser_parse_any_type(v__parser__Parser* p, v__ast__Language language, bool is_ptr, bool check_dot);
|
||
v__ast__Type v__parser__Parser_find_type_or_add_placeholder(v__parser__Parser* p, string name, v__ast__Language language);
|
||
v__ast__Type v__parser__Parser_parse_generic_type(v__parser__Parser* p, string name);
|
||
v__ast__Type v__parser__Parser_parse_generic_inst_type(v__parser__Parser* p, string name);
|
||
v__ast__Stmt v__parser__parse_stmt(string text, v__ast__Table* table, v__ast__Scope* scope);
|
||
v__ast__File* v__parser__parse_comptime(string tmpl_path, string text, v__ast__Table* table, v__pref__Preferences* pref, v__ast__Scope* scope);
|
||
v__ast__File* v__parser__parse_text(string text, string path, v__ast__Table* table, v__scanner__CommentsMode comments_mode, v__pref__Preferences* pref);
|
||
void v__parser__Parser_free(v__parser__Parser* p);
|
||
void v__parser__Parser_free_scanner(v__parser__Parser* p);
|
||
void v__parser__Parser_set_path(v__parser__Parser* p, string path);
|
||
v__ast__File* v__parser__parse_file(string path, v__ast__Table* table, v__scanner__CommentsMode comments_mode, v__pref__Preferences* pref);
|
||
multi_return_ref_v__ast__File_Array_v__vet__Error v__parser__parse_vet_file(string path, v__ast__Table* table_, v__pref__Preferences* pref);
|
||
v__ast__File* v__parser__Parser_parse(v__parser__Parser* p);
|
||
Array_v__ast__File_ptr v__parser__parse_files(Array_string paths, v__ast__Table* table, v__pref__Preferences* pref);
|
||
void v__parser__Parser_codegen(v__parser__Parser* p, string code);
|
||
void v__parser__Parser_init_parse_fns(v__parser__Parser* p);
|
||
void v__parser__Parser_read_first_token(v__parser__Parser* p);
|
||
v__token__Token v__parser__Parser_peek_token(v__parser__Parser* p, int n);
|
||
VV_LOCAL_SYMBOL v__token__Token v__parser__Parser_peek_token_after_var_list(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_array_type(v__parser__Parser* p);
|
||
void v__parser__Parser_open_scope(v__parser__Parser* p);
|
||
void v__parser__Parser_close_scope(v__parser__Parser* p);
|
||
Array_v__ast__Stmt v__parser__Parser_parse_block(v__parser__Parser* p);
|
||
Array_v__ast__Stmt v__parser__Parser_parse_block_no_scope(v__parser__Parser* p, bool is_top_level);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_next(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_check(v__parser__Parser* p, v__token__Kind expected);
|
||
VV_LOCAL_SYMBOL string v__parser__Parser_check_js_name(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL string v__parser__Parser_check_name(v__parser__Parser* p);
|
||
v__ast__Stmt v__parser__Parser_top_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL bool v__parser__comptime_if_expr_contains_top_stmt(v__ast__IfExpr if_expr);
|
||
VV_LOCAL_SYMBOL v__ast__Stmt v__parser__Parser_other_stmts(v__parser__Parser* p, v__ast__Stmt cur_stmt);
|
||
v__ast__Comment v__parser__Parser_check_comment(v__parser__Parser* p);
|
||
v__ast__Comment v__parser__Parser_comment(v__parser__Parser* p);
|
||
v__ast__ExprStmt v__parser__Parser_comment_stmt(v__parser__Parser* p);
|
||
Array_v__ast__Comment v__parser__Parser_eat_comments(v__parser__Parser* p, v__parser__EatCommentsConfig cfg);
|
||
v__ast__Stmt v__parser__Parser_stmt(v__parser__Parser* p, bool is_top_level);
|
||
VV_LOCAL_SYMBOL v__ast__AsmStmt v__parser__Parser_asm_stmt(v__parser__Parser* p, bool is_top_level);
|
||
VV_LOCAL_SYMBOL v__ast__AsmArg v__parser__Parser_reg_or_alias(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__AsmAddressing v__parser__Parser_asm_addressing(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL Array_v__ast__AsmIO v__parser__Parser_asm_ios(v__parser__Parser* p, bool output);
|
||
VV_LOCAL_SYMBOL multi_return_Array_v__ast__Expr_Array_v__ast__Comment v__parser__Parser_expr_list(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_attributes(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_attributes(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Attr v__parser__Parser_parse_attr(v__parser__Parser* p);
|
||
void v__parser__Parser_language_not_allowed_error(v__parser__Parser* p, v__ast__Language language, v__token__Pos pos);
|
||
void v__parser__Parser_language_not_allowed_warning(v__parser__Parser* p, v__ast__Language language, v__token__Pos pos);
|
||
void v__parser__Parser_check_for_impure_v(v__parser__Parser* p, v__ast__Language language, v__token__Pos pos);
|
||
v__ast__NodeError v__parser__Parser_error(v__parser__Parser* p, string s);
|
||
void v__parser__Parser_warn(v__parser__Parser* p, string s);
|
||
void v__parser__Parser_note(v__parser__Parser* p, string s);
|
||
v__ast__NodeError v__parser__Parser_error_with_pos(v__parser__Parser* p, string s, v__token__Pos pos);
|
||
void v__parser__Parser_error_with_error(v__parser__Parser* p, v__errors__Error _v_error);
|
||
void v__parser__Parser_warn_with_pos(v__parser__Parser* p, string s, v__token__Pos pos);
|
||
void v__parser__Parser_note_with_pos(v__parser__Parser* p, string s, v__token__Pos pos);
|
||
void v__parser__Parser_vet_error(v__parser__Parser* p, string msg, int line, v__vet__FixKind fix, v__vet__ErrorType typ);
|
||
VV_LOCAL_SYMBOL v__ast__Stmt v__parser__Parser_parse_multi_expr(v__parser__Parser* p, bool is_top_level);
|
||
v__ast__Ident v__parser__Parser_parse_ident(v__parser__Parser* p, v__ast__Language language);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_typename(v__parser__Parser* p, v__token__Token t);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_generic_call(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_generic_cast(v__parser__Parser* p);
|
||
v__ast__Expr v__parser__Parser_name_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__IndexExpr v__parser__Parser_index_expr(v__parser__Parser* p, v__ast__Expr left, bool is_gated);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_scope_register_it(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_scope_register_ab(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_dot_expr(v__parser__Parser* p, v__ast__Expr left);
|
||
VV_LOCAL_SYMBOL multi_return_Array_v__ast__Type_Array_string v__parser__Parser_parse_generic_types(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL Array_v__ast__Type v__parser__Parser_parse_concrete_types(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_is_generic_name(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__EnumVal v__parser__Parser_enum_val(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_filter_string_vet_errors(v__parser__Parser* p, v__token__Pos pos);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_string_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_parse_number_literal(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Module v__parser__Parser_module_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Import v__parser__Parser_import_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_import_syms(v__parser__Parser* p, v__ast__Import* parent);
|
||
VV_LOCAL_SYMBOL v__ast__ConstDecl v__parser__Parser_const_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Return v__parser__Parser_return_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__GlobalDecl v__parser__Parser_global_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__EnumDecl v__parser__Parser_enum_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__TypeDecl v__parser__Parser_type_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Assoc v__parser__Parser_assoc(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_new_true_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__verror(string s);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_top_level_statement_start(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_top_level_statement_end(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_rewind_scanner_to_current_token_in_new_mode(v__parser__Parser* p);
|
||
bool v__parser__Parser_mark_var_as_used(v__parser__Parser* p, string varname);
|
||
VV_LOCAL_SYMBOL v__ast__Stmt v__parser__Parser_unsafe_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL bool v__parser__Parser_disallow_declarations_in_script_mode(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__Parser_trace(v__parser__Parser* p, string fbase, string message);
|
||
VV_LOCAL_SYMBOL v__ast__Expr v__parser__Parser_sql_expr(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__SqlStmt v__parser__Parser_sql_stmt(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__SqlStmtLine v__parser__Parser_parse_sql_stmt_line(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL _option_bool v__parser__Parser_check_sql_keyword(v__parser__Parser* p, string name);
|
||
VV_LOCAL_SYMBOL v__ast__StructDecl v__parser__Parser_struct_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL v__ast__StructInit v__parser__Parser_struct_init(v__parser__Parser* p, string typ_str, bool short_syntax);
|
||
VV_LOCAL_SYMBOL v__ast__InterfaceDecl v__parser__Parser_interface_decl(v__parser__Parser* p);
|
||
VV_LOCAL_SYMBOL void v__parser__State_update(v__parser__State* state, string line);
|
||
VV_LOCAL_SYMBOL bool v__parser__is_html_open_tag(string name, string s);
|
||
VV_LOCAL_SYMBOL string v__parser__insert_template_code(string fn_name, string tmpl_str_start, string line);
|
||
string v__parser__Parser_compile_template_file(v__parser__Parser* p, string template_file, string fn_name);
|
||
void v__callgraph__show(v__ast__Table* table, v__pref__Preferences* pref, Array_v__ast__File_ptr ast_files);
|
||
VV_LOCAL_SYMBOL string v__callgraph__Mapper_dot_normalise_node_name(v__callgraph__Mapper* m, string name);
|
||
VV_LOCAL_SYMBOL string v__callgraph__Mapper_fn_name(v__callgraph__Mapper* m, string fname, v__ast__Type receiver_type, bool is_method);
|
||
VV_LOCAL_SYMBOL string v__callgraph__Mapper_dot_fn_name(v__callgraph__Mapper* m, string fname, v__ast__Type recv_type, bool is_method);
|
||
VV_LOCAL_SYMBOL _option_void v__callgraph__Mapper_visit(v__callgraph__Mapper* m, v__ast__Node* node);
|
||
v__builder__Builder v__builder__new_builder(v__pref__Preferences* pref);
|
||
_option_void v__builder__Builder_front_stages(v__builder__Builder* b, Array_string v_files);
|
||
_option_void v__builder__Builder_middle_stages(v__builder__Builder* b);
|
||
_option_void v__builder__Builder_front_and_middle_stages(v__builder__Builder* b, Array_string v_files);
|
||
void v__builder__Builder_parse_imports(v__builder__Builder* b);
|
||
void v__builder__Builder_resolve_deps(v__builder__Builder* b);
|
||
v__depgraph__DepGraph* v__builder__Builder_import_graph(v__builder__Builder* b);
|
||
Array_string v__builder__Builder_v_files_from_dir(v__builder__Builder* b, string dir);
|
||
void v__builder__Builder_log(v__builder__Builder* b, string s);
|
||
void v__builder__Builder_info(v__builder__Builder* b, string s);
|
||
string v__builder__module_path(string mod);
|
||
_option_string v__builder__Builder_find_module_path(v__builder__Builder* b, string mod, string fpath);
|
||
void v__builder__Builder_show_total_warns_and_errors_stats(v__builder__Builder* b);
|
||
void v__builder__Builder_print_warnings_and_errors(v__builder__Builder* b);
|
||
v__errors__Error v__builder__Builder_error_with_pos(v__builder__Builder* b, string s, string fpath, v__token__Pos pos);
|
||
void v__builder__verror(string s);
|
||
_option_void v__builder__Builder_find_win_cc(v__builder__Builder* v);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_show_c_compiler_output(v__builder__Builder* v, os__Result res);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_post_process_c_compiler_output(v__builder__Builder* v, os__Result res);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_show_cc(v__builder__Builder* v, string cmd, string response_file, string response_file_content);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_setup_ccompiler_options(v__builder__Builder* v, string ccompiler);
|
||
VV_LOCAL_SYMBOL Array_string v__builder__Builder_all_args(v__builder__Builder* v, v__builder__CcompilerOptions ccoptions);
|
||
VV_LOCAL_SYMBOL Array_string v__builder__Builder_thirdparty_object_args(v__builder__Builder* v, v__builder__CcompilerOptions ccoptions, Array_string middle);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_setup_output_name(v__builder__Builder* v);
|
||
void v__builder__Builder_cc(v__builder__Builder* v);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_ensure_linuxroot_exists(v__builder__Builder* b, string sysroot);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_cc_linux_cross(v__builder__Builder* b);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_cc_windows_cross(v__builder__Builder* c);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_build_thirdparty_obj_files(v__builder__Builder* b);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_build_thirdparty_obj_file(v__builder__Builder* v, string path, Array_v__cflag__CFlag moduleflags);
|
||
VV_LOCAL_SYMBOL string v__builder__missing_compiler_info(void);
|
||
VV_LOCAL_SYMBOL Array_string v__builder__error_context_lines(string text, string keyword, int before, int after);
|
||
VV_LOCAL_SYMBOL Array_v__cflag__CFlag v__builder__Builder_get_os_cflags(v__builder__Builder* v);
|
||
VV_LOCAL_SYMBOL Array_v__cflag__CFlag v__builder__Builder_get_rest_of_module_cflags(v__builder__Builder* v, v__cflag__CFlag* c);
|
||
void v__builder__compile(string command, v__pref__Preferences* pref, void (*backend_cb)(v__builder__Builder* b));
|
||
VV_LOCAL_SYMBOL void v__builder__check_if_output_folder_is_writable(v__pref__Preferences* pref);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_myfree(v__builder__Builder* b);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_exit_on_invalid_syntax(v__builder__Builder* b);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_run_compiled_executable_and_exit(v__builder__Builder* b);
|
||
VV_LOCAL_SYMBOL void v__builder__eshcb(os__Signal _d1);
|
||
VV_LOCAL_SYMBOL void v__builder__serror(string reason, IError e);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_cleanup_run_executable_after_exit(v__builder__Builder* v, string exefile);
|
||
void v__builder__Builder_set_module_lookup_paths(v__builder__Builder* v);
|
||
Array_string v__builder__Builder_get_builtin_files(v__builder__Builder* v);
|
||
Array_string v__builder__Builder_get_user_files(v__builder__Builder* v);
|
||
void v__builder__Builder_dump_c_options(v__builder__Builder* b, Array_string all_args);
|
||
void v__builder__Builder_dump_modules(v__builder__Builder* b, Array_string mods);
|
||
void v__builder__Builder_dump_files(v__builder__Builder* b, Array_string files);
|
||
VV_LOCAL_SYMBOL void v__builder__dump_list(string file_path, Array_string list);
|
||
VV_LOCAL_SYMBOL _option_string v__builder__find_windows_kit_internal(v__builder__RegKey key, Array_string versions);
|
||
VV_LOCAL_SYMBOL _option_v__builder__WindowsKit v__builder__find_windows_kit_root(string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__WindowsKit v__builder__find_windows_kit_root_by_reg(string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__WindowsKit v__builder__new_windows_kit(string kit_root, string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__WindowsKit v__builder__find_windows_kit_root_by_env(string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__VsInstallation v__builder__find_vs(string vswhere_dir, string host_arch, string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__VsInstallation v__builder__find_vs_by_reg(string vswhere_dir, string host_arch, string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__VsInstallation v__builder__find_vs_by_env(string host_arch, string target_arch);
|
||
VV_LOCAL_SYMBOL _option_v__builder__MsvcResult v__builder__find_msvc(bool m64_target);
|
||
void v__builder__Builder_cc_msvc(v__builder__Builder* v);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_build_thirdparty_obj_file_with_msvc(v__builder__Builder* v, string path, Array_v__cflag__CFlag moduleflags);
|
||
v__builder__MsvcStringFlags v__builder__msvc_string_flags(Array_v__cflag__CFlag cflags);
|
||
VV_LOCAL_SYMBOL Array_string v__builder__MsvcResult_include_paths(v__builder__MsvcResult* r);
|
||
VV_LOCAL_SYMBOL Array_string v__builder__MsvcResult_library_paths(v__builder__MsvcResult* r);
|
||
void v__builder__Builder_rebuild_modules(v__builder__Builder* b);
|
||
Array_string v__builder__Builder_find_invalidated_modules_by_files(v__builder__Builder* b, Array_string all_files);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_v_build_module(v__builder__Builder* b, string vexe, string imp_path);
|
||
VV_LOCAL_SYMBOL string v__builder__Builder_rebuild_cached_module(v__builder__Builder* b, string vexe, string imp_path);
|
||
VV_LOCAL_SYMBOL void v__builder__Builder_handle_usecache(v__builder__Builder* b, string vexe);
|
||
bool v__builder__Builder_should_rebuild(v__builder__Builder* b);
|
||
VV_LOCAL_SYMBOL int compare_7770354126342877024_string(string* a, string* b) {
|
||
if (string__lt(*a, *b)) return -1;
|
||
else return 1;
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL i64 v__builder__most_recent_timestamp(Array_string files);
|
||
void v__builder__Builder_rebuild(v__builder__Builder* b, void (*backend_cb)(v__builder__Builder* b));
|
||
string v__builder__Builder_get_vtmp_filename(v__builder__Builder* b, string base_file_name, string postfix);
|
||
void v__builder__cbuilder__start(void);
|
||
void v__builder__cbuilder__compile_c(v__builder__Builder* b);
|
||
string v__builder__cbuilder__gen_c(v__builder__Builder* b, Array_string v_files);
|
||
void v__builder__cbuilder__build_c(v__builder__Builder* b, Array_string v_files, string out_file);
|
||
VV_LOCAL_SYMBOL void main__main(void);
|
||
VV_LOCAL_SYMBOL void main__invoke_help_and_exit(Array_string remaining);
|
||
VV_LOCAL_SYMBOL void main__rebuild(v__pref__Preferences* prefs);
|
||
string _v_dump_expr_string(string fpath, int line, string sexpr, string dump_arg);
|
||
|
||
static string time__FormatTime_str(time__FormatTime it); // auto
|
||
static string time__FormatDate_str(time__FormatDate it); // auto
|
||
static string v__pref__Backend_str(v__pref__Backend it); // auto
|
||
static string v__ast__AttrKind_str(v__ast__AttrKind it); // auto
|
||
static string Array_v__ast__Expr_str(Array_v__ast__Expr a); // auto
|
||
static string indent_Array_v__ast__Expr_str(Array_v__ast__Expr a, int indent_count); // auto
|
||
static string v__ast__CallExpr_str(v__ast__CallExpr it); // auto
|
||
static string indent_v__ast__CallExpr_str(v__ast__CallExpr it, int indent_count); // auto
|
||
static string v__ast__TypeInfo_str(v__ast__TypeInfo x); // auto
|
||
static string indent_v__ast__TypeInfo_str(v__ast__TypeInfo x, int indent_count); // auto
|
||
static string v__ast__Fn_str(v__ast__Fn it); // auto
|
||
static string indent_v__ast__Fn_str(v__ast__Fn it, int indent_count); // auto
|
||
static string v__ast__Language_str(v__ast__Language it); // auto
|
||
static string v__ast__IdentKind_str(v__ast__IdentKind it); // auto
|
||
static string anon_fn_v__ast__constdecl_str(); // auto
|
||
static string v__token__Pos_str(v__token__Pos it); // auto
|
||
static string indent_v__token__Pos_str(v__token__Pos it, int indent_count); // auto
|
||
static string Array_v__ast__Attr_str(Array_v__ast__Attr a); // auto
|
||
static string indent_Array_v__ast__Attr_str(Array_v__ast__Attr a, int indent_count); // auto
|
||
static string Array_v__ast__Type_str(Array_v__ast__Type a); // auto
|
||
static string indent_Array_v__ast__Type_str(Array_v__ast__Type a, int indent_count); // auto
|
||
static string Array_Array_v__ast__Type_str(Array_Array_v__ast__Type a); // auto
|
||
static string indent_Array_Array_v__ast__Type_str(Array_Array_v__ast__Type a, int indent_count); // auto
|
||
static string v__gen__c__StrType_str(v__gen__c__StrType it); // auto
|
||
static string indent_v__gen__c__StrType_str(v__gen__c__StrType it, int indent_count); // auto
|
||
static string v__ast__Enum_str(v__ast__Enum it); // auto
|
||
static string indent_v__ast__Enum_str(v__ast__Enum it, int indent_count); // auto
|
||
static string v__ast__ComptTimeConstValue_str(v__ast__ComptTimeConstValue x); // auto
|
||
static string indent_v__ast__ComptTimeConstValue_str(v__ast__ComptTimeConstValue x, int indent_count); // auto
|
||
static string v__gen__c__SqlType_str(v__gen__c__SqlType it); // auto
|
||
static string Array_rune_str(Array_rune a); // auto
|
||
static string indent_Array_rune_str(Array_rune a, int indent_count); // auto
|
||
static string v__scanner__CommentsMode_str(v__scanner__CommentsMode it); // auto
|
||
static string v__parser__State_str(v__parser__State it); // auto
|
||
static string v__errors__Reporter_str(v__errors__Reporter it); // auto
|
||
static string v__builder__CcompilerOptions_str(v__builder__CcompilerOptions it); // auto
|
||
static string indent_v__builder__CcompilerOptions_str(v__builder__CcompilerOptions it, int indent_count); // auto
|
||
static string Array_v__cflag__CFlag_str(Array_v__cflag__CFlag a); // auto
|
||
static string indent_Array_v__cflag__CFlag_str(Array_v__cflag__CFlag a, int indent_count); // auto
|
||
static string Map_string_int_str(Map_string_int m); // auto
|
||
static string indent_Map_string_int_str(Map_string_int m, int indent_count); // auto
|
||
static string v__ast__OrExpr_str(v__ast__OrExpr it); // auto
|
||
static string indent_v__ast__OrExpr_str(v__ast__OrExpr it, int indent_count); // auto
|
||
static string Array_v__ast__CallArg_str(Array_v__ast__CallArg a); // auto
|
||
static string indent_Array_v__ast__CallArg_str(Array_v__ast__CallArg a, int indent_count); // auto
|
||
static string Array_v__ast__Comment_str(Array_v__ast__Comment a); // auto
|
||
static string indent_Array_v__ast__Comment_str(Array_v__ast__Comment a, int indent_count); // auto
|
||
static string v__ast__Aggregate_str(v__ast__Aggregate it); // auto
|
||
static string indent_v__ast__Aggregate_str(v__ast__Aggregate it, int indent_count); // auto
|
||
static string v__ast__Alias_str(v__ast__Alias it); // auto
|
||
static string indent_v__ast__Alias_str(v__ast__Alias it, int indent_count); // auto
|
||
static string v__ast__Array_str(v__ast__Array it); // auto
|
||
static string indent_v__ast__Array_str(v__ast__Array it, int indent_count); // auto
|
||
static string v__ast__ArrayFixed_str(v__ast__ArrayFixed it); // auto
|
||
static string indent_v__ast__ArrayFixed_str(v__ast__ArrayFixed it, int indent_count); // auto
|
||
static string v__ast__Chan_str(v__ast__Chan it); // auto
|
||
static string indent_v__ast__Chan_str(v__ast__Chan it, int indent_count); // auto
|
||
static string v__ast__FnType_str(v__ast__FnType it); // auto
|
||
static string indent_v__ast__FnType_str(v__ast__FnType it, int indent_count); // auto
|
||
static string v__ast__GenericInst_str(v__ast__GenericInst it); // auto
|
||
static string indent_v__ast__GenericInst_str(v__ast__GenericInst it, int indent_count); // auto
|
||
static string v__ast__Interface_str(v__ast__Interface it); // auto
|
||
static string indent_v__ast__Interface_str(v__ast__Interface it, int indent_count); // auto
|
||
static string v__ast__Map_str(v__ast__Map it); // auto
|
||
static string indent_v__ast__Map_str(v__ast__Map it, int indent_count); // auto
|
||
static string v__ast__MultiReturn_str(v__ast__MultiReturn it); // auto
|
||
static string indent_v__ast__MultiReturn_str(v__ast__MultiReturn it, int indent_count); // auto
|
||
static string v__ast__Struct_str(v__ast__Struct it); // auto
|
||
static string indent_v__ast__Struct_str(v__ast__Struct it, int indent_count); // auto
|
||
static string v__ast__SumType_str(v__ast__SumType it); // auto
|
||
static string indent_v__ast__SumType_str(v__ast__SumType it, int indent_count); // auto
|
||
static string v__ast__Thread_str(v__ast__Thread it); // auto
|
||
static string indent_v__ast__Thread_str(v__ast__Thread it, int indent_count); // auto
|
||
static string Array_v__ast__Param_str(Array_v__ast__Param a); // auto
|
||
static string indent_Array_v__ast__Param_str(Array_v__ast__Param a, int indent_count); // auto
|
||
static string v__ast__EmptyExpr_str(v__ast__EmptyExpr it); // auto
|
||
static string indent_v__ast__EmptyExpr_str(v__ast__EmptyExpr it, int indent_count); // auto
|
||
static string Array_v__ast__Stmt_str(Array_v__ast__Stmt a); // auto
|
||
static string indent_Array_v__ast__Stmt_str(Array_v__ast__Stmt a, int indent_count); // auto
|
||
static string v__ast__OrKind_str(v__ast__OrKind it); // auto
|
||
static string v__ast__Comment_str(v__ast__Comment it); // auto
|
||
static string indent_v__ast__Comment_str(v__ast__Comment it, int indent_count); // auto
|
||
static string Array_v__ast__StructField_str(Array_v__ast__StructField a); // auto
|
||
static string indent_Array_v__ast__StructField_str(Array_v__ast__StructField a, int indent_count); // auto
|
||
static string Map_int_Array_v__ast__Type_str(Map_int_Array_v__ast__Type m); // auto
|
||
static string indent_Map_int_Array_v__ast__Type_str(Map_int_Array_v__ast__Type m, int indent_count); // auto
|
||
static string Array_v__ast__Fn_str(Array_v__ast__Fn a); // auto
|
||
static string indent_Array_v__ast__Fn_str(Array_v__ast__Fn a, int indent_count); // auto
|
||
static string v__ast__Param_str(v__ast__Param it); // auto
|
||
static string indent_v__ast__Param_str(v__ast__Param it, int indent_count); // auto
|
||
static string v__ast__StructField_str(v__ast__StructField it); // auto
|
||
static string indent_v__ast__StructField_str(v__ast__StructField it, int indent_count); // auto
|
||
static bool Array_rune_arr_eq(Array_rune a, Array_rune b); // auto
|
||
static bool time__Duration_alias_eq(time__Duration a, time__Duration b); // auto
|
||
static bool v__ast__Type_alias_eq(v__ast__Type a, v__ast__Type b); // auto
|
||
static bool Array_string_arr_eq(Array_string a, Array_string b); // auto
|
||
static bool v__token__Pos_struct_eq(v__token__Pos a, v__token__Pos b); // auto
|
||
static bool Array_v__ast__Type_arr_eq(Array_v__ast__Type a, Array_v__ast__Type b); // auto
|
||
static bool v__ast__Stmt_sumtype_eq(v__ast__Stmt a, v__ast__Stmt b); // auto
|
||
static bool v__ast__AsmStmt_struct_eq(v__ast__AsmStmt a, v__ast__AsmStmt b); // auto
|
||
static bool Array_v__ast__AsmClobbered_arr_eq(Array_v__ast__AsmClobbered a, Array_v__ast__AsmClobbered b); // auto
|
||
static bool v__ast__AsmClobbered_struct_eq(v__ast__AsmClobbered a, v__ast__AsmClobbered b); // auto
|
||
static bool v__ast__AsmRegister_struct_eq(v__ast__AsmRegister a, v__ast__AsmRegister b); // auto
|
||
static bool Array_v__ast__Comment_arr_eq(Array_v__ast__Comment a, Array_v__ast__Comment b); // auto
|
||
static bool v__ast__Comment_struct_eq(v__ast__Comment a, v__ast__Comment b); // auto
|
||
static bool Array_v__ast__AsmTemplate_arr_eq(Array_v__ast__AsmTemplate a, Array_v__ast__AsmTemplate b); // auto
|
||
static bool v__ast__AsmTemplate_struct_eq(v__ast__AsmTemplate a, v__ast__AsmTemplate b); // auto
|
||
static bool Array_v__ast__AsmArg_arr_eq(Array_v__ast__AsmArg a, Array_v__ast__AsmArg b); // auto
|
||
static bool v__ast__AsmArg_sumtype_eq(v__ast__AsmArg a, v__ast__AsmArg b); // auto
|
||
static bool v__ast__AsmAddressing_struct_eq(v__ast__AsmAddressing a, v__ast__AsmAddressing b); // auto
|
||
static bool v__ast__AsmAlias_struct_eq(v__ast__AsmAlias a, v__ast__AsmAlias b); // auto
|
||
static bool v__ast__AsmDisp_struct_eq(v__ast__AsmDisp a, v__ast__AsmDisp b); // auto
|
||
static bool v__ast__BoolLiteral_struct_eq(v__ast__BoolLiteral a, v__ast__BoolLiteral b); // auto
|
||
static bool v__ast__CharLiteral_struct_eq(v__ast__CharLiteral a, v__ast__CharLiteral b); // auto
|
||
static bool v__ast__FloatLiteral_struct_eq(v__ast__FloatLiteral a, v__ast__FloatLiteral b); // auto
|
||
static bool v__ast__IntegerLiteral_struct_eq(v__ast__IntegerLiteral a, v__ast__IntegerLiteral b); // auto
|
||
static bool Array_v__ast__AsmIO_arr_eq(Array_v__ast__AsmIO a, Array_v__ast__AsmIO b); // auto
|
||
static bool v__ast__AsmIO_struct_eq(v__ast__AsmIO a, v__ast__AsmIO b); // auto
|
||
static bool v__ast__Expr_sumtype_eq(v__ast__Expr a, v__ast__Expr b); // auto
|
||
static bool v__ast__AnonFn_struct_eq(v__ast__AnonFn a, v__ast__AnonFn b); // auto
|
||
static bool v__ast__FnDecl_struct_eq(v__ast__FnDecl a, v__ast__FnDecl b); // auto
|
||
static bool v__ast__StructField_struct_eq(v__ast__StructField a, v__ast__StructField b); // auto
|
||
static bool Array_v__ast__Attr_arr_eq(Array_v__ast__Attr a, Array_v__ast__Attr b); // auto
|
||
static bool v__ast__Attr_struct_eq(v__ast__Attr a, v__ast__Attr b); // auto
|
||
static bool Array_v__ast__Param_arr_eq(Array_v__ast__Param a, Array_v__ast__Param b); // auto
|
||
static bool v__ast__Param_struct_eq(v__ast__Param a, v__ast__Param b); // auto
|
||
static bool Array_v__ast__Stmt_arr_eq(Array_v__ast__Stmt a, Array_v__ast__Stmt b); // auto
|
||
static bool Array_v__ast__DeferStmt_arr_eq(Array_v__ast__DeferStmt a, Array_v__ast__DeferStmt b); // auto
|
||
static bool v__ast__DeferStmt_struct_eq(v__ast__DeferStmt a, v__ast__DeferStmt b); // auto
|
||
static bool Array_v__ast__Ident_arr_eq(Array_v__ast__Ident a, Array_v__ast__Ident b); // auto
|
||
static bool v__ast__Ident_struct_eq(v__ast__Ident a, v__ast__Ident b); // auto
|
||
static bool v__ast__ScopeObject_sumtype_eq(v__ast__ScopeObject a, v__ast__ScopeObject b); // auto
|
||
static bool v__ast__ConstField_struct_eq(v__ast__ConstField a, v__ast__ConstField b); // auto
|
||
static bool v__ast__ComptTimeConstValue_sumtype_eq(v__ast__ComptTimeConstValue a, v__ast__ComptTimeConstValue b); // auto
|
||
static bool v__ast__EmptyExpr_struct_eq(v__ast__EmptyExpr a, v__ast__EmptyExpr b); // auto
|
||
static bool v__ast__GlobalField_struct_eq(v__ast__GlobalField a, v__ast__GlobalField b); // auto
|
||
static bool v__ast__Var_struct_eq(v__ast__Var a, v__ast__Var b); // auto
|
||
static bool v__ast__IdentInfo_sumtype_eq(v__ast__IdentInfo a, v__ast__IdentInfo b); // auto
|
||
static bool v__ast__IdentFn_struct_eq(v__ast__IdentFn a, v__ast__IdentFn b); // auto
|
||
static bool v__ast__IdentVar_struct_eq(v__ast__IdentVar a, v__ast__IdentVar b); // auto
|
||
static bool v__ast__ArrayDecompose_struct_eq(v__ast__ArrayDecompose a, v__ast__ArrayDecompose b); // auto
|
||
static bool v__ast__ArrayInit_struct_eq(v__ast__ArrayInit a, v__ast__ArrayInit b); // auto
|
||
static bool Array_Array_v__ast__Comment_arr_eq(Array_Array_v__ast__Comment a, Array_Array_v__ast__Comment b); // auto
|
||
static bool Array_v__ast__Expr_arr_eq(Array_v__ast__Expr a, Array_v__ast__Expr b); // auto
|
||
static bool v__ast__AsCast_struct_eq(v__ast__AsCast a, v__ast__AsCast b); // auto
|
||
static bool v__ast__Assoc_struct_eq(v__ast__Assoc a, v__ast__Assoc b); // auto
|
||
static bool v__ast__AtExpr_struct_eq(v__ast__AtExpr a, v__ast__AtExpr b); // auto
|
||
static bool v__ast__CTempVar_struct_eq(v__ast__CTempVar a, v__ast__CTempVar b); // auto
|
||
static bool v__ast__CallExpr_struct_eq(v__ast__CallExpr a, v__ast__CallExpr b); // auto
|
||
static bool v__ast__OrExpr_struct_eq(v__ast__OrExpr a, v__ast__OrExpr b); // auto
|
||
static bool Array_v__ast__CallArg_arr_eq(Array_v__ast__CallArg a, Array_v__ast__CallArg b); // auto
|
||
static bool v__ast__CallArg_struct_eq(v__ast__CallArg a, v__ast__CallArg b); // auto
|
||
static bool v__ast__CastExpr_struct_eq(v__ast__CastExpr a, v__ast__CastExpr b); // auto
|
||
static bool v__ast__ChanInit_struct_eq(v__ast__ChanInit a, v__ast__ChanInit b); // auto
|
||
static bool v__ast__ComptimeCall_struct_eq(v__ast__ComptimeCall a, v__ast__ComptimeCall b); // auto
|
||
static bool v__ast__File_struct_eq(v__ast__File a, v__ast__File b); // auto
|
||
static bool v__ast__Module_struct_eq(v__ast__Module a, v__ast__Module b); // auto
|
||
static bool Array_v__ast__Import_arr_eq(Array_v__ast__Import a, Array_v__ast__Import b); // auto
|
||
static bool v__ast__Import_struct_eq(v__ast__Import a, v__ast__Import b); // auto
|
||
static bool Array_v__ast__ImportSymbol_arr_eq(Array_v__ast__ImportSymbol a, Array_v__ast__ImportSymbol b); // auto
|
||
static bool v__ast__ImportSymbol_struct_eq(v__ast__ImportSymbol a, v__ast__ImportSymbol b); // auto
|
||
static bool Array_v__ast__EmbeddedFile_arr_eq(Array_v__ast__EmbeddedFile a, Array_v__ast__EmbeddedFile b); // auto
|
||
static bool v__ast__EmbeddedFile_struct_eq(v__ast__EmbeddedFile a, v__ast__EmbeddedFile b); // auto
|
||
static bool Array_u8_arr_eq(Array_u8 a, Array_u8 b); // auto
|
||
static bool Map_string_string_map_eq(Map_string_string a, Map_string_string b); // auto
|
||
static bool Array_v__errors__Error_arr_eq(Array_v__errors__Error a, Array_v__errors__Error b); // auto
|
||
static bool v__errors__Error_struct_eq(v__errors__Error a, v__errors__Error b); // auto
|
||
static bool Array_v__errors__Warning_arr_eq(Array_v__errors__Warning a, Array_v__errors__Warning b); // auto
|
||
static bool v__errors__Warning_struct_eq(v__errors__Warning a, v__errors__Warning b); // auto
|
||
static bool Array_v__errors__Notice_arr_eq(Array_v__errors__Notice a, Array_v__errors__Notice b); // auto
|
||
static bool v__errors__Notice_struct_eq(v__errors__Notice a, v__errors__Notice b); // auto
|
||
static bool Array_v__ast__FnDecl_ptr_arr_eq(Array_v__ast__FnDecl_ptr a, Array_v__ast__FnDecl_ptr b); // auto
|
||
static bool v__ast__ComptimeSelector_struct_eq(v__ast__ComptimeSelector a, v__ast__ComptimeSelector b); // auto
|
||
static bool v__ast__ComptimeType_struct_eq(v__ast__ComptimeType a, v__ast__ComptimeType b); // auto
|
||
static bool v__ast__ConcatExpr_struct_eq(v__ast__ConcatExpr a, v__ast__ConcatExpr b); // auto
|
||
static bool v__ast__DumpExpr_struct_eq(v__ast__DumpExpr a, v__ast__DumpExpr b); // auto
|
||
static bool v__ast__EnumVal_struct_eq(v__ast__EnumVal a, v__ast__EnumVal b); // auto
|
||
static bool v__ast__GoExpr_struct_eq(v__ast__GoExpr a, v__ast__GoExpr b); // auto
|
||
static bool v__ast__IfExpr_struct_eq(v__ast__IfExpr a, v__ast__IfExpr b); // auto
|
||
static bool Array_v__ast__IfBranch_arr_eq(Array_v__ast__IfBranch a, Array_v__ast__IfBranch b); // auto
|
||
static bool v__ast__IfBranch_struct_eq(v__ast__IfBranch a, v__ast__IfBranch b); // auto
|
||
static bool v__ast__IfGuardExpr_struct_eq(v__ast__IfGuardExpr a, v__ast__IfGuardExpr b); // auto
|
||
static bool Array_v__ast__IfGuardVar_arr_eq(Array_v__ast__IfGuardVar a, Array_v__ast__IfGuardVar b); // auto
|
||
static bool v__ast__IfGuardVar_struct_eq(v__ast__IfGuardVar a, v__ast__IfGuardVar b); // auto
|
||
static bool v__ast__IndexExpr_struct_eq(v__ast__IndexExpr a, v__ast__IndexExpr b); // auto
|
||
static bool v__ast__InfixExpr_struct_eq(v__ast__InfixExpr a, v__ast__InfixExpr b); // auto
|
||
static bool v__ast__IsRefType_struct_eq(v__ast__IsRefType a, v__ast__IsRefType b); // auto
|
||
static bool v__ast__Likely_struct_eq(v__ast__Likely a, v__ast__Likely b); // auto
|
||
static bool v__ast__LockExpr_struct_eq(v__ast__LockExpr a, v__ast__LockExpr b); // auto
|
||
static bool Array_bool_arr_eq(Array_bool a, Array_bool b); // auto
|
||
static bool v__ast__MapInit_struct_eq(v__ast__MapInit a, v__ast__MapInit b); // auto
|
||
static bool v__ast__MatchExpr_struct_eq(v__ast__MatchExpr a, v__ast__MatchExpr b); // auto
|
||
static bool Array_v__ast__MatchBranch_arr_eq(Array_v__ast__MatchBranch a, Array_v__ast__MatchBranch b); // auto
|
||
static bool v__ast__MatchBranch_struct_eq(v__ast__MatchBranch a, v__ast__MatchBranch b); // auto
|
||
static bool v__ast__NodeError_struct_eq(v__ast__NodeError a, v__ast__NodeError b); // auto
|
||
static bool v__ast__None_struct_eq(v__ast__None a, v__ast__None b); // auto
|
||
static bool v__ast__OffsetOf_struct_eq(v__ast__OffsetOf a, v__ast__OffsetOf b); // auto
|
||
static bool v__ast__ParExpr_struct_eq(v__ast__ParExpr a, v__ast__ParExpr b); // auto
|
||
static bool v__ast__PostfixExpr_struct_eq(v__ast__PostfixExpr a, v__ast__PostfixExpr b); // auto
|
||
static bool v__ast__PrefixExpr_struct_eq(v__ast__PrefixExpr a, v__ast__PrefixExpr b); // auto
|
||
static bool v__ast__RangeExpr_struct_eq(v__ast__RangeExpr a, v__ast__RangeExpr b); // auto
|
||
static bool v__ast__SelectExpr_struct_eq(v__ast__SelectExpr a, v__ast__SelectExpr b); // auto
|
||
static bool Array_v__ast__SelectBranch_arr_eq(Array_v__ast__SelectBranch a, Array_v__ast__SelectBranch b); // auto
|
||
static bool v__ast__SelectBranch_struct_eq(v__ast__SelectBranch a, v__ast__SelectBranch b); // auto
|
||
static bool v__ast__SelectorExpr_struct_eq(v__ast__SelectorExpr a, v__ast__SelectorExpr b); // auto
|
||
static bool v__ast__SizeOf_struct_eq(v__ast__SizeOf a, v__ast__SizeOf b); // auto
|
||
static bool v__ast__SqlExpr_struct_eq(v__ast__SqlExpr a, v__ast__SqlExpr b); // auto
|
||
static bool v__ast__TypeNode_struct_eq(v__ast__TypeNode a, v__ast__TypeNode b); // auto
|
||
static bool Array_v__ast__StructField_arr_eq(Array_v__ast__StructField a, Array_v__ast__StructField b); // auto
|
||
static bool Map_int_v__ast__SqlExpr_map_eq(Map_int_v__ast__SqlExpr a, Map_int_v__ast__SqlExpr b); // auto
|
||
static bool v__ast__StringInterLiteral_struct_eq(v__ast__StringInterLiteral a, v__ast__StringInterLiteral b); // auto
|
||
static bool Array_int_arr_eq(Array_int a, Array_int b); // auto
|
||
static bool Array_v__token__Pos_arr_eq(Array_v__token__Pos a, Array_v__token__Pos b); // auto
|
||
static bool v__ast__StringLiteral_struct_eq(v__ast__StringLiteral a, v__ast__StringLiteral b); // auto
|
||
static bool v__ast__StructInit_struct_eq(v__ast__StructInit a, v__ast__StructInit b); // auto
|
||
static bool Array_v__ast__StructInitField_arr_eq(Array_v__ast__StructInitField a, Array_v__ast__StructInitField b); // auto
|
||
static bool v__ast__StructInitField_struct_eq(v__ast__StructInitField a, v__ast__StructInitField b); // auto
|
||
static bool Array_v__ast__StructInitEmbed_arr_eq(Array_v__ast__StructInitEmbed a, Array_v__ast__StructInitEmbed b); // auto
|
||
static bool v__ast__StructInitEmbed_struct_eq(v__ast__StructInitEmbed a, v__ast__StructInitEmbed b); // auto
|
||
static bool v__ast__TypeOf_struct_eq(v__ast__TypeOf a, v__ast__TypeOf b); // auto
|
||
static bool v__ast__UnsafeExpr_struct_eq(v__ast__UnsafeExpr a, v__ast__UnsafeExpr b); // auto
|
||
static bool v__ast__AssertStmt_struct_eq(v__ast__AssertStmt a, v__ast__AssertStmt b); // auto
|
||
static bool v__ast__AssignStmt_struct_eq(v__ast__AssignStmt a, v__ast__AssignStmt b); // auto
|
||
static bool v__ast__Block_struct_eq(v__ast__Block a, v__ast__Block b); // auto
|
||
static bool v__ast__BranchStmt_struct_eq(v__ast__BranchStmt a, v__ast__BranchStmt b); // auto
|
||
static bool v__ast__ComptimeFor_struct_eq(v__ast__ComptimeFor a, v__ast__ComptimeFor b); // auto
|
||
static bool v__ast__ConstDecl_struct_eq(v__ast__ConstDecl a, v__ast__ConstDecl b); // auto
|
||
static bool Array_v__ast__ConstField_arr_eq(Array_v__ast__ConstField a, Array_v__ast__ConstField b); // auto
|
||
static bool v__ast__EmptyStmt_struct_eq(v__ast__EmptyStmt a, v__ast__EmptyStmt b); // auto
|
||
static bool v__ast__EnumDecl_struct_eq(v__ast__EnumDecl a, v__ast__EnumDecl b); // auto
|
||
static bool Array_v__ast__EnumField_arr_eq(Array_v__ast__EnumField a, Array_v__ast__EnumField b); // auto
|
||
static bool v__ast__EnumField_struct_eq(v__ast__EnumField a, v__ast__EnumField b); // auto
|
||
static bool v__ast__ExprStmt_struct_eq(v__ast__ExprStmt a, v__ast__ExprStmt b); // auto
|
||
static bool v__ast__ForCStmt_struct_eq(v__ast__ForCStmt a, v__ast__ForCStmt b); // auto
|
||
static bool v__ast__ForInStmt_struct_eq(v__ast__ForInStmt a, v__ast__ForInStmt b); // auto
|
||
static bool v__ast__ForStmt_struct_eq(v__ast__ForStmt a, v__ast__ForStmt b); // auto
|
||
static bool v__ast__GlobalDecl_struct_eq(v__ast__GlobalDecl a, v__ast__GlobalDecl b); // auto
|
||
static bool Array_v__ast__GlobalField_arr_eq(Array_v__ast__GlobalField a, Array_v__ast__GlobalField b); // auto
|
||
static bool v__ast__GotoLabel_struct_eq(v__ast__GotoLabel a, v__ast__GotoLabel b); // auto
|
||
static bool v__ast__GotoStmt_struct_eq(v__ast__GotoStmt a, v__ast__GotoStmt b); // auto
|
||
static bool v__ast__HashStmt_struct_eq(v__ast__HashStmt a, v__ast__HashStmt b); // auto
|
||
static bool v__ast__InterfaceDecl_struct_eq(v__ast__InterfaceDecl a, v__ast__InterfaceDecl b); // auto
|
||
static bool Array_v__ast__FnDecl_arr_eq(Array_v__ast__FnDecl a, Array_v__ast__FnDecl b); // auto
|
||
static bool Array_v__ast__InterfaceEmbedding_arr_eq(Array_v__ast__InterfaceEmbedding a, Array_v__ast__InterfaceEmbedding b); // auto
|
||
static bool v__ast__InterfaceEmbedding_struct_eq(v__ast__InterfaceEmbedding a, v__ast__InterfaceEmbedding b); // auto
|
||
static bool v__ast__Return_struct_eq(v__ast__Return a, v__ast__Return b); // auto
|
||
static bool v__ast__SqlStmt_struct_eq(v__ast__SqlStmt a, v__ast__SqlStmt b); // auto
|
||
static bool Array_v__ast__SqlStmtLine_arr_eq(Array_v__ast__SqlStmtLine a, Array_v__ast__SqlStmtLine b); // auto
|
||
static bool v__ast__SqlStmtLine_struct_eq(v__ast__SqlStmtLine a, v__ast__SqlStmtLine b); // auto
|
||
static bool Map_int_v__ast__SqlStmtLine_map_eq(Map_int_v__ast__SqlStmtLine a, Map_int_v__ast__SqlStmtLine b); // auto
|
||
static bool v__ast__StructDecl_struct_eq(v__ast__StructDecl a, v__ast__StructDecl b); // auto
|
||
static bool Array_v__ast__Embed_arr_eq(Array_v__ast__Embed a, Array_v__ast__Embed b); // auto
|
||
static bool v__ast__Embed_struct_eq(v__ast__Embed a, v__ast__Embed b); // auto
|
||
static bool v__ast__TypeDecl_sumtype_eq(v__ast__TypeDecl a, v__ast__TypeDecl b); // auto
|
||
static bool v__ast__AliasTypeDecl_struct_eq(v__ast__AliasTypeDecl a, v__ast__AliasTypeDecl b); // auto
|
||
static bool v__ast__FnTypeDecl_struct_eq(v__ast__FnTypeDecl a, v__ast__FnTypeDecl b); // auto
|
||
static bool v__ast__SumTypeDecl_struct_eq(v__ast__SumTypeDecl a, v__ast__SumTypeDecl b); // auto
|
||
static bool Array_v__ast__TypeNode_arr_eq(Array_v__ast__TypeNode a, Array_v__ast__TypeNode b); // auto
|
||
static bool v__gen__c__StrType_struct_eq(v__gen__c__StrType a, v__gen__c__StrType b); // auto
|
||
static bool v__gen__c__SumtypeCastingFn_struct_eq(v__gen__c__SumtypeCastingFn a, v__gen__c__SumtypeCastingFn b); // auto
|
||
void v__ast__TypeSymbol_free(v__ast__TypeSymbol* it); // auto
|
||
void Array_v__ast__Fn_free(Array_v__ast__Fn* it); // auto
|
||
void v__ast__Fn_free(v__ast__Fn* it); // auto
|
||
void Array_v__ast__Param_free(Array_v__ast__Param* it); // auto
|
||
void v__ast__Param_free(v__ast__Param* it); // auto
|
||
void Array_v__ast__Attr_free(Array_v__ast__Attr* it); // auto
|
||
void v__ast__Attr_free(v__ast__Attr* it); // auto
|
||
|
||
// V global/const definitions:
|
||
string _const_math__bits__overflow_error; // a string literal, inited later
|
||
string _const_math__bits__divide_error; // a string literal, inited later
|
||
#define _const_strconv__digits 18
|
||
#define _const_strconv__int_size 32
|
||
#define _const_strconv__bias32 127
|
||
#define _const_strconv__maxexp32 255
|
||
#define _const_strconv__bias64 1023
|
||
#define _const_strconv__maxexp64 2047
|
||
#define _const_strconv__max_size_f64_char 32
|
||
string _const_strconv__digit_pairs; // a string literal, inited later
|
||
string _const_strconv__base_digits; // a string literal, inited later
|
||
#define _const_strconv__pow5_num_bits_32 61
|
||
#define _const_strconv__pow5_inv_num_bits_32 59
|
||
#define _const_strconv__pow5_num_bits_64 121
|
||
#define _const_strconv__pow5_inv_num_bits_64 122
|
||
string _const_digit_pairs; // a string literal, inited later
|
||
#define _const_hashbits 24
|
||
#define _const_max_cached_hashbits 16
|
||
#define _const_init_log_capicity 5
|
||
#define _const_init_capicity 32
|
||
#define _const_init_even_index 30
|
||
#define _const_extra_metas_inc 4
|
||
#define _const_prealloc_block_size 16777216
|
||
#define _const_degree 6
|
||
#define _const_mid_index 5
|
||
#define _const_max_len 11
|
||
string _const_si_s_code; // a string literal, inited later
|
||
string _const_si_g32_code; // a string literal, inited later
|
||
string _const_si_g64_code; // a string literal, inited later
|
||
#define _const_cp_utf8 65001
|
||
#define _const_v__token__max_keyword_len 20
|
||
string _const_time__days_string; // a string literal, inited later
|
||
string _const_time__months_string; // a string literal, inited later
|
||
#define _const_time__seconds_per_minute 60
|
||
#define _const_time__seconds_per_hour 3600
|
||
#define _const_time__seconds_per_day 86400
|
||
#define _const_time__seconds_per_week 604800
|
||
#define _const_time__days_per_400_years 146097
|
||
#define _const_time__days_per_100_years 36524
|
||
#define _const_time__days_per_4_years 1461
|
||
#define _const_time__days_in_year 365
|
||
#define _const_rand__constants__max_u32 4294967295
|
||
string _const_flag__space; // a string literal, inited later
|
||
string _const_flag__underline; // a string literal, inited later
|
||
#define _const_flag__max_args_number 4048
|
||
#define _const_semver__ver_major 0
|
||
#define _const_semver__ver_minor 1
|
||
#define _const_semver__ver_patch 2
|
||
string _const_semver__comparator_sep; // a string literal, inited later
|
||
string _const_semver__comparator_set_sep; // a string literal, inited later
|
||
string _const_semver__hyphen_range_sep; // a string literal, inited later
|
||
string _const_semver__x_range_symbols; // a string literal, inited later
|
||
#define _const_sync__stdatomic__used 1
|
||
#define _const_os__o_rdonly 0
|
||
#define _const_os__o_wronly 1
|
||
#define _const_os__o_rdwr 2
|
||
#define _const_os__o_binary 0
|
||
#define _const_os__o_create 64
|
||
#define _const_os__o_excl 128
|
||
#define _const_os__o_noctty 256
|
||
#define _const_os__o_trunc 512
|
||
#define _const_os__o_append 1024
|
||
#define _const_os__o_nonblock 2048
|
||
#define _const_os__o_sync 1052672
|
||
#define _const_os__bslash '\\'
|
||
string _const_os__fslash_str; // a string literal, inited later
|
||
string _const_os__dot_dot; // a string literal, inited later
|
||
string _const_os__empty_str; // a string literal, inited later
|
||
string _const_os__dot_str; // a string literal, inited later
|
||
#define _const_os__max_path_len 4096
|
||
#define _const_os__f_ok 0
|
||
#define _const_os__x_ok 1
|
||
#define _const_os__w_ok 2
|
||
#define _const_os__r_ok 4
|
||
#define _const_os__prot_read 1
|
||
#define _const_os__prot_write 2
|
||
#define _const_os__map_private 2
|
||
#define _const_os__map_anonymous 32
|
||
#define _const_os__sys_write 1
|
||
#define _const_os__sys_open 2
|
||
#define _const_os__sys_close 3
|
||
#define _const_os__sys_mkdir 83
|
||
#define _const_os__sys_creat 85
|
||
string _const_os__path_separator; // a string literal, inited later
|
||
string _const_os__path_delimiter; // a string literal, inited later
|
||
#define _const_os__stdin_value 0
|
||
#define _const_os__stdout_value 1
|
||
#define _const_os__stderr_value 2
|
||
#define _const_os__s_ifmt 61440
|
||
#define _const_os__s_ifdir 16384
|
||
#define _const_os__s_iflnk 40960
|
||
#define _const_os__s_isuid 2048
|
||
#define _const_os__s_isgid 1024
|
||
#define _const_os__s_isvtx 512
|
||
#define _const_os__s_irusr 256
|
||
#define _const_os__s_iwusr 128
|
||
#define _const_os__s_ixusr 64
|
||
#define _const_os__s_irgrp 32
|
||
#define _const_os__s_iwgrp 16
|
||
#define _const_os__s_ixgrp 8
|
||
#define _const_os__s_iroth 4
|
||
#define _const_os__s_iwoth 2
|
||
#define _const_os__s_ixoth 1
|
||
#define _const_term__default_columns_size 80
|
||
#define _const_term__default_rows_size 25
|
||
string _const_v__util__version__v_version; // a string literal, inited later
|
||
string _const_v__vmod__err_label; // a string literal, inited later
|
||
string _const_v__cflag__fexisting_literal; // a string literal, inited later
|
||
#define _const_rand__wyrand__seed_len 2
|
||
string _const_v__pkgconfig__version; // a string literal, inited later
|
||
string _const_rand__ulid_encoding; // a string literal, inited later
|
||
string _const_rand__english_letters; // a string literal, inited later
|
||
string _const_rand__hex_chars; // a string literal, inited later
|
||
string _const_rand__ascii_chars; // a string literal, inited later
|
||
#define _const_sync__aops_used 1
|
||
#define _const_sync__spinloops 750
|
||
#define _const_sync__spinloops_sem 4000
|
||
string _const_help__unknown_topic; // a string literal, inited later
|
||
#define _const_v__util__error_context_before 2
|
||
#define _const_v__util__error_context_after 2
|
||
#define _const_v__util__backslash 92
|
||
#define _const_v__util__backslash_r 13
|
||
#define _const_v__util__backslash_n 10
|
||
#define _const_v__util__double_quote 34
|
||
string _const_v__util__double_escape; // a string literal, inited later
|
||
string _const_v__util__map_prefix; // a string literal, inited later
|
||
#define _const_v__ast__invalid_type_idx -1
|
||
#define _const_v__ast__void_type_idx 1
|
||
#define _const_v__ast__voidptr_type_idx 2
|
||
#define _const_v__ast__byteptr_type_idx 3
|
||
#define _const_v__ast__charptr_type_idx 4
|
||
#define _const_v__ast__i8_type_idx 5
|
||
#define _const_v__ast__i16_type_idx 6
|
||
#define _const_v__ast__int_type_idx 7
|
||
#define _const_v__ast__i64_type_idx 8
|
||
#define _const_v__ast__isize_type_idx 9
|
||
#define _const_v__ast__byte_type_idx 10
|
||
#define _const_v__ast__u16_type_idx 11
|
||
#define _const_v__ast__u32_type_idx 12
|
||
#define _const_v__ast__u64_type_idx 13
|
||
#define _const_v__ast__usize_type_idx 14
|
||
#define _const_v__ast__f32_type_idx 15
|
||
#define _const_v__ast__f64_type_idx 16
|
||
#define _const_v__ast__char_type_idx 17
|
||
#define _const_v__ast__bool_type_idx 18
|
||
#define _const_v__ast__none_type_idx 19
|
||
#define _const_v__ast__string_type_idx 20
|
||
#define _const_v__ast__rune_type_idx 21
|
||
#define _const_v__ast__array_type_idx 22
|
||
#define _const_v__ast__map_type_idx 23
|
||
#define _const_v__ast__chan_type_idx 24
|
||
#define _const_v__ast__any_type_idx 25
|
||
#define _const_v__ast__float_literal_type_idx 26
|
||
#define _const_v__ast__int_literal_type_idx 27
|
||
#define _const_v__ast__thread_type_idx 28
|
||
#define _const_v__ast__error_type_idx 29
|
||
#define _const_v__checker__expr_level_cutoff_limit 40
|
||
#define _const_v__checker__stmt_level_cutoff_limit 40
|
||
#define _const_v__checker__iface_level_cutoff_limit 100
|
||
string _const_v__checker__vroot_is_deprecated_message; // a string literal, inited later
|
||
string _const_v__checker__unicode_lit_overflow_message; // a string literal, inited later
|
||
string _const_v__gen__c__si_s_code; // a string literal, inited later
|
||
string _const_v__gen__c__result_name; // a string literal, inited later
|
||
string _const_v__gen__c__option_name; // a string literal, inited later
|
||
string _const_v__gen__c__c_commit_hash_default; // a string literal, inited later
|
||
string _const_v__gen__c__c_current_commit_hash_default; // a string literal, inited later
|
||
string _const_v__gen__c__c_concurrency_helpers; // a string literal, inited later
|
||
string _const_v__gen__c__c_common_macros; // a string literal, inited later
|
||
string _const_v__gen__c__c_unsigned_comparison_functions; // a string literal, inited later
|
||
string _const_v__gen__c__c_helper_macros; // a string literal, inited later
|
||
string _const_v__gen__c__c_headers; // str inited later
|
||
string _const_v__gen__c__c_builtin_types; // a string literal, inited later
|
||
string _const_v__gen__c__c_bare_headers; // str inited later
|
||
string _const_v__gen__c__c_wyhash_headers; // a string literal, inited later
|
||
string _const_v__gen__c__closure_ctx; // a string literal, inited later
|
||
string _const_v__gen__c__posix_hotcode_definitions_1; // a string literal, inited later
|
||
string _const_v__gen__c__windows_hotcode_definitions_1; // a string literal, inited later
|
||
#define _const_v__scanner__single_quote '\''
|
||
#define _const_v__scanner__double_quote '"'
|
||
#define _const_v__scanner__b_lf 10
|
||
#define _const_v__scanner__b_cr 13
|
||
#define _const_v__scanner__backslash '\\'
|
||
#define _const_v__parser__max_expr_level 100
|
||
#define _const_v__parser__maximum_inline_sum_type_variants 3
|
||
string _const_v__parser__tmpl_str_end; // a string literal, inited later
|
||
string _const_v__builder__c_verror_message_marker; // a string literal, inited later
|
||
string _const_v__builder__c_error_info; // a string literal, inited later
|
||
string _const_v__builder__no_compiler_error; // a string literal, inited later
|
||
#define _const_v__builder__key_query_value 1
|
||
#define _const_v__builder__key_wow64_32key 512
|
||
#define _const_v__builder__key_enumerate_sub_keys 8
|
||
u32 _const_math__bits__de_bruijn32 = 125613361; // precomputed
|
||
Array_u8 _const_math__bits__de_bruijn32tab; // inited later
|
||
u64 _const_math__bits__de_bruijn64 = 285870213051353865U; // precomputed
|
||
Array_u8 _const_math__bits__de_bruijn64tab; // inited later
|
||
u64 _const_math__bits__m0 = 6148914691236517205U; // precomputed
|
||
u64 _const_math__bits__m1 = 3689348814741910323U; // precomputed
|
||
u64 _const_math__bits__m2 = 1085102592571150095U; // precomputed
|
||
u64 _const_math__bits__m3 = 71777214294589695U; // precomputed
|
||
u64 _const_math__bits__m4 = 281470681808895U; // precomputed
|
||
u32 _const_math__bits__max_u32 = 4294967295; // precomputed
|
||
u64 _const_math__bits__max_u64 = 18446744073709551615U; // precomputed
|
||
u8 _const_math__bits__n8 = 8; // precomputed
|
||
u16 _const_math__bits__n16 = 16; // precomputed
|
||
u32 _const_math__bits__n32 = 32; // precomputed
|
||
u64 _const_math__bits__n64 = 64U; // precomputed
|
||
u64 _const_math__bits__two32 = 4294967296U; // precomputed
|
||
u64 _const_math__bits__mask32 = 4294967295U; // precomputed
|
||
Array_u8 _const_math__bits__ntz_8_tab; // inited later
|
||
Array_u8 _const_math__bits__pop_8_tab; // inited later
|
||
Array_u8 _const_math__bits__rev_8_tab; // inited later
|
||
Array_u8 _const_math__bits__len_8_tab; // inited later
|
||
u32 _const_strconv__single_plus_zero = 0; // precomputed
|
||
u32 _const_strconv__single_minus_zero = 2147483648; // precomputed
|
||
u32 _const_strconv__single_plus_infinity = 2139095040; // precomputed
|
||
u32 _const_strconv__single_minus_infinity = 4286578688; // precomputed
|
||
u64 _const_strconv__double_plus_zero = 0U; // precomputed
|
||
u64 _const_strconv__double_minus_zero = 9223372036854775808U; // precomputed
|
||
u64 _const_strconv__double_plus_infinity = 9218868437227405312U; // precomputed
|
||
u64 _const_strconv__double_minus_infinity = 18442240474082181120U; // precomputed
|
||
rune _const_strconv__c_dpoint = '.'; // precomputed
|
||
rune _const_strconv__c_plus = '+'; // precomputed
|
||
rune _const_strconv__c_minus = '-'; // precomputed
|
||
rune _const_strconv__c_zero = '0'; // precomputed
|
||
rune _const_strconv__c_nine = '9'; // precomputed
|
||
u32 _const_strconv__c_ten = 10; // precomputed
|
||
Array_u64 _const_strconv__pos_exp; // inited later
|
||
Array_u64 _const_strconv__neg_exp; // inited later
|
||
u64 _const_strconv__max_u64 = 18446744073709551615U; // precomputed
|
||
Array_u32 _const_strconv__ten_pow_table_32; // inited later
|
||
u32 _const_strconv__mantbits32 = 23; // precomputed
|
||
u32 _const_strconv__expbits32 = 8; // precomputed
|
||
Array_u64 _const_strconv__ten_pow_table_64; // inited later
|
||
u32 _const_strconv__mantbits64 = 52; // precomputed
|
||
u32 _const_strconv__expbits64 = 11; // precomputed
|
||
Array_f64 _const_strconv__dec_round; // inited later
|
||
Array_u64 _const_strconv__powers_of_10; // inited later
|
||
Array_u64 _const_strconv__pow5_split_32; // inited later
|
||
Array_u64 _const_strconv__pow5_inv_split_32; // inited later
|
||
Array_strconv__Uint128 _const_strconv__pow5_split_64; // inited later
|
||
Array_strconv__Uint128 _const_strconv__pow5_inv_split_64; // inited later
|
||
i64 total_m = ((i64)(0)); // global4
|
||
|
||
int g_main_argc = ((int)(0)); // global4
|
||
|
||
voidptr g_main_argv = ((voidptr)(0)); // global4
|
||
|
||
Array_VCastTypeIndexName as_cast_type_indexes; // global4
|
||
|
||
f64 _const_max_load_factor = 0.8; // precomputed
|
||
u32 _const_hash_mask = 16777215; // precomputed
|
||
u32 _const_probe_inc = 16777216; // precomputed
|
||
IError _const_none__; // inited later
|
||
VMemoryBlock* g_memory_block; // global4
|
||
|
||
Array_v__token__Kind _const_v__token__assign_tokens; // inited later
|
||
Array_string _const_v__token__valid_at_tokens; // inited later
|
||
Array_string _const_v__token__token_str; // inited later
|
||
Map_string_v__token__Kind _const_v__token__keywords; // inited later
|
||
Array_v__token__Precedence _const_v__token__precedences; // inited later
|
||
Array_string _const_time__tokens_2; // inited later
|
||
Array_string _const_time__tokens_3; // inited later
|
||
Array_string _const_time__tokens_4; // inited later
|
||
Array_string _const_time__long_days; // inited later
|
||
Array_int _const_time__month_days; // inited later
|
||
Array_string _const_time__long_months; // inited later
|
||
i64 _const_time__absolute_zero_year; // inited later
|
||
Array_int _const_time__days_before; // inited later
|
||
time__Duration _const_time__nanosecond; // inited later
|
||
time__Duration _const_time__infinite; // inited later
|
||
u64 _const_hash__wyp0 = 11562461410679940143U; // precomputed
|
||
u64 _const_hash__wyp1 = 16646288086500911323U; // precomputed
|
||
u64 _const_hash__wyp2 = 10285213230658275043U; // precomputed
|
||
u64 _const_hash__wyp3 = 6384245875588680899U; // precomputed
|
||
u64 _const_hash__wyp4 = 2129725606500045391U; // precomputed
|
||
u64 _const_rand__constants__lower_mask = 4294967295U; // precomputed
|
||
u64 _const_rand__constants__max_u64 = 18446744073709551615U; // precomputed
|
||
u32 _const_rand__constants__u31_mask = 2147483647; // precomputed
|
||
u64 _const_rand__constants__u63_mask = 9223372036854775807U; // precomputed
|
||
u64 _const_hash__fnv1a__fnv64_prime = 1099511628211U; // precomputed
|
||
u64 _const_hash__fnv1a__fnv64_offset_basis = 14695981039346656037U; // precomputed
|
||
u32 _const_hash__fnv1a__fnv32_offset_basis = 2166136261; // precomputed
|
||
u32 _const_hash__fnv1a__fnv32_prime = 16777619; // precomputed
|
||
rune _const_os__fslash = '/'; // precomputed
|
||
rune _const_os__dot = '.'; // precomputed
|
||
rune _const_os__qmark = '?'; // precomputed
|
||
Array_string _const_os__args; // inited later
|
||
string _const_os__wd_at_startup; // inited later
|
||
Array_string _const_os__executable_suffixes; // inited later
|
||
Array_string _const_v__vmod__mod_file_stop_paths; // inited later
|
||
v__vmod__ModFileCacher* _const_v__vmod__private_file_cacher; // inited later
|
||
u64 _const_rand__wyrand__wyp0 = 11562461410679940143U; // precomputed
|
||
u64 _const_rand__wyrand__wyp1 = 16646288086500911323U; // precomputed
|
||
Array_string _const_v__pkgconfig__default_paths; // inited later
|
||
f64 _const_rand__sqrt2 = 1.4142135623730951; // precomputed
|
||
Array_rune _const_rand__clock_seq_hi_and_reserved_valid_values; // inited later
|
||
rand__PRNG* default_rng; // global4
|
||
|
||
Array_string _const_v__pref__list_of_flags_with_param; // inited later
|
||
v__util__EManager* _const_v__util__emanager; // inited later
|
||
string _const_v__util__normalised_workdir; // inited later
|
||
v__util__LinesCache* lines_cache; // global4
|
||
|
||
Array_u8 _const_v__util__invalid_escapes; // inited later
|
||
v__util__Timers* g_timers; // global4
|
||
|
||
Array_string _const_v__util__builtin_module_parts; // inited later
|
||
Array_string _const_v__util__bundle_modules; // inited later
|
||
Map_string_Array_string _const_v__util__external_module_dependencies_for_tool; // inited later
|
||
Array_string _const_v__util__const_tabs; // inited later
|
||
voidptr _const_sync__pool__no_result; // inited later
|
||
Map_int_Array_string _const_v__ast__x86_no_number_register_list; // inited later
|
||
Map_int_Map_string_int _const_v__ast__x86_with_number_register_list; // inited later
|
||
Array_string _const_v__ast__arm_no_number_register_list; // inited later
|
||
Map_string_int _const_v__ast__arm_with_number_register_list; // inited later
|
||
Array_string _const_v__ast__riscv_no_number_register_list; // inited later
|
||
Map_string_int _const_v__ast__riscv_with_number_register_list; // inited later
|
||
Array_string _const_v__ast__native_builtins; // inited later
|
||
v__ast__Table* global_table = ((v__ast__Table*)(0)); // global4
|
||
|
||
Array_string _const_v__ast__builtin_type_names; // inited later
|
||
v__ast__Type _const_v__ast__ovoid_type; // inited later
|
||
v__ast__Type _const_v__ast__rvoid_type; // inited later
|
||
int _const_v__checker__int_min; // inited later
|
||
int _const_v__checker__int_max = 2147483647; // precomputed
|
||
Array_string _const_v__checker__valid_comptime_if_os; // inited later
|
||
Array_string _const_v__checker__valid_comptime_compression_types; // inited later
|
||
Array_string _const_v__checker__valid_comptime_if_compilers; // inited later
|
||
Array_string _const_v__checker__valid_comptime_if_platforms; // inited later
|
||
Array_string _const_v__checker__valid_comptime_if_cpu_features; // inited later
|
||
Array_string _const_v__checker__valid_comptime_if_other; // inited later
|
||
Array_string _const_v__checker__array_builtin_methods; // inited later
|
||
Array_string _const_v__checker__reserved_type_names; // inited later
|
||
IError _const_v__gen__c__unsupported_ctemp_assert_transform; // inited later
|
||
Array_string _const_v__gen__c__c_reserved; // inited later
|
||
Array_string _const_v__gen__c__cmp_str; // inited later
|
||
Array_string _const_v__gen__c__cmp_rev; // inited later
|
||
Array_string _const_v__gen__c__skip_struct_init; // inited later
|
||
rune _const_v__scanner__num_sep = '_'; // precomputed
|
||
Array_string _const_v__parser__supported_comptime_calls; // inited later
|
||
Array_string _const_v__parser__comptime_types; // inited later
|
||
Array_v__ast__File_ptr codegen_files; // global4
|
||
|
||
Array_v__token__Kind _const_v__parser__valid_tokens_inside_types; // inited later
|
||
v__builder__RegKey _const_v__builder__hkey_local_machine; // inited later
|
||
Array_string _const_main__external_tools; // inited later
|
||
Array_string _const_main__list_of_flags_that_allow_duplicates; // inited later
|
||
u32 _const_children_bytes; // inited later
|
||
v__token__KeywordsMatcher _const_v__token__matcher; // inited later
|
||
time__Duration _const_time__microsecond; // inited later
|
||
f32 _const_rand__constants__max_u32_as_f32; // inited later
|
||
f64 _const_rand__constants__max_u64_as_f64; // inited later
|
||
Array_int _const_semver__versions; // inited later
|
||
string _const_v__pref__default_module_path; // inited later
|
||
v__ast__TypeSymbol* _const_v__ast__invalid_type_symbol; // inited later
|
||
v__token__KeywordsMatcher _const_v__ast__builtin_type_names_matcher; // inited later
|
||
Array_int _const_v__ast__integer_type_idxs; // inited later
|
||
Array_int _const_v__ast__signed_integer_type_idxs; // inited later
|
||
Array_int _const_v__ast__unsigned_integer_type_idxs; // inited later
|
||
Array_int _const_v__ast__int_promoted_type_idxs; // inited later
|
||
Array_int _const_v__ast__float_type_idxs; // inited later
|
||
Array_int _const_v__ast__number_type_idxs; // inited later
|
||
Array_int _const_v__ast__pointer_type_idxs; // inited later
|
||
Array_int _const_v__ast__string_type_idxs; // inited later
|
||
v__ast__Type _const_v__ast__void_type; // inited later
|
||
v__ast__Type _const_v__ast__voidptr_type; // inited later
|
||
v__ast__Type _const_v__ast__byteptr_type; // inited later
|
||
v__ast__Type _const_v__ast__charptr_type; // inited later
|
||
v__ast__Type _const_v__ast__i8_type; // inited later
|
||
v__ast__Type _const_v__ast__int_type; // inited later
|
||
v__ast__Type _const_v__ast__i16_type; // inited later
|
||
v__ast__Type _const_v__ast__i64_type; // inited later
|
||
v__ast__Type _const_v__ast__isize_type; // inited later
|
||
v__ast__Type _const_v__ast__byte_type; // inited later
|
||
v__ast__Type _const_v__ast__u16_type; // inited later
|
||
v__ast__Type _const_v__ast__u32_type; // inited later
|
||
v__ast__Type _const_v__ast__u64_type; // inited later
|
||
v__ast__Type _const_v__ast__usize_type; // inited later
|
||
v__ast__Type _const_v__ast__f32_type; // inited later
|
||
v__ast__Type _const_v__ast__f64_type; // inited later
|
||
v__ast__Type _const_v__ast__char_type; // inited later
|
||
v__ast__Type _const_v__ast__bool_type; // inited later
|
||
v__ast__Type _const_v__ast__none_type; // inited later
|
||
v__ast__Type _const_v__ast__string_type; // inited later
|
||
v__ast__Type _const_v__ast__rune_type; // inited later
|
||
v__ast__Type _const_v__ast__array_type; // inited later
|
||
v__ast__Type _const_v__ast__map_type; // inited later
|
||
v__ast__Type _const_v__ast__chan_type; // inited later
|
||
v__ast__Type _const_v__ast__any_type; // inited later
|
||
v__ast__Type _const_v__ast__float_literal_type; // inited later
|
||
v__ast__Type _const_v__ast__int_literal_type; // inited later
|
||
v__ast__Type _const_v__ast__thread_type; // inited later
|
||
v__ast__Type _const_v__ast__error_type; // inited later
|
||
Array_string _const_v__checker__valid_comptime_not_user_defined; // inited later
|
||
Map_string_bool _const_v__gen__c__c_reserved_map; // inited later
|
||
Array_string _const_v__gen__c__builtins; // inited later
|
||
time__Duration _const_time__millisecond; // inited later
|
||
Array_v__ast__Type _const_v__ast__charptr_types; // inited later
|
||
Array_v__ast__Type _const_v__ast__byteptr_types; // inited later
|
||
Array_v__ast__Type _const_v__ast__voidptr_types; // inited later
|
||
time__Duration _const_time__second; // inited later
|
||
Array_v__ast__Type _const_v__ast__cptr_types; // inited later
|
||
time__Duration _const_time__minute; // inited later
|
||
time__Duration _const_time__hour; // inited later
|
||
|
||
// V interface table:
|
||
static IError I_None___to_Interface_IError(None__* x);
|
||
const int _IError_None___index = 0;
|
||
static IError I_Error_to_Interface_IError(Error* x);
|
||
const int _IError_Error_index = 1;
|
||
static IError I_MessageError_to_Interface_IError(MessageError* x);
|
||
const int _IError_MessageError_index = 2;
|
||
static IError I_time__TimeParseError_to_Interface_IError(time__TimeParseError* x);
|
||
const int _IError_time__TimeParseError_index = 3;
|
||
static IError I_flag__UnkownFlagError_to_Interface_IError(flag__UnkownFlagError* x);
|
||
const int _IError_flag__UnkownFlagError_index = 4;
|
||
static IError I_flag__ArgsCountError_to_Interface_IError(flag__ArgsCountError* x);
|
||
const int _IError_flag__ArgsCountError_index = 5;
|
||
static IError I_semver__InvalidComparatorFormatError_to_Interface_IError(semver__InvalidComparatorFormatError* x);
|
||
const int _IError_semver__InvalidComparatorFormatError_index = 6;
|
||
static IError I_semver__EmptyInputError_to_Interface_IError(semver__EmptyInputError* x);
|
||
const int _IError_semver__EmptyInputError_index = 7;
|
||
static IError I_semver__InvalidVersionFormatError_to_Interface_IError(semver__InvalidVersionFormatError* x);
|
||
const int _IError_semver__InvalidVersionFormatError_index = 8;
|
||
static IError I_os__FileNotOpenedError_to_Interface_IError(os__FileNotOpenedError* x);
|
||
const int _IError_os__FileNotOpenedError_index = 9;
|
||
static IError I_os__SizeOfTypeIs0Error_to_Interface_IError(os__SizeOfTypeIs0Error* x);
|
||
const int _IError_os__SizeOfTypeIs0Error_index = 10;
|
||
static IError I_os__ExecutableNotFoundError_to_Interface_IError(os__ExecutableNotFoundError* x);
|
||
const int _IError_os__ExecutableNotFoundError_index = 11;
|
||
static IError I_v__gen__c__UnsupportedAssertCtempTransform_to_Interface_IError(v__gen__c__UnsupportedAssertCtempTransform* x);
|
||
const int _IError_v__gen__c__UnsupportedAssertCtempTransform_index = 12;
|
||
// ^^^ number of types for interface IError: 13
|
||
|
||
// Methods wrapper for interface "IError"
|
||
static inline string None___msg_Interface_IError_method_wrapper(None__* err) {
|
||
return Error_msg(err->Error);
|
||
}
|
||
static inline int None___code_Interface_IError_method_wrapper(None__* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string Error_msg_Interface_IError_method_wrapper(Error* err) {
|
||
return Error_msg(*err);
|
||
}
|
||
static inline int Error_code_Interface_IError_method_wrapper(Error* err) {
|
||
return Error_code(*err);
|
||
}
|
||
static inline string MessageError_msg_Interface_IError_method_wrapper(MessageError* err) {
|
||
return MessageError_msg(*err);
|
||
}
|
||
static inline int MessageError_code_Interface_IError_method_wrapper(MessageError* err) {
|
||
return MessageError_code(*err);
|
||
}
|
||
static inline string time__TimeParseError_msg_Interface_IError_method_wrapper(time__TimeParseError* err) {
|
||
return time__TimeParseError_msg(*err);
|
||
}
|
||
static inline int time__TimeParseError_code_Interface_IError_method_wrapper(time__TimeParseError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string flag__UnkownFlagError_msg_Interface_IError_method_wrapper(flag__UnkownFlagError* err) {
|
||
return flag__UnkownFlagError_msg(*err);
|
||
}
|
||
static inline int flag__UnkownFlagError_code_Interface_IError_method_wrapper(flag__UnkownFlagError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string flag__ArgsCountError_msg_Interface_IError_method_wrapper(flag__ArgsCountError* err) {
|
||
return flag__ArgsCountError_msg(*err);
|
||
}
|
||
static inline int flag__ArgsCountError_code_Interface_IError_method_wrapper(flag__ArgsCountError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string semver__InvalidComparatorFormatError_msg_Interface_IError_method_wrapper(semver__InvalidComparatorFormatError* err) {
|
||
return MessageError_msg(err->MessageError);
|
||
}
|
||
static inline int semver__InvalidComparatorFormatError_code_Interface_IError_method_wrapper(semver__InvalidComparatorFormatError* err) {
|
||
return MessageError_code(err->MessageError);
|
||
}
|
||
static inline string semver__EmptyInputError_msg_Interface_IError_method_wrapper(semver__EmptyInputError* err) {
|
||
return semver__EmptyInputError_msg(*err);
|
||
}
|
||
static inline int semver__EmptyInputError_code_Interface_IError_method_wrapper(semver__EmptyInputError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string semver__InvalidVersionFormatError_msg_Interface_IError_method_wrapper(semver__InvalidVersionFormatError* err) {
|
||
return semver__InvalidVersionFormatError_msg(*err);
|
||
}
|
||
static inline int semver__InvalidVersionFormatError_code_Interface_IError_method_wrapper(semver__InvalidVersionFormatError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string os__FileNotOpenedError_msg_Interface_IError_method_wrapper(os__FileNotOpenedError* err) {
|
||
return os__FileNotOpenedError_msg(*err);
|
||
}
|
||
static inline int os__FileNotOpenedError_code_Interface_IError_method_wrapper(os__FileNotOpenedError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string os__SizeOfTypeIs0Error_msg_Interface_IError_method_wrapper(os__SizeOfTypeIs0Error* err) {
|
||
return os__SizeOfTypeIs0Error_msg(*err);
|
||
}
|
||
static inline int os__SizeOfTypeIs0Error_code_Interface_IError_method_wrapper(os__SizeOfTypeIs0Error* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string os__ExecutableNotFoundError_msg_Interface_IError_method_wrapper(os__ExecutableNotFoundError* err) {
|
||
return os__ExecutableNotFoundError_msg(*err);
|
||
}
|
||
static inline int os__ExecutableNotFoundError_code_Interface_IError_method_wrapper(os__ExecutableNotFoundError* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
static inline string v__gen__c__UnsupportedAssertCtempTransform_msg_Interface_IError_method_wrapper(v__gen__c__UnsupportedAssertCtempTransform* err) {
|
||
return Error_msg(err->Error);
|
||
}
|
||
static inline int v__gen__c__UnsupportedAssertCtempTransform_code_Interface_IError_method_wrapper(v__gen__c__UnsupportedAssertCtempTransform* err) {
|
||
return Error_code(err->Error);
|
||
}
|
||
|
||
struct _IError_interface_methods {
|
||
string (*_method_msg)(void* _);
|
||
int (*_method_code)(void* _);
|
||
};
|
||
|
||
struct _IError_interface_methods IError_name_table[13] = {
|
||
{
|
||
._method_msg = (void*) None___msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) None___code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) Error_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) Error_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) MessageError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) MessageError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) time__TimeParseError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) time__TimeParseError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) flag__UnkownFlagError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) flag__UnkownFlagError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) flag__ArgsCountError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) flag__ArgsCountError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) semver__InvalidComparatorFormatError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) semver__InvalidComparatorFormatError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) semver__EmptyInputError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) semver__EmptyInputError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) semver__InvalidVersionFormatError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) semver__InvalidVersionFormatError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) os__FileNotOpenedError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) os__FileNotOpenedError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) os__SizeOfTypeIs0Error_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) os__SizeOfTypeIs0Error_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) os__ExecutableNotFoundError_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) os__ExecutableNotFoundError_code_Interface_IError_method_wrapper,
|
||
},
|
||
{
|
||
._method_msg = (void*) v__gen__c__UnsupportedAssertCtempTransform_msg_Interface_IError_method_wrapper,
|
||
._method_code = (void*) v__gen__c__UnsupportedAssertCtempTransform_code_Interface_IError_method_wrapper,
|
||
},
|
||
};
|
||
|
||
|
||
// Casting functions for converting "None__" to interface "IError"
|
||
static inline IError I_None___to_Interface_IError(None__* x) {
|
||
return (IError) {
|
||
._None__ = x,
|
||
._typ = _IError_None___index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "Error" to interface "IError"
|
||
static inline IError I_Error_to_Interface_IError(Error* x) {
|
||
return (IError) {
|
||
._Error = x,
|
||
._typ = _IError_Error_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "MessageError" to interface "IError"
|
||
static inline IError I_MessageError_to_Interface_IError(MessageError* x) {
|
||
return (IError) {
|
||
._MessageError = x,
|
||
._typ = _IError_MessageError_index,
|
||
.msg = (string*)((char*)x + __offsetof_ptr(x, MessageError, msg)),
|
||
.code = (int*)((char*)x + __offsetof_ptr(x, MessageError, code)),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "time__TimeParseError" to interface "IError"
|
||
static inline IError I_time__TimeParseError_to_Interface_IError(time__TimeParseError* x) {
|
||
return (IError) {
|
||
._time__TimeParseError = x,
|
||
._typ = _IError_time__TimeParseError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x + __offsetof_ptr(x, time__TimeParseError, code)),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "flag__UnkownFlagError" to interface "IError"
|
||
static inline IError I_flag__UnkownFlagError_to_Interface_IError(flag__UnkownFlagError* x) {
|
||
return (IError) {
|
||
._flag__UnkownFlagError = x,
|
||
._typ = _IError_flag__UnkownFlagError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "flag__ArgsCountError" to interface "IError"
|
||
static inline IError I_flag__ArgsCountError_to_Interface_IError(flag__ArgsCountError* x) {
|
||
return (IError) {
|
||
._flag__ArgsCountError = x,
|
||
._typ = _IError_flag__ArgsCountError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "semver__InvalidComparatorFormatError" to interface "IError"
|
||
static inline IError I_semver__InvalidComparatorFormatError_to_Interface_IError(semver__InvalidComparatorFormatError* x) {
|
||
return (IError) {
|
||
._semver__InvalidComparatorFormatError = x,
|
||
._typ = _IError_semver__InvalidComparatorFormatError_index,
|
||
.msg = (string*)((char*)x + __offsetof_ptr(x, semver__InvalidComparatorFormatError, MessageError) + __offsetof_ptr(x, MessageError, msg)),
|
||
.code = (int*)((char*)x + __offsetof_ptr(x, semver__InvalidComparatorFormatError, MessageError) + __offsetof_ptr(x, MessageError, code)),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "semver__EmptyInputError" to interface "IError"
|
||
static inline IError I_semver__EmptyInputError_to_Interface_IError(semver__EmptyInputError* x) {
|
||
return (IError) {
|
||
._semver__EmptyInputError = x,
|
||
._typ = _IError_semver__EmptyInputError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "semver__InvalidVersionFormatError" to interface "IError"
|
||
static inline IError I_semver__InvalidVersionFormatError_to_Interface_IError(semver__InvalidVersionFormatError* x) {
|
||
return (IError) {
|
||
._semver__InvalidVersionFormatError = x,
|
||
._typ = _IError_semver__InvalidVersionFormatError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "os__FileNotOpenedError" to interface "IError"
|
||
static inline IError I_os__FileNotOpenedError_to_Interface_IError(os__FileNotOpenedError* x) {
|
||
return (IError) {
|
||
._os__FileNotOpenedError = x,
|
||
._typ = _IError_os__FileNotOpenedError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "os__SizeOfTypeIs0Error" to interface "IError"
|
||
static inline IError I_os__SizeOfTypeIs0Error_to_Interface_IError(os__SizeOfTypeIs0Error* x) {
|
||
return (IError) {
|
||
._os__SizeOfTypeIs0Error = x,
|
||
._typ = _IError_os__SizeOfTypeIs0Error_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "os__ExecutableNotFoundError" to interface "IError"
|
||
static inline IError I_os__ExecutableNotFoundError_to_Interface_IError(os__ExecutableNotFoundError* x) {
|
||
return (IError) {
|
||
._os__ExecutableNotFoundError = x,
|
||
._typ = _IError_os__ExecutableNotFoundError_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "v__gen__c__UnsupportedAssertCtempTransform" to interface "IError"
|
||
static inline IError I_v__gen__c__UnsupportedAssertCtempTransform_to_Interface_IError(v__gen__c__UnsupportedAssertCtempTransform* x) {
|
||
return (IError) {
|
||
._v__gen__c__UnsupportedAssertCtempTransform = x,
|
||
._typ = _IError_v__gen__c__UnsupportedAssertCtempTransform_index,
|
||
.msg = (string*)((char*)x),
|
||
.code = (int*)((char*)x),
|
||
};
|
||
}
|
||
|
||
static rand__PRNG I_rand__wyrand__WyRandRNG_to_Interface_rand__PRNG(rand__wyrand__WyRandRNG* x);
|
||
const int _rand__PRNG_rand__wyrand__WyRandRNG_index = 0;
|
||
// ^^^ number of types for interface rand__PRNG: 1
|
||
|
||
// Methods wrapper for interface "rand__PRNG"
|
||
|
||
struct _rand__PRNG_interface_methods {
|
||
void (*_method_seed)(void* _, Array_u32 seed_data);
|
||
u8 (*_method_u8)(void* _);
|
||
u16 (*_method_u16)(void* _);
|
||
u32 (*_method_u32)(void* _);
|
||
u64 (*_method_u64)(void* _);
|
||
int (*_method_block_size)(void* _);
|
||
void (*_method__v_free)(void* _);
|
||
};
|
||
|
||
struct _rand__PRNG_interface_methods rand__PRNG_name_table[1] = {
|
||
{
|
||
._method_seed = (void*) rand__wyrand__WyRandRNG_seed,
|
||
._method_u8 = (void*) rand__wyrand__WyRandRNG_u8,
|
||
._method_u16 = (void*) rand__wyrand__WyRandRNG_u16,
|
||
._method_u32 = (void*) rand__wyrand__WyRandRNG_u32,
|
||
._method_u64 = (void*) rand__wyrand__WyRandRNG_u64,
|
||
._method_block_size = (void*) rand__wyrand__WyRandRNG_block_size,
|
||
._method__v_free = (void*) rand__wyrand__WyRandRNG_free,
|
||
},
|
||
};
|
||
|
||
|
||
// Casting functions for converting "rand__wyrand__WyRandRNG" to interface "rand__PRNG"
|
||
static inline rand__PRNG I_rand__wyrand__WyRandRNG_to_Interface_rand__PRNG(rand__wyrand__WyRandRNG* x) {
|
||
return (rand__PRNG) {
|
||
._rand__wyrand__WyRandRNG = x,
|
||
._typ = _rand__PRNG_rand__wyrand__WyRandRNG_index,
|
||
};
|
||
}
|
||
|
||
// ^^^ number of types for interface hash__Hasher: 0
|
||
|
||
// Methods wrapper for interface "hash__Hasher"
|
||
|
||
struct _hash__Hasher_interface_methods {
|
||
Array_u8 (*_method_sum)(void* _, Array_u8 b);
|
||
int (*_method_size)(void* _);
|
||
int (*_method_block_size)(void* _);
|
||
};
|
||
|
||
struct _hash__Hasher_interface_methods hash__Hasher_name_table[1];
|
||
|
||
|
||
|
||
// ^^^ number of types for interface hash__Hash32er: 0
|
||
|
||
// Methods wrapper for interface "hash__Hash32er"
|
||
|
||
struct _hash__Hash32er_interface_methods {
|
||
u32 (*_method_sum32)(void* _);
|
||
};
|
||
|
||
struct _hash__Hash32er_interface_methods hash__Hash32er_name_table[1];
|
||
|
||
|
||
|
||
// ^^^ number of types for interface hash__Hash64er: 0
|
||
|
||
// Methods wrapper for interface "hash__Hash64er"
|
||
|
||
struct _hash__Hash64er_interface_methods {
|
||
u64 (*_method_sum64)(void* _);
|
||
};
|
||
|
||
struct _hash__Hash64er_interface_methods hash__Hash64er_name_table[1];
|
||
|
||
|
||
|
||
static v__ast__walker__Visitor I_v__ast__walker__Inspector_to_Interface_v__ast__walker__Visitor(v__ast__walker__Inspector* x);
|
||
const int _v__ast__walker__Visitor_v__ast__walker__Inspector_index = 0;
|
||
static v__ast__walker__Visitor I_v__callgraph__Mapper_to_Interface_v__ast__walker__Visitor(v__callgraph__Mapper* x);
|
||
const int _v__ast__walker__Visitor_v__callgraph__Mapper_index = 1;
|
||
// ^^^ number of types for interface v__ast__walker__Visitor: 2
|
||
|
||
// Methods wrapper for interface "v__ast__walker__Visitor"
|
||
|
||
struct _v__ast__walker__Visitor_interface_methods {
|
||
_option_void (*_method_visit)(void* _, v__ast__Node* node);
|
||
};
|
||
|
||
struct _v__ast__walker__Visitor_interface_methods v__ast__walker__Visitor_name_table[2] = {
|
||
{
|
||
._method_visit = (void*) v__ast__walker__Inspector_visit,
|
||
},
|
||
{
|
||
._method_visit = (void*) v__callgraph__Mapper_visit,
|
||
},
|
||
};
|
||
|
||
|
||
// Casting functions for converting "v__ast__walker__Inspector" to interface "v__ast__walker__Visitor"
|
||
static inline v__ast__walker__Visitor I_v__ast__walker__Inspector_to_Interface_v__ast__walker__Visitor(v__ast__walker__Inspector* x) {
|
||
return (v__ast__walker__Visitor) {
|
||
._v__ast__walker__Inspector = x,
|
||
._typ = _v__ast__walker__Visitor_v__ast__walker__Inspector_index,
|
||
};
|
||
}
|
||
|
||
// Casting functions for converting "v__callgraph__Mapper" to interface "v__ast__walker__Visitor"
|
||
static inline v__ast__walker__Visitor I_v__callgraph__Mapper_to_Interface_v__ast__walker__Visitor(v__callgraph__Mapper* x) {
|
||
return (v__ast__walker__Visitor) {
|
||
._v__callgraph__Mapper = x,
|
||
._typ = _v__ast__walker__Visitor_v__callgraph__Mapper_index,
|
||
};
|
||
}
|
||
|
||
|
||
|
||
// V gowrappers:
|
||
void* sync__pool__process_in_thread_thread_wrapper(thread_arg_sync__pool__process_in_thread *arg) {
|
||
sync__pool__process_in_thread(arg->arg1, arg->arg2);
|
||
free(arg);
|
||
return 0;
|
||
}
|
||
|
||
// V shared type functions:
|
||
static inline voidptr __dup__shared__Array_string(voidptr src, int sz) {
|
||
__shared__Array_string* dest = memdup(src, sz);
|
||
sync__RwMutex_init(&dest->mtx);
|
||
return dest;
|
||
}
|
||
static inline voidptr __dup__shared__Map_string_bool(voidptr src, int sz) {
|
||
__shared__Map_string_bool* dest = memdup(src, sz);
|
||
sync__RwMutex_init(&dest->mtx);
|
||
return dest;
|
||
}
|
||
|
||
typedef struct __shared_map __shared_map;
|
||
struct __shared_map {
|
||
sync__RwMutex mtx;
|
||
map val;
|
||
};
|
||
static inline voidptr __dup_shared_map(voidptr src, int sz) {
|
||
__shared_map* dest = memdup(src, sz);
|
||
sync__RwMutex_init(&dest->mtx);
|
||
return dest;
|
||
}
|
||
typedef struct __shared_array __shared_array;
|
||
struct __shared_array {
|
||
sync__RwMutex mtx;
|
||
array val;
|
||
};
|
||
static inline voidptr __dup_shared_array(voidptr src, int sz) {
|
||
__shared_array* dest = memdup(src, sz);
|
||
sync__RwMutex_init(&dest->mtx);
|
||
return dest;
|
||
}
|
||
static inline void __sort_ptr(uintptr_t a[], bool b[], int l) {
|
||
for (int i=1; i<l; i++) {
|
||
uintptr_t ins = a[i];
|
||
bool insb = b[i];
|
||
int j = i;
|
||
while(j>0 && a[j-1] > ins) {
|
||
a[j] = a[j-1];
|
||
b[j] = b[j-1];
|
||
j--;
|
||
}
|
||
a[j] = ins;
|
||
b[j] = insb;
|
||
}
|
||
}
|
||
|
||
// V auto str functions:
|
||
static string time__FormatTime_str(time__FormatTime it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case time__FormatTime__hhmm12: return _SLIT("hhmm12");
|
||
case time__FormatTime__hhmm24: return _SLIT("hhmm24");
|
||
case time__FormatTime__hhmmss12: return _SLIT("hhmmss12");
|
||
case time__FormatTime__hhmmss24: return _SLIT("hhmmss24");
|
||
case time__FormatTime__hhmmss24_milli: return _SLIT("hhmmss24_milli");
|
||
case time__FormatTime__hhmmss24_micro: return _SLIT("hhmmss24_micro");
|
||
case time__FormatTime__no_time: return _SLIT("no_time");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string time__FormatDate_str(time__FormatDate it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case time__FormatDate__ddmmyy: return _SLIT("ddmmyy");
|
||
case time__FormatDate__ddmmyyyy: return _SLIT("ddmmyyyy");
|
||
case time__FormatDate__mmddyy: return _SLIT("mmddyy");
|
||
case time__FormatDate__mmddyyyy: return _SLIT("mmddyyyy");
|
||
case time__FormatDate__mmmd: return _SLIT("mmmd");
|
||
case time__FormatDate__mmmdd: return _SLIT("mmmdd");
|
||
case time__FormatDate__mmmddyy: return _SLIT("mmmddyy");
|
||
case time__FormatDate__mmmddyyyy: return _SLIT("mmmddyyyy");
|
||
case time__FormatDate__no_date: return _SLIT("no_date");
|
||
case time__FormatDate__yyyymmdd: return _SLIT("yyyymmdd");
|
||
case time__FormatDate__yymmdd: return _SLIT("yymmdd");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__pref__Backend_str(v__pref__Backend it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__pref__Backend__c: return _SLIT("c");
|
||
case v__pref__Backend__js_node: return _SLIT("js_node");
|
||
case v__pref__Backend__js_browser: return _SLIT("js_browser");
|
||
case v__pref__Backend__js_freestanding: return _SLIT("js_freestanding");
|
||
case v__pref__Backend__native: return _SLIT("native");
|
||
case v__pref__Backend__interpret: return _SLIT("interpret");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__ast__AttrKind_str(v__ast__AttrKind it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__ast__AttrKind__plain: return _SLIT("plain");
|
||
case v__ast__AttrKind__string: return _SLIT("string");
|
||
case v__ast__AttrKind__number: return _SLIT("number");
|
||
case v__ast__AttrKind__bool: return _SLIT("bool");
|
||
case v__ast__AttrKind__comptime_define: return _SLIT("comptime_define");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string Array_v__ast__Expr_str(Array_v__ast__Expr a) { return indent_Array_v__ast__Expr_str(a, 0);}
|
||
static string indent_Array_v__ast__Expr_str(Array_v__ast__Expr a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__Expr it = *(v__ast__Expr*)array_get(a, i);
|
||
strings__Builder_write_string(&sb, _SLIT(""));
|
||
string x = v__ast__Expr_str(it);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__ast__CallExpr_str(v__ast__CallExpr it) { return indent_v__ast__CallExpr_str(it, 0);}
|
||
static string v__ast__TypeInfo_str(v__ast__TypeInfo x) { return indent_v__ast__TypeInfo_str(x, 0); }
|
||
static string v__ast__Fn_str(v__ast__Fn it) { return indent_v__ast__Fn_str(it, 0);}
|
||
static string v__ast__Language_str(v__ast__Language it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__ast__Language__v: return _SLIT("v");
|
||
case v__ast__Language__c: return _SLIT("c");
|
||
case v__ast__Language__js: return _SLIT("js");
|
||
case v__ast__Language__amd64: return _SLIT("amd64");
|
||
case v__ast__Language__i386: return _SLIT("i386");
|
||
case v__ast__Language__arm64: return _SLIT("arm64");
|
||
case v__ast__Language__arm32: return _SLIT("arm32");
|
||
case v__ast__Language__rv64: return _SLIT("rv64");
|
||
case v__ast__Language__rv32: return _SLIT("rv32");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__ast__IdentKind_str(v__ast__IdentKind it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__ast__IdentKind__unresolved: return _SLIT("unresolved");
|
||
case v__ast__IdentKind__blank_ident: return _SLIT("blank_ident");
|
||
case v__ast__IdentKind__variable: return _SLIT("variable");
|
||
case v__ast__IdentKind__constant: return _SLIT("constant");
|
||
case v__ast__IdentKind__global: return _SLIT("global");
|
||
case v__ast__IdentKind__function: return _SLIT("function");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string anon_fn_v__ast__constdecl_str() { return _SLIT("fn (mut v.ast.ConstDecl)");}
|
||
static string v__token__Pos_str(v__token__Pos it) { return indent_v__token__Pos_str(it, 0);}
|
||
static string Array_v__ast__Attr_str(Array_v__ast__Attr a) { return indent_Array_v__ast__Attr_str(a, 0);}
|
||
static string indent_Array_v__ast__Attr_str(Array_v__ast__Attr a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__Attr it = *(v__ast__Attr*)array_get(a, i);
|
||
strings__Builder_write_string(&sb, _SLIT(""));
|
||
string x = v__ast__Attr_str(&it);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string Array_v__ast__Type_str(Array_v__ast__Type a) { return indent_Array_v__ast__Type_str(a, 0);}
|
||
static string indent_Array_v__ast__Type_str(Array_v__ast__Type a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
int it = *(int*)array_get(a, i);
|
||
strings__Builder_write_string(&sb, _SLIT(""));
|
||
string x = int_str(it);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string Array_Array_v__ast__Type_str(Array_Array_v__ast__Type a) { return indent_Array_Array_v__ast__Type_str(a, 0);}
|
||
static string indent_Array_Array_v__ast__Type_str(Array_Array_v__ast__Type a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
Array_v__ast__Type it = *(Array_v__ast__Type*)array_get(a, i);
|
||
string x = indent_Array_v__ast__Type_str(it, indent_count);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__gen__c__StrType_str(v__gen__c__StrType it) { return indent_v__gen__c__StrType_str(it, 0);}
|
||
static string v__ast__Enum_str(v__ast__Enum it) { return indent_v__ast__Enum_str(it, 0);}
|
||
static string v__ast__ComptTimeConstValue_str(v__ast__ComptTimeConstValue x) { return indent_v__ast__ComptTimeConstValue_str(x, 0); }
|
||
static string v__gen__c__SqlType_str(v__gen__c__SqlType it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__gen__c__SqlType__sqlite3: return _SLIT("sqlite3");
|
||
case v__gen__c__SqlType__mysql: return _SLIT("mysql");
|
||
case v__gen__c__SqlType__psql: return _SLIT("psql");
|
||
case v__gen__c__SqlType__mssql: return _SLIT("mssql");
|
||
case v__gen__c__SqlType__unknown: return _SLIT("unknown");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string Array_rune_str(Array_rune a) { return indent_Array_rune_str(a, 0);}
|
||
static string indent_Array_rune_str(Array_rune a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
rune it = *(rune*)array_get(a, i);
|
||
string x = str_intp(2, _MOV((StrIntpData[]){{_SLIT("`"), 0xfe10, {.d_s = rune_str(it) }}, {_SLIT("`"), 0, {.d_c = 0 }}}));
|
||
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__scanner__CommentsMode_str(v__scanner__CommentsMode it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__scanner__CommentsMode__skip_comments: return _SLIT("skip_comments");
|
||
case v__scanner__CommentsMode__parse_comments: return _SLIT("parse_comments");
|
||
case v__scanner__CommentsMode__toplevel_comments: return _SLIT("toplevel_comments");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__parser__State_str(v__parser__State it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__parser__State__simple: return _SLIT("simple");
|
||
case v__parser__State__html: return _SLIT("html");
|
||
case v__parser__State__css: return _SLIT("css");
|
||
case v__parser__State__js: return _SLIT("js");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__errors__Reporter_str(v__errors__Reporter it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__errors__Reporter__scanner: return _SLIT("scanner");
|
||
case v__errors__Reporter__parser: return _SLIT("parser");
|
||
case v__errors__Reporter__checker: return _SLIT("checker");
|
||
case v__errors__Reporter__builder: return _SLIT("builder");
|
||
case v__errors__Reporter__gen: return _SLIT("gen");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__builder__CcompilerOptions_str(v__builder__CcompilerOptions it) { return indent_v__builder__CcompilerOptions_str(it, 0);}
|
||
static string Array_v__cflag__CFlag_str(Array_v__cflag__CFlag a) { return indent_Array_v__cflag__CFlag_str(a, 0);}
|
||
static string indent_Array_v__cflag__CFlag_str(Array_v__cflag__CFlag a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__cflag__CFlag it = *(v__cflag__CFlag*)array_get(a, i);
|
||
strings__Builder_write_string(&sb, _SLIT(""));
|
||
string x = v__cflag__CFlag_str(&it);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string Map_string_int_str(Map_string_int m) { return indent_Map_string_int_str(m, 0);}
|
||
static string indent_Map_string_int_str(Map_string_int m, int indent_count) { /* gen_str_for_map */
|
||
strings__Builder sb = strings__new_builder(m.key_values.len*10);
|
||
strings__Builder_write_string(&sb, _SLIT("{"));
|
||
for (int i = 0; i < m.key_values.len; ++i) {
|
||
if (!DenseArray_has_index(&m.key_values, i)) { continue; }
|
||
string key = *(string*)DenseArray_key(&m.key_values, i);
|
||
strings__Builder_write_string(&sb, str_intp(2, _MOV((StrIntpData[]){{_SLIT("'"), 0xfe10, {.d_s = key}},{_SLIT("'"), 0, {.d_c = 0 }}})));
|
||
strings__Builder_write_string(&sb, _SLIT(": "));
|
||
strings__Builder_write_string(&sb, int_str(*(int*)DenseArray_value(&m.key_values, i)));
|
||
if (i != m.key_values.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("}"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__ast__OrExpr_str(v__ast__OrExpr it) { return indent_v__ast__OrExpr_str(it, 0);}
|
||
static string Array_v__ast__CallArg_str(Array_v__ast__CallArg a) { return indent_Array_v__ast__CallArg_str(a, 0);}
|
||
static string indent_Array_v__ast__CallArg_str(Array_v__ast__CallArg a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__CallArg it = *(v__ast__CallArg*)array_get(a, i);
|
||
strings__Builder_write_string(&sb, _SLIT(""));
|
||
string x = v__ast__CallArg_str(it);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string Array_v__ast__Comment_str(Array_v__ast__Comment a) { return indent_Array_v__ast__Comment_str(a, 0);}
|
||
static string indent_Array_v__ast__Comment_str(Array_v__ast__Comment a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__Comment it = *(v__ast__Comment*)array_get(a, i);
|
||
string x = indent_v__ast__Comment_str(it, indent_count);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__ast__Aggregate_str(v__ast__Aggregate it) { return indent_v__ast__Aggregate_str(it, 0);}
|
||
static string v__ast__Alias_str(v__ast__Alias it) { return indent_v__ast__Alias_str(it, 0);}
|
||
static string v__ast__Array_str(v__ast__Array it) { return indent_v__ast__Array_str(it, 0);}
|
||
static string v__ast__ArrayFixed_str(v__ast__ArrayFixed it) { return indent_v__ast__ArrayFixed_str(it, 0);}
|
||
static string v__ast__Chan_str(v__ast__Chan it) { return indent_v__ast__Chan_str(it, 0);}
|
||
static string v__ast__FnType_str(v__ast__FnType it) { return indent_v__ast__FnType_str(it, 0);}
|
||
static string v__ast__GenericInst_str(v__ast__GenericInst it) { return indent_v__ast__GenericInst_str(it, 0);}
|
||
static string v__ast__Interface_str(v__ast__Interface it) { return indent_v__ast__Interface_str(it, 0);}
|
||
static string v__ast__Map_str(v__ast__Map it) { return indent_v__ast__Map_str(it, 0);}
|
||
static string v__ast__MultiReturn_str(v__ast__MultiReturn it) { return indent_v__ast__MultiReturn_str(it, 0);}
|
||
static string v__ast__Struct_str(v__ast__Struct it) { return indent_v__ast__Struct_str(it, 0);}
|
||
static string v__ast__SumType_str(v__ast__SumType it) { return indent_v__ast__SumType_str(it, 0);}
|
||
static string v__ast__Thread_str(v__ast__Thread it) { return indent_v__ast__Thread_str(it, 0);}
|
||
static string Array_v__ast__Param_str(Array_v__ast__Param a) { return indent_Array_v__ast__Param_str(a, 0);}
|
||
static string indent_Array_v__ast__Param_str(Array_v__ast__Param a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__Param it = *(v__ast__Param*)array_get(a, i);
|
||
string x = indent_v__ast__Param_str(it, indent_count);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__ast__EmptyExpr_str(v__ast__EmptyExpr it) { return indent_v__ast__EmptyExpr_str(it, 0);}
|
||
static string Array_v__ast__Stmt_str(Array_v__ast__Stmt a) { return indent_Array_v__ast__Stmt_str(a, 0);}
|
||
static string indent_Array_v__ast__Stmt_str(Array_v__ast__Stmt a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__Stmt it = *(v__ast__Stmt*)array_get(a, i);
|
||
strings__Builder_write_string(&sb, _SLIT(""));
|
||
string x = v__ast__Stmt_str(it);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__ast__OrKind_str(v__ast__OrKind it) { /* gen_str_for_enum */
|
||
switch(it) {
|
||
case v__ast__OrKind__absent: return _SLIT("absent");
|
||
case v__ast__OrKind__block: return _SLIT("block");
|
||
case v__ast__OrKind__propagate_option: return _SLIT("propagate_option");
|
||
case v__ast__OrKind__propagate_result: return _SLIT("propagate_result");
|
||
default: return _SLIT("unknown enum value");
|
||
}
|
||
}
|
||
static string v__ast__Comment_str(v__ast__Comment it) { return indent_v__ast__Comment_str(it, 0);}
|
||
static string Array_v__ast__StructField_str(Array_v__ast__StructField a) { return indent_Array_v__ast__StructField_str(a, 0);}
|
||
static string indent_Array_v__ast__StructField_str(Array_v__ast__StructField a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__StructField it = *(v__ast__StructField*)array_get(a, i);
|
||
string x = indent_v__ast__StructField_str(it, indent_count);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string Map_int_Array_v__ast__Type_str(Map_int_Array_v__ast__Type m) { return indent_Map_int_Array_v__ast__Type_str(m, 0);}
|
||
static string indent_Map_int_Array_v__ast__Type_str(Map_int_Array_v__ast__Type m, int indent_count) { /* gen_str_for_map */
|
||
strings__Builder sb = strings__new_builder(m.key_values.len*10);
|
||
strings__Builder_write_string(&sb, _SLIT("{"));
|
||
for (int i = 0; i < m.key_values.len; ++i) {
|
||
if (!DenseArray_has_index(&m.key_values, i)) { continue; }
|
||
int key = *(int*)DenseArray_key(&m.key_values, i);
|
||
strings__Builder_write_string(&sb, int_str(key));
|
||
strings__Builder_write_string(&sb, _SLIT(": "));
|
||
strings__Builder_write_string(&sb, indent_Array_v__ast__Type_str(*(Array_v__ast__Type*)DenseArray_value(&m.key_values, i), indent_count));
|
||
if (i != m.key_values.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("}"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string Array_v__ast__Fn_str(Array_v__ast__Fn a) { return indent_Array_v__ast__Fn_str(a, 0);}
|
||
static string indent_Array_v__ast__Fn_str(Array_v__ast__Fn a, int indent_count) {
|
||
strings__Builder sb = strings__new_builder(a.len * 10);
|
||
strings__Builder_write_string(&sb, _SLIT("["));
|
||
for (int i = 0; i < a.len; ++i) {
|
||
v__ast__Fn it = *(v__ast__Fn*)array_get(a, i);
|
||
string x = indent_v__ast__Fn_str(it, indent_count);
|
||
strings__Builder_write_string(&sb, x);
|
||
if (i < a.len-1) {
|
||
strings__Builder_write_string(&sb, _SLIT(", "));
|
||
}
|
||
}
|
||
strings__Builder_write_string(&sb, _SLIT("]"));
|
||
string res = strings__Builder_str(&sb);
|
||
strings__Builder_free(&sb);
|
||
return res;
|
||
}
|
||
static string v__ast__Param_str(v__ast__Param it) { return indent_v__ast__Param_str(it, 0);}
|
||
static string v__ast__StructField_str(v__ast__StructField it) { return indent_v__ast__StructField_str(it, 0);}
|
||
|
||
// V dump functions:
|
||
string _v_dump_expr_string(string fpath, int line, string sexpr, string dump_arg) {
|
||
string sline = int_str(line);
|
||
string value = string_str(dump_arg);
|
||
|
||
strings__Builder sb = strings__new_builder(256);
|
||
|
||
strings__Builder_write_rune(&sb, '[');
|
||
strings__Builder_write_string(&sb, fpath);
|
||
strings__Builder_write_rune(&sb, ':');
|
||
strings__Builder_write_string(&sb, sline);
|
||
strings__Builder_write_rune(&sb, ']');
|
||
strings__Builder_write_rune(&sb, ' ');
|
||
strings__Builder_write_string(&sb, sexpr);
|
||
strings__Builder_write_rune(&sb, ':');
|
||
strings__Builder_write_rune(&sb, ' ');
|
||
strings__Builder_write_string(&sb, value);
|
||
strings__Builder_write_rune(&sb, '\n');
|
||
|
||
string res;
|
||
res = strings__Builder_str(&sb);
|
||
eprint(res);
|
||
string_free(&res);
|
||
strings__Builder_free(&sb);
|
||
|
||
string_free(&value);
|
||
string_free(&sline);
|
||
return dump_arg;
|
||
}
|
||
|
||
static string indent_v__ast__CallExpr_str(v__ast__CallExpr it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t1 = indent_v__ast__OrExpr_str(it.or_block, indent_count + 1);
|
||
string _t2 = indent_Array_v__ast__CallArg_str(it.args, indent_count + 1);
|
||
string _t3 = indent_Array_v__ast__Type_str(it.expected_arg_types, indent_count + 1);
|
||
string _t4 = indent_Array_v__ast__Type_str(it.concrete_types, indent_count + 1);
|
||
string _t5 = indent_Array_v__ast__Type_str(it.raw_concrete_types, indent_count + 1);
|
||
string _t6 = indent_Array_v__ast__Type_str(it.from_embed_types, indent_count + 1);
|
||
string _t7 = indent_Array_v__ast__Comment_str(it.comments, indent_count + 1);
|
||
string _t8 = v__ast__Expr_str(it.left);
|
||
string _t9 = isnil(it.scope) ? _SLIT("nil") : (indent_count > 25)? _SLIT("<probably circular>") : v__ast__Scope_str(*it.scope);
|
||
string _t10 = indent_v__token__Pos_str(it.pos, indent_count + 1);
|
||
string _t11 = indent_v__token__Pos_str(it.name_pos, indent_count + 1);
|
||
string _t12 = indent_v__token__Pos_str(it.concrete_list_pos, indent_count + 1);
|
||
string _t13 = v__ast__Type_str(it.left_type);
|
||
string _t14 = v__ast__Type_str(it.receiver_type);
|
||
string _t15 = v__ast__Type_str(it.return_type);
|
||
string _t16 = v__ast__Type_str(it.fn_var_type);
|
||
string _t17 = v__ast__Language_str(it.language);
|
||
string res = str_intp( 111, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.CallExpr{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" or_block: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t1}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" args: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t2}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" expected_arg_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t3}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" concrete_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t4}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" raw_concrete_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t5}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" from_embed_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t6}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" comments: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t7}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" mod: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.mod}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" name: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.name}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" left: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t8}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" scope: &"), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t9}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t10}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" name_pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t11}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" concrete_list_pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t12}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" left_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t13}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" receiver_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t14}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" return_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t15}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" fn_var_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t16}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" language: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t17}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_method: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_method ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_field: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_field ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_fn_var: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_fn_var ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_keep_alive: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_keep_alive ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_noreturn: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_noreturn ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_ctor_new: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_ctor_new ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" should_be_skipped: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.should_be_skipped ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" free_receiver: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.free_receiver ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t17);
|
||
string_free(&_t16);
|
||
string_free(&_t15);
|
||
string_free(&_t14);
|
||
string_free(&_t13);
|
||
string_free(&_t12);
|
||
string_free(&_t11);
|
||
string_free(&_t10);
|
||
string_free(&_t9);
|
||
string_free(&_t8);
|
||
string_free(&_t7);
|
||
string_free(&_t6);
|
||
string_free(&_t5);
|
||
string_free(&_t4);
|
||
string_free(&_t3);
|
||
string_free(&_t2);
|
||
string_free(&_t1);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__TypeInfo_str(v__ast__TypeInfo x, int indent_count) {
|
||
switch(x._typ) {
|
||
case 434: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Aggregate_str(*(v__ast__Aggregate*)x._v__ast__Aggregate, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 436: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Alias_str(*(v__ast__Alias*)x._v__ast__Alias, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 415: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Array_str(*(v__ast__Array*)x._v__ast__Array, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 444: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__ArrayFixed_str(*(v__ast__ArrayFixed*)x._v__ast__ArrayFixed, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 445: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Chan_str(*(v__ast__Chan*)x._v__ast__Chan, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 450: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Enum_str(*(v__ast__Enum*)x._v__ast__Enum, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 448: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__FnType_str(*(v__ast__FnType*)x._v__ast__FnType, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 449: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__GenericInst_str(*(v__ast__GenericInst*)x._v__ast__GenericInst, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 439: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Interface_str(*(v__ast__Interface*)x._v__ast__Interface, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 416: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Map_str(*(v__ast__Map*)x._v__ast__Map, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 447: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__MultiReturn_str(*(v__ast__MultiReturn*)x._v__ast__MultiReturn, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 420: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Struct_str(*(v__ast__Struct*)x._v__ast__Struct, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 440: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__SumType_str(*(v__ast__SumType*)x._v__ast__SumType, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 446: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.TypeInfo("), 0xfe10, {.d_s = indent_v__ast__Thread_str(*(v__ast__Thread*)x._v__ast__Thread, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
default: return _SLIT("unknown sum type value");
|
||
}
|
||
}
|
||
|
||
static string indent_v__ast__Fn_str(v__ast__Fn it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t18 = indent_Array_v__ast__Param_str(it.params, indent_count + 1);
|
||
string _t19 = Array_string_str(it.generic_names);
|
||
string _t20 = Array_string_str(it.dep_names);
|
||
string _t21 = indent_Array_v__ast__Attr_str(it.attrs, indent_count + 1);
|
||
string _t22 = indent_v__token__Pos_str(it.pos, indent_count + 1);
|
||
string _t23 = indent_v__token__Pos_str(it.return_type_pos, indent_count + 1);
|
||
string _t24 = v__ast__Type_str(it.return_type);
|
||
string _t25 = v__ast__Type_str(it.receiver_type);
|
||
string _t26 = v__ast__Language_str(it.language);
|
||
string _t27 = v__ast__Language_str(it.file_mode);
|
||
string res = str_intp( 119, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Fn{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" params: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t18}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" generic_names: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t19}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" dep_names: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t20}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" attrs: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t21}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" mod: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.mod}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" file: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.file}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" name: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.name}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t22}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" return_type_pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t23}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" return_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t24}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" receiver_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t25}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" usages: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.usages}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" ctdefine_idx: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.ctdefine_idx}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" source_fn: "), 0, {.d_c=0}}, {_SLIT(""), 17, {.d_p=(voidptr) it.source_fn}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" language: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t26}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" file_mode: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t27}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_variadic: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_variadic ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_pub: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_pub ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_ctor_new: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_ctor_new ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_deprecated: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_deprecated ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_noreturn: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_noreturn ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_unsafe: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_unsafe ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_placeholder: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_placeholder ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_main: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_main ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_test: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_test ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_keep_alive: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_keep_alive ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_method: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_method ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" no_body: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.no_body ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_conditional: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_conditional ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t27);
|
||
string_free(&_t26);
|
||
string_free(&_t25);
|
||
string_free(&_t24);
|
||
string_free(&_t23);
|
||
string_free(&_t22);
|
||
string_free(&_t21);
|
||
string_free(&_t20);
|
||
string_free(&_t19);
|
||
string_free(&_t18);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__token__Pos_str(v__token__Pos it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string res = str_intp( 23, _MOV((StrIntpData[]){
|
||
{_SLIT("v.token.Pos{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" len: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.len}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" line_nr: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.line_nr}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.pos}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" col: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.col}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" last_line: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.last_line}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__gen__c__StrType_str(v__gen__c__StrType it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t28 = v__ast__Type_str(it.typ);
|
||
string res = str_intp( 11, _MOV((StrIntpData[]){
|
||
{_SLIT("v.gen.c.StrType{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" styp: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.styp}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" typ: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t28}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t28);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Enum_str(v__ast__Enum it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t29 = Array_string_str(it.vals);
|
||
string res = str_intp( 19, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Enum{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" vals: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t29}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_flag: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_flag ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_multi_allowed: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_multi_allowed ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" uses_exprs: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.uses_exprs ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t29);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__ComptTimeConstValue_str(v__ast__ComptTimeConstValue x, int indent_count) {
|
||
switch(x._typ) {
|
||
case 266: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = indent_v__ast__EmptyExpr_str(*(v__ast__EmptyExpr*)x._v__ast__EmptyExpr, indent_count)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 15: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = f32_str(*(f32*)x._f32)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 16: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = f64_str(*(f64*)x._f64)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 6: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = i16_str(*(i16*)x._i16)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 8: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = i64_str(*(i64*)x._i64)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 5: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = i8_str(*(i8*)x._i8)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 7: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = int_str(*(int*)x._int)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 21: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = rune_str(*(rune*)x._rune)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 20: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue('"), 0xfe10, {.d_s = string_str(*(string*)x._string)}},
|
||
{_SLIT("')"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 11: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = u16_str(*(u16*)x._u16)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 12: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = u32_str(*(u32*)x._u32)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 13: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = u64_str(*(u64*)x._u64)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
case 10: return str_intp(2, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ComptTimeConstValue("), 0xfe10, {.d_s = u8_str(*(u8*)x._u8)}},
|
||
{_SLIT(")"), 0, {.d_c = 0 }}
|
||
}));
|
||
default: return _SLIT("unknown sum type value");
|
||
}
|
||
}
|
||
|
||
static string indent_v__builder__CcompilerOptions_str(v__builder__CcompilerOptions it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t30 = Array_string_str(it.args);
|
||
string _t31 = Array_string_str(it.wargs);
|
||
string _t32 = Array_string_str(it.pre_args);
|
||
string _t33 = Array_string_str(it.o_args);
|
||
string _t34 = Array_string_str(it.source_args);
|
||
string _t35 = Array_string_str(it.post_args);
|
||
string _t36 = Array_string_str(it.linker_flags);
|
||
string res = str_intp( 67, _MOV((StrIntpData[]){
|
||
{_SLIT("v.builder.CcompilerOptions{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" guessed_compiler: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.guessed_compiler}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" shared_postfix: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.shared_postfix}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" debug_mode: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.debug_mode ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_cc_tcc: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_cc_tcc ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_cc_gcc: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_cc_gcc ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_cc_msvc: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_cc_msvc ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_cc_clang: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_cc_clang ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" env_cflags: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.env_cflags}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" env_ldflags: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.env_ldflags}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" args: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t30}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" wargs: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t31}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pre_args: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t32}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" o_args: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t33}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" source_args: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t34}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" post_args: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t35}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" linker_flags: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t36}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t36);
|
||
string_free(&_t35);
|
||
string_free(&_t34);
|
||
string_free(&_t33);
|
||
string_free(&_t32);
|
||
string_free(&_t31);
|
||
string_free(&_t30);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__OrExpr_str(v__ast__OrExpr it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t37 = indent_Array_v__ast__Stmt_str(it.stmts, indent_count + 1);
|
||
string _t38 = v__ast__OrKind_str(it.kind);
|
||
string _t39 = indent_v__token__Pos_str(it.pos, indent_count + 1);
|
||
string res = str_intp( 15, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.OrExpr{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" stmts: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t37}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" kind: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t38}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t39}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t39);
|
||
string_free(&_t38);
|
||
string_free(&_t37);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Aggregate_str(v__ast__Aggregate it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t40 = indent_Array_v__ast__StructField_str(it.fields, indent_count + 1);
|
||
string _t41 = v__ast__Type_str(it.sum_type);
|
||
string _t42 = indent_Array_v__ast__Type_str(it.types, indent_count + 1);
|
||
string res = str_intp( 15, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Aggregate{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" fields: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t40}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" sum_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t41}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t42}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t42);
|
||
string_free(&_t41);
|
||
string_free(&_t40);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Alias_str(v__ast__Alias it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t43 = v__ast__Type_str(it.parent_type);
|
||
string _t44 = v__ast__Language_str(it.language);
|
||
string res = str_intp( 15, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Alias{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" parent_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t43}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" language: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t44}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_import: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_import ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t44);
|
||
string_free(&_t43);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Array_str(v__ast__Array it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t45 = v__ast__Type_str(it.elem_type);
|
||
string res = str_intp( 11, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Array{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" nr_dims: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.nr_dims}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" elem_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t45}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t45);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__ArrayFixed_str(v__ast__ArrayFixed it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t46 = v__ast__Expr_str(it.size_expr);
|
||
string _t47 = v__ast__Type_str(it.elem_type);
|
||
string res = str_intp( 15, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.ArrayFixed{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" size_expr: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t46}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" size: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.size}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" elem_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t47}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t47);
|
||
string_free(&_t46);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Chan_str(v__ast__Chan it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t48 = v__ast__Type_str(it.elem_type);
|
||
string res = str_intp( 11, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Chan{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" elem_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t48}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_mut: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_mut ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t48);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__FnType_str(v__ast__FnType it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t49 = indent_v__ast__Fn_str(it.func, indent_count + 1);
|
||
string res = str_intp( 15, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.FnType{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" is_anon: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_anon ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" has_decl: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.has_decl ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" func: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t49}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t49);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__GenericInst_str(v__ast__GenericInst it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t50 = indent_Array_v__ast__Type_str(it.concrete_types, indent_count + 1);
|
||
string res = str_intp( 11, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.GenericInst{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" parent_idx: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.parent_idx}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" concrete_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t50}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t50);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Interface_str(v__ast__Interface it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t51 = indent_Map_int_Array_v__ast__Type_str(it.conversions, indent_count + 1);
|
||
string _t52 = indent_Array_v__ast__Type_str(it.types, indent_count + 1);
|
||
string _t53 = indent_Array_v__ast__StructField_str(it.fields, indent_count + 1);
|
||
string _t54 = indent_Array_v__ast__Fn_str(it.methods, indent_count + 1);
|
||
string _t55 = indent_Array_v__ast__Type_str(it.embeds, indent_count + 1);
|
||
string _t56 = indent_Array_v__ast__Type_str(it.generic_types, indent_count + 1);
|
||
string _t57 = indent_Array_v__ast__Type_str(it.concrete_types, indent_count + 1);
|
||
string _t58 = v__ast__Type_str(it.parent_type);
|
||
string res = str_intp( 39, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Interface{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" conversions: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t51}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t52}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" fields: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t53}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" methods: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t54}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" embeds: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t55}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" generic_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t56}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" concrete_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t57}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" parent_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t58}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_generic: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_generic ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t58);
|
||
string_free(&_t57);
|
||
string_free(&_t56);
|
||
string_free(&_t55);
|
||
string_free(&_t54);
|
||
string_free(&_t53);
|
||
string_free(&_t52);
|
||
string_free(&_t51);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Map_str(v__ast__Map it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t59 = v__ast__Type_str(it.key_type);
|
||
string _t60 = v__ast__Type_str(it.value_type);
|
||
string res = str_intp( 11, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Map{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" key_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t59}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" value_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t60}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t60);
|
||
string_free(&_t59);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__MultiReturn_str(v__ast__MultiReturn it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t61 = indent_Array_v__ast__Type_str(it.types, indent_count + 1);
|
||
string res = str_intp( 7, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.MultiReturn{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t61}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t61);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Struct_str(v__ast__Struct it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t62 = indent_Array_v__ast__Attr_str(it.attrs, indent_count + 1);
|
||
string _t63 = indent_Array_v__ast__Type_str(it.embeds, indent_count + 1);
|
||
string _t64 = indent_Array_v__ast__StructField_str(it.fields, indent_count + 1);
|
||
string _t65 = indent_Array_v__ast__Type_str(it.generic_types, indent_count + 1);
|
||
string _t66 = indent_Array_v__ast__Type_str(it.concrete_types, indent_count + 1);
|
||
string _t67 = v__ast__Type_str(it.parent_type);
|
||
string res = str_intp( 47, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Struct{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" attrs: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t62}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" embeds: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t63}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" fields: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t64}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" generic_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t65}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" concrete_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t66}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" parent_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t67}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_typedef: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_typedef ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_union: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_union ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_heap: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_heap ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_minify: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_minify ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_generic: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_generic ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t67);
|
||
string_free(&_t66);
|
||
string_free(&_t65);
|
||
string_free(&_t64);
|
||
string_free(&_t63);
|
||
string_free(&_t62);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__SumType_str(v__ast__SumType it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t68 = indent_Array_v__ast__StructField_str(it.fields, indent_count + 1);
|
||
string _t69 = indent_Array_v__ast__Type_str(it.variants, indent_count + 1);
|
||
string _t70 = indent_Array_v__ast__Type_str(it.generic_types, indent_count + 1);
|
||
string _t71 = indent_Array_v__ast__Type_str(it.concrete_types, indent_count + 1);
|
||
string _t72 = v__ast__Type_str(it.parent_type);
|
||
string res = str_intp( 35, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.SumType{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" fields: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t68}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" variants: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t69}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" generic_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t70}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" concrete_types: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t71}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" parent_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t72}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" found_fields: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.found_fields ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_anon: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_anon ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_generic: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_generic ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t72);
|
||
string_free(&_t71);
|
||
string_free(&_t70);
|
||
string_free(&_t69);
|
||
string_free(&_t68);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Thread_str(v__ast__Thread it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t73 = v__ast__Type_str(it.return_type);
|
||
string res = str_intp( 7, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Thread{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" return_type: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t73}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t73);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__EmptyExpr_str(v__ast__EmptyExpr it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string res = str_intp( 7, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.EmptyExpr{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" x: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.x}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Comment_str(v__ast__Comment it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t74 = indent_v__token__Pos_str(it.pos, indent_count + 1);
|
||
string res = str_intp( 19, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Comment{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" text: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.text}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_multi: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_multi ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_inline: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_inline ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t74}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t74);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__Param_str(v__ast__Param it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t75 = indent_v__token__Pos_str(it.pos, indent_count + 1);
|
||
string _t76 = indent_v__token__Pos_str(it.type_pos, indent_count + 1);
|
||
string _t77 = v__ast__Type_str(it.typ);
|
||
string res = str_intp( 31, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.Param{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" name: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.name}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t75}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" type_pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t76}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" typ: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t77}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_mut: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_mut ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_auto_rec: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_auto_rec ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_hidden: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_hidden ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t77);
|
||
string_free(&_t76);
|
||
string_free(&_t75);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static string indent_v__ast__StructField_str(v__ast__StructField it, int indent_count) {
|
||
string indents = string_repeat(_SLIT(" "), indent_count);
|
||
string _t78 = indent_Array_v__ast__Comment_str(it.comments, indent_count + 1);
|
||
string _t79 = indent_Array_v__ast__Attr_str(it.attrs, indent_count + 1);
|
||
string _t80 = v__ast__Expr_str(it.default_expr);
|
||
string _t81 = indent_v__token__Pos_str(it.pos, indent_count + 1);
|
||
string _t82 = indent_v__token__Pos_str(it.type_pos, indent_count + 1);
|
||
string _t83 = v__ast__Type_str(it.default_expr_typ);
|
||
string _t84 = v__ast__Type_str(it.typ);
|
||
string res = str_intp( 75, _MOV((StrIntpData[]){
|
||
{_SLIT("v.ast.StructField{\n"), 0, {.d_c=0}},
|
||
{_SLIT0, 0xfe10, {.d_s=indents}}, {_SLIT(" comments: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t78}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" attrs: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t79}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" default_val: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.default_val}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" deprecation_msg: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.deprecation_msg}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" deprecated_after: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.deprecated_after}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" default_expr: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t80}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" name: "), 0, {.d_c=0}}, {_SLIT("'"), 16, {.d_s=it.name}}, {_SLIT("'"), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t81}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" type_pos: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t82}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" i: "), 0, {.d_c=0}}, {_SLIT(""), 7, {.d_i32=it.i}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" default_expr_typ: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t83}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" typ: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=_t84}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" has_default_expr: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.has_default_expr ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_pub: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_pub ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_mut: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_mut ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_global: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_global ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_volatile: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_volatile ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT(" is_deprecated: "), 0, {.d_c=0}}, {_SLIT(""), 16, {.d_s=it.is_deprecated ? _SLIT("true") : _SLIT("false")}}, {_SLIT(""), 0, {.d_c=0}},
|
||
{_SLIT("\n"), 0xfe10, {.d_s=indents}}, {_SLIT("}"), 0, {.d_c=0}},
|
||
}));
|
||
string_free(&_t84);
|
||
string_free(&_t83);
|
||
string_free(&_t82);
|
||
string_free(&_t81);
|
||
string_free(&_t80);
|
||
string_free(&_t79);
|
||
string_free(&_t78);
|
||
string_free(&indents);
|
||
return res;
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__EmptyExpr_to_sumtype_v__ast__Expr(v__ast__EmptyExpr* x) {
|
||
v__ast__EmptyExpr* ptr = memdup(x, sizeof(v__ast__EmptyExpr));
|
||
return (v__ast__Expr){ ._v__ast__EmptyExpr = ptr, ._typ = 266};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__EmptyStmt_to_sumtype_v__ast__Stmt(v__ast__EmptyStmt* x) {
|
||
v__ast__EmptyStmt* ptr = memdup(x, sizeof(v__ast__EmptyStmt));
|
||
return (v__ast__Stmt){ ._v__ast__EmptyStmt = ptr, ._typ = 308, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__EmptyStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__EmptyNode_to_sumtype_v__ast__Node(v__ast__EmptyNode* x) {
|
||
v__ast__EmptyNode* ptr = memdup(x, sizeof(v__ast__EmptyNode));
|
||
return (v__ast__Node){ ._v__ast__EmptyNode = ptr, ._typ = 331};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__Expr_to_sumtype_v__ast__Node(v__ast__Expr* x) {
|
||
v__ast__Expr* ptr = memdup(x, sizeof(v__ast__Expr));
|
||
return (v__ast__Node){ ._v__ast__Expr = ptr, ._typ = 299};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__Stmt_to_sumtype_v__ast__Node(v__ast__Stmt* x) {
|
||
v__ast__Stmt* ptr = memdup(x, sizeof(v__ast__Stmt));
|
||
return (v__ast__Node){ ._v__ast__Stmt = ptr, ._typ = 324};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__StructInitField_to_sumtype_v__ast__Node(v__ast__StructInitField* x) {
|
||
v__ast__StructInitField* ptr = memdup(x, sizeof(v__ast__StructInitField));
|
||
return (v__ast__Node){ ._v__ast__StructInitField = ptr, ._typ = 338};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__FnDecl_to_sumtype_v__ast__Stmt(v__ast__FnDecl* x) {
|
||
v__ast__FnDecl* ptr = memdup(x, sizeof(v__ast__FnDecl));
|
||
return (v__ast__Stmt){ ._v__ast__FnDecl = ptr, ._typ = 185, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__FnDecl, pos))};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__CallArg_to_sumtype_v__ast__Node(v__ast__CallArg* x) {
|
||
v__ast__CallArg* ptr = memdup(x, sizeof(v__ast__CallArg));
|
||
return (v__ast__Node){ ._v__ast__CallArg = ptr, ._typ = 330};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__OrExpr_to_sumtype_v__ast__Expr(v__ast__OrExpr* x) {
|
||
v__ast__OrExpr* ptr = memdup(x, sizeof(v__ast__OrExpr));
|
||
return (v__ast__Expr){ ._v__ast__OrExpr = ptr, ._typ = 284};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__IfBranch_to_sumtype_v__ast__Node(v__ast__IfBranch* x) {
|
||
v__ast__IfBranch* ptr = memdup(x, sizeof(v__ast__IfBranch));
|
||
return (v__ast__Node){ ._v__ast__IfBranch = ptr, ._typ = 333};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__MatchBranch_to_sumtype_v__ast__Node(v__ast__MatchBranch* x) {
|
||
v__ast__MatchBranch* ptr = memdup(x, sizeof(v__ast__MatchBranch));
|
||
return (v__ast__Node){ ._v__ast__MatchBranch = ptr, ._typ = 334};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__SelectBranch_to_sumtype_v__ast__Node(v__ast__SelectBranch* x) {
|
||
v__ast__SelectBranch* ptr = memdup(x, sizeof(v__ast__SelectBranch));
|
||
return (v__ast__Node){ ._v__ast__SelectBranch = ptr, ._typ = 336};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__StructField_to_sumtype_v__ast__Node(v__ast__StructField* x) {
|
||
v__ast__StructField* ptr = memdup(x, sizeof(v__ast__StructField));
|
||
return (v__ast__Node){ ._v__ast__StructField = ptr, ._typ = 337};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__GlobalField_to_sumtype_v__ast__Node(v__ast__GlobalField* x) {
|
||
v__ast__GlobalField* ptr = memdup(x, sizeof(v__ast__GlobalField));
|
||
return (v__ast__Node){ ._v__ast__GlobalField = ptr, ._typ = 327};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__ConstField_to_sumtype_v__ast__Node(v__ast__ConstField* x) {
|
||
v__ast__ConstField* ptr = memdup(x, sizeof(v__ast__ConstField));
|
||
return (v__ast__Node){ ._v__ast__ConstField = ptr, ._typ = 326};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__EnumField_to_sumtype_v__ast__Node(v__ast__EnumField* x) {
|
||
v__ast__EnumField* ptr = memdup(x, sizeof(v__ast__EnumField));
|
||
return (v__ast__Node){ ._v__ast__EnumField = ptr, ._typ = 332};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__Param_to_sumtype_v__ast__Node(v__ast__Param* x) {
|
||
v__ast__Param* ptr = memdup(x, sizeof(v__ast__Param));
|
||
return (v__ast__Node){ ._v__ast__Param = ptr, ._typ = 335};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__TypeNode_to_sumtype_v__ast__Expr(v__ast__TypeNode* x) {
|
||
v__ast__TypeNode* ptr = memdup(x, sizeof(v__ast__TypeNode));
|
||
return (v__ast__Expr){ ._v__ast__TypeNode = ptr, ._typ = 296};
|
||
}
|
||
|
||
static inline v__ast__ScopeObject v__ast__AsmRegister_to_sumtype_v__ast__ScopeObject(v__ast__AsmRegister* x) {
|
||
v__ast__AsmRegister* ptr = memdup(x, sizeof(v__ast__AsmRegister));
|
||
return (v__ast__ScopeObject){ ._v__ast__AsmRegister = ptr, ._typ = 325, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AsmRegister, name)), .typ = (v__ast__Type*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AsmRegister, typ))};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue v__ast__EmptyExpr_to_sumtype_v__ast__ComptTimeConstValue(v__ast__EmptyExpr* x) {
|
||
v__ast__EmptyExpr* ptr = memdup(x, sizeof(v__ast__EmptyExpr));
|
||
return (v__ast__ComptTimeConstValue){ ._v__ast__EmptyExpr = ptr, ._typ = 266};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ArrayInit_to_sumtype_v__ast__Expr(v__ast__ArrayInit* x) {
|
||
v__ast__ArrayInit* ptr = memdup(x, sizeof(v__ast__ArrayInit));
|
||
return (v__ast__Expr){ ._v__ast__ArrayInit = ptr, ._typ = 250};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__StringLiteral_to_sumtype_v__ast__Expr(v__ast__StringLiteral* x) {
|
||
v__ast__StringLiteral* ptr = memdup(x, sizeof(v__ast__StringLiteral));
|
||
return (v__ast__Expr){ ._v__ast__StringLiteral = ptr, ._typ = 294};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__MapInit_to_sumtype_v__ast__Expr(v__ast__MapInit* x) {
|
||
v__ast__MapInit* ptr = memdup(x, sizeof(v__ast__MapInit));
|
||
return (v__ast__Expr){ ._v__ast__MapInit = ptr, ._typ = 279};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__StructInit_to_sumtype_v__ast__Expr(v__ast__StructInit* x) {
|
||
v__ast__StructInit* ptr = memdup(x, sizeof(v__ast__StructInit));
|
||
return (v__ast__Expr){ ._v__ast__StructInit = ptr, ._typ = 295};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__SumType_to_sumtype_v__ast__TypeInfo(v__ast__SumType* x) {
|
||
v__ast__SumType* ptr = memdup(x, sizeof(v__ast__SumType));
|
||
return (v__ast__TypeInfo){ ._v__ast__SumType = ptr, ._typ = 440};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Chan_to_sumtype_v__ast__TypeInfo(v__ast__Chan* x) {
|
||
v__ast__Chan* ptr = memdup(x, sizeof(v__ast__Chan));
|
||
return (v__ast__TypeInfo){ ._v__ast__Chan = ptr, ._typ = 445};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Map_to_sumtype_v__ast__TypeInfo(v__ast__Map* x) {
|
||
v__ast__Map* ptr = memdup(x, sizeof(v__ast__Map));
|
||
return (v__ast__TypeInfo){ ._v__ast__Map = ptr, ._typ = 416};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Thread_to_sumtype_v__ast__TypeInfo(v__ast__Thread* x) {
|
||
v__ast__Thread* ptr = memdup(x, sizeof(v__ast__Thread));
|
||
return (v__ast__TypeInfo){ ._v__ast__Thread = ptr, ._typ = 446};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Struct_to_sumtype_v__ast__TypeInfo(v__ast__Struct* x) {
|
||
v__ast__Struct* ptr = memdup(x, sizeof(v__ast__Struct));
|
||
return (v__ast__TypeInfo){ ._v__ast__Struct = ptr, ._typ = 420};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Array_to_sumtype_v__ast__TypeInfo(v__ast__Array* x) {
|
||
v__ast__Array* ptr = memdup(x, sizeof(v__ast__Array));
|
||
return (v__ast__TypeInfo){ ._v__ast__Array = ptr, ._typ = 415};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__ArrayFixed_to_sumtype_v__ast__TypeInfo(v__ast__ArrayFixed* x) {
|
||
v__ast__ArrayFixed* ptr = memdup(x, sizeof(v__ast__ArrayFixed));
|
||
return (v__ast__TypeInfo){ ._v__ast__ArrayFixed = ptr, ._typ = 444};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__MultiReturn_to_sumtype_v__ast__TypeInfo(v__ast__MultiReturn* x) {
|
||
v__ast__MultiReturn* ptr = memdup(x, sizeof(v__ast__MultiReturn));
|
||
return (v__ast__TypeInfo){ ._v__ast__MultiReturn = ptr, ._typ = 447};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__FnType_to_sumtype_v__ast__TypeInfo(v__ast__FnType* x) {
|
||
v__ast__FnType* ptr = memdup(x, sizeof(v__ast__FnType));
|
||
return (v__ast__TypeInfo){ ._v__ast__FnType = ptr, ._typ = 448};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__None_to_sumtype_v__ast__Expr(v__ast__None* x) {
|
||
v__ast__None* ptr = memdup(x, sizeof(v__ast__None));
|
||
return (v__ast__Expr){ ._v__ast__None = ptr, ._typ = 282};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Interface_to_sumtype_v__ast__TypeInfo(v__ast__Interface* x) {
|
||
v__ast__Interface* ptr = memdup(x, sizeof(v__ast__Interface));
|
||
return (v__ast__TypeInfo){ ._v__ast__Interface = ptr, ._typ = 439};
|
||
}
|
||
|
||
static inline v__ast__IdentInfo v__ast__IdentVar_to_sumtype_v__ast__IdentInfo(v__ast__IdentVar* x) {
|
||
v__ast__IdentVar* ptr = memdup(x, sizeof(v__ast__IdentVar));
|
||
return (v__ast__IdentInfo){ ._v__ast__IdentVar = ptr, ._typ = 380};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__InfixExpr_to_sumtype_v__ast__Expr(v__ast__InfixExpr* x) {
|
||
v__ast__InfixExpr* ptr = memdup(x, sizeof(v__ast__InfixExpr));
|
||
return (v__ast__Expr){ ._v__ast__InfixExpr = ptr, ._typ = 274};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__CastExpr_to_sumtype_v__ast__Expr(v__ast__CastExpr* x) {
|
||
v__ast__CastExpr* ptr = memdup(x, sizeof(v__ast__CastExpr));
|
||
return (v__ast__Expr){ ._v__ast__CastExpr = ptr, ._typ = 257};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__AsmRegister_to_sumtype_v__ast__AsmArg(v__ast__AsmRegister* x) {
|
||
v__ast__AsmRegister* ptr = memdup(x, sizeof(v__ast__AsmRegister));
|
||
return (v__ast__AsmArg){ ._v__ast__AsmRegister = ptr, ._typ = 325};
|
||
}
|
||
|
||
static inline v__ast__ScopeObject v__ast__Var_to_sumtype_v__ast__ScopeObject(v__ast__Var* x) {
|
||
v__ast__Var* ptr = memdup(x, sizeof(v__ast__Var));
|
||
return (v__ast__ScopeObject){ ._v__ast__Var = ptr, ._typ = 328, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__Var, name)), .typ = (v__ast__Type*)((char*)ptr + __offsetof_ptr(ptr, v__ast__Var, typ))};
|
||
}
|
||
|
||
static inline v__ast__ScopeObject v__ast__ConstField_to_sumtype_v__ast__ScopeObject(v__ast__ConstField* x) {
|
||
v__ast__ConstField* ptr = memdup(x, sizeof(v__ast__ConstField));
|
||
return (v__ast__ScopeObject){ ._v__ast__ConstField = ptr, ._typ = 326, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ConstField, name)), .typ = (v__ast__Type*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ConstField, typ))};
|
||
}
|
||
|
||
static inline v__ast__IdentInfo v__ast__IdentFn_to_sumtype_v__ast__IdentInfo(v__ast__IdentFn* x) {
|
||
v__ast__IdentFn* ptr = memdup(x, sizeof(v__ast__IdentFn));
|
||
return (v__ast__IdentInfo){ ._v__ast__IdentFn = ptr, ._typ = 379};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__IndexExpr_to_sumtype_v__ast__Expr(v__ast__IndexExpr* x) {
|
||
v__ast__IndexExpr* ptr = memdup(x, sizeof(v__ast__IndexExpr));
|
||
return (v__ast__Expr){ ._v__ast__IndexExpr = ptr, ._typ = 273};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue int_to_sumtype_v__ast__ComptTimeConstValue(int* x) {
|
||
int* ptr = memdup(x, sizeof(int));
|
||
return (v__ast__ComptTimeConstValue){ ._int = ptr, ._typ = 7};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue f64_to_sumtype_v__ast__ComptTimeConstValue(f64* x) {
|
||
f64* ptr = memdup(x, sizeof(f64));
|
||
return (v__ast__ComptTimeConstValue){ ._f64 = ptr, ._typ = 16};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue u64_to_sumtype_v__ast__ComptTimeConstValue(u64* x) {
|
||
u64* ptr = memdup(x, sizeof(u64));
|
||
return (v__ast__ComptTimeConstValue){ ._u64 = ptr, ._typ = 13};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue i64_to_sumtype_v__ast__ComptTimeConstValue(i64* x) {
|
||
i64* ptr = memdup(x, sizeof(i64));
|
||
return (v__ast__ComptTimeConstValue){ ._i64 = ptr, ._typ = 8};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue string_to_sumtype_v__ast__ComptTimeConstValue(string* x) {
|
||
string* ptr = memdup(x, sizeof(string));
|
||
return (v__ast__ComptTimeConstValue){ ._string = ptr, ._typ = 20};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue rune_to_sumtype_v__ast__ComptTimeConstValue(rune* x) {
|
||
rune* ptr = memdup(x, sizeof(rune));
|
||
return (v__ast__ComptTimeConstValue){ ._rune = ptr, ._typ = 21};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue i8_to_sumtype_v__ast__ComptTimeConstValue(i8* x) {
|
||
i8* ptr = memdup(x, sizeof(i8));
|
||
return (v__ast__ComptTimeConstValue){ ._i8 = ptr, ._typ = 5};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue i16_to_sumtype_v__ast__ComptTimeConstValue(i16* x) {
|
||
i16* ptr = memdup(x, sizeof(i16));
|
||
return (v__ast__ComptTimeConstValue){ ._i16 = ptr, ._typ = 6};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue u8_to_sumtype_v__ast__ComptTimeConstValue(u8* x) {
|
||
u8* ptr = memdup(x, sizeof(u8));
|
||
return (v__ast__ComptTimeConstValue){ ._u8 = ptr, ._typ = 10};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue u16_to_sumtype_v__ast__ComptTimeConstValue(u16* x) {
|
||
u16* ptr = memdup(x, sizeof(u16));
|
||
return (v__ast__ComptTimeConstValue){ ._u16 = ptr, ._typ = 11};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue u32_to_sumtype_v__ast__ComptTimeConstValue(u32* x) {
|
||
u32* ptr = memdup(x, sizeof(u32));
|
||
return (v__ast__ComptTimeConstValue){ ._u32 = ptr, ._typ = 12};
|
||
}
|
||
|
||
static inline v__ast__ComptTimeConstValue f32_to_sumtype_v__ast__ComptTimeConstValue(f32* x) {
|
||
f32* ptr = memdup(x, sizeof(f32));
|
||
return (v__ast__ComptTimeConstValue){ ._f32 = ptr, ._typ = 15};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__Return_to_sumtype_v__ast__Stmt(v__ast__Return* x) {
|
||
v__ast__Return* ptr = memdup(x, sizeof(v__ast__Return));
|
||
return (v__ast__Stmt){ ._v__ast__Return = ptr, ._typ = 321, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__Return, pos))};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Aggregate_to_sumtype_v__ast__TypeInfo(v__ast__Aggregate* x) {
|
||
v__ast__Aggregate* ptr = memdup(x, sizeof(v__ast__Aggregate));
|
||
return (v__ast__TypeInfo){ ._v__ast__Aggregate = ptr, ._typ = 434};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__Ident_to_sumtype_v__ast__Expr(v__ast__Ident* x) {
|
||
v__ast__Ident* ptr = memdup(x, sizeof(v__ast__Ident));
|
||
return (v__ast__Expr){ ._v__ast__Ident = ptr, ._typ = 270};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__AssertStmt_to_sumtype_v__ast__Stmt(v__ast__AssertStmt* x) {
|
||
v__ast__AssertStmt* ptr = memdup(x, sizeof(v__ast__AssertStmt));
|
||
return (v__ast__Stmt){ ._v__ast__AssertStmt = ptr, ._typ = 301, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AssertStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__IfExpr_to_sumtype_v__ast__Expr(v__ast__IfExpr* x) {
|
||
v__ast__IfExpr* ptr = memdup(x, sizeof(v__ast__IfExpr));
|
||
return (v__ast__Expr){ ._v__ast__IfExpr = ptr, ._typ = 271};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__BoolLiteral_to_sumtype_v__ast__Expr(v__ast__BoolLiteral* x) {
|
||
v__ast__BoolLiteral* ptr = memdup(x, sizeof(v__ast__BoolLiteral));
|
||
return (v__ast__Expr){ ._v__ast__BoolLiteral = ptr, ._typ = 254};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__MatchExpr_to_sumtype_v__ast__Expr(v__ast__MatchExpr* x) {
|
||
v__ast__MatchExpr* ptr = memdup(x, sizeof(v__ast__MatchExpr));
|
||
return (v__ast__Expr){ ._v__ast__MatchExpr = ptr, ._typ = 280};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__ForCStmt_to_sumtype_v__ast__Stmt(v__ast__ForCStmt* x) {
|
||
v__ast__ForCStmt* ptr = memdup(x, sizeof(v__ast__ForCStmt));
|
||
return (v__ast__Stmt){ ._v__ast__ForCStmt = ptr, ._typ = 311, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ForCStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__ForStmt_to_sumtype_v__ast__Stmt(v__ast__ForStmt* x) {
|
||
v__ast__ForStmt* ptr = memdup(x, sizeof(v__ast__ForStmt));
|
||
return (v__ast__Stmt){ ._v__ast__ForStmt = ptr, ._typ = 313, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ForStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__InterfaceDecl_to_sumtype_v__ast__Stmt(v__ast__InterfaceDecl* x) {
|
||
v__ast__InterfaceDecl* ptr = memdup(x, sizeof(v__ast__InterfaceDecl));
|
||
return (v__ast__Stmt){ ._v__ast__InterfaceDecl = ptr, ._typ = 319, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__InterfaceDecl, pos))};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__CallExpr_to_sumtype_v__ast__Expr(v__ast__CallExpr* x) {
|
||
v__ast__CallExpr* ptr = memdup(x, sizeof(v__ast__CallExpr));
|
||
return (v__ast__Expr){ ._v__ast__CallExpr = ptr, ._typ = 256};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__IntegerLiteral_to_sumtype_v__ast__Expr(v__ast__IntegerLiteral* x) {
|
||
v__ast__IntegerLiteral* ptr = memdup(x, sizeof(v__ast__IntegerLiteral));
|
||
return (v__ast__Expr){ ._v__ast__IntegerLiteral = ptr, ._typ = 275};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__FloatLiteral_to_sumtype_v__ast__Expr(v__ast__FloatLiteral* x) {
|
||
v__ast__FloatLiteral* ptr = memdup(x, sizeof(v__ast__FloatLiteral));
|
||
return (v__ast__Expr){ ._v__ast__FloatLiteral = ptr, ._typ = 268};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__SqlExpr_to_sumtype_v__ast__Expr(v__ast__SqlExpr* x) {
|
||
v__ast__SqlExpr* ptr = memdup(x, sizeof(v__ast__SqlExpr));
|
||
return (v__ast__Expr){ ._v__ast__SqlExpr = ptr, ._typ = 292};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__CTempVar_to_sumtype_v__ast__Expr(v__ast__CTempVar* x) {
|
||
v__ast__CTempVar* ptr = memdup(x, sizeof(v__ast__CTempVar));
|
||
return (v__ast__Expr){ ._v__ast__CTempVar = ptr, ._typ = 255};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__SelectorExpr_to_sumtype_v__ast__Expr(v__ast__SelectorExpr* x) {
|
||
v__ast__SelectorExpr* ptr = memdup(x, sizeof(v__ast__SelectorExpr));
|
||
return (v__ast__Expr){ ._v__ast__SelectorExpr = ptr, ._typ = 290};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__ForInStmt_to_sumtype_v__ast__Stmt(v__ast__ForInStmt* x) {
|
||
v__ast__ForInStmt* ptr = memdup(x, sizeof(v__ast__ForInStmt));
|
||
return (v__ast__Stmt){ ._v__ast__ForInStmt = ptr, ._typ = 312, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ForInStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__ExprStmt_to_sumtype_v__ast__Stmt(v__ast__ExprStmt* x) {
|
||
v__ast__ExprStmt* ptr = memdup(x, sizeof(v__ast__ExprStmt));
|
||
return (v__ast__Stmt){ ._v__ast__ExprStmt = ptr, ._typ = 310, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ExprStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__NodeError_to_sumtype_v__ast__Stmt(v__ast__NodeError* x) {
|
||
v__ast__NodeError* ptr = memdup(x, sizeof(v__ast__NodeError));
|
||
return (v__ast__Stmt){ ._v__ast__NodeError = ptr, ._typ = 281, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__NodeError, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__AssignStmt_to_sumtype_v__ast__Stmt(v__ast__AssignStmt* x) {
|
||
v__ast__AssignStmt* ptr = memdup(x, sizeof(v__ast__AssignStmt));
|
||
return (v__ast__Stmt){ ._v__ast__AssignStmt = ptr, ._typ = 302, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AssignStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ComptimeCall_to_sumtype_v__ast__Expr(v__ast__ComptimeCall* x) {
|
||
v__ast__ComptimeCall* ptr = memdup(x, sizeof(v__ast__ComptimeCall));
|
||
return (v__ast__Expr){ ._v__ast__ComptimeCall = ptr, ._typ = 261};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ComptimeSelector_to_sumtype_v__ast__Expr(v__ast__ComptimeSelector* x) {
|
||
v__ast__ComptimeSelector* ptr = memdup(x, sizeof(v__ast__ComptimeSelector));
|
||
return (v__ast__Expr){ ._v__ast__ComptimeSelector = ptr, ._typ = 262};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__NodeError_to_sumtype_v__ast__Expr(v__ast__NodeError* x) {
|
||
v__ast__NodeError* ptr = memdup(x, sizeof(v__ast__NodeError));
|
||
return (v__ast__Expr){ ._v__ast__NodeError = ptr, ._typ = 281};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__Comment_to_sumtype_v__ast__Expr(v__ast__Comment* x) {
|
||
v__ast__Comment* ptr = memdup(x, sizeof(v__ast__Comment));
|
||
return (v__ast__Expr){ ._v__ast__Comment = ptr, ._typ = 260};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__EnumVal_to_sumtype_v__ast__Expr(v__ast__EnumVal* x) {
|
||
v__ast__EnumVal* ptr = memdup(x, sizeof(v__ast__EnumVal));
|
||
return (v__ast__Expr){ ._v__ast__EnumVal = ptr, ._typ = 267};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__AtExpr_to_sumtype_v__ast__Expr(v__ast__AtExpr* x) {
|
||
v__ast__AtExpr* ptr = memdup(x, sizeof(v__ast__AtExpr));
|
||
return (v__ast__Expr){ ._v__ast__AtExpr = ptr, ._typ = 253};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ComptimeType_to_sumtype_v__ast__Expr(v__ast__ComptimeType* x) {
|
||
v__ast__ComptimeType* ptr = memdup(x, sizeof(v__ast__ComptimeType));
|
||
return (v__ast__Expr){ ._v__ast__ComptimeType = ptr, ._typ = 263};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__CharLiteral_to_sumtype_v__ast__Expr(v__ast__CharLiteral* x) {
|
||
v__ast__CharLiteral* ptr = memdup(x, sizeof(v__ast__CharLiteral));
|
||
return (v__ast__Expr){ ._v__ast__CharLiteral = ptr, ._typ = 259};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__GoExpr_to_sumtype_v__ast__Expr(v__ast__GoExpr* x) {
|
||
v__ast__GoExpr* ptr = memdup(x, sizeof(v__ast__GoExpr));
|
||
return (v__ast__Expr){ ._v__ast__GoExpr = ptr, ._typ = 269};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__SelectExpr_to_sumtype_v__ast__Expr(v__ast__SelectExpr* x) {
|
||
v__ast__SelectExpr* ptr = memdup(x, sizeof(v__ast__SelectExpr));
|
||
return (v__ast__Expr){ ._v__ast__SelectExpr = ptr, ._typ = 289};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ParExpr_to_sumtype_v__ast__Expr(v__ast__ParExpr* x) {
|
||
v__ast__ParExpr* ptr = memdup(x, sizeof(v__ast__ParExpr));
|
||
return (v__ast__Expr){ ._v__ast__ParExpr = ptr, ._typ = 285};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__UnsafeExpr_to_sumtype_v__ast__Expr(v__ast__UnsafeExpr* x) {
|
||
v__ast__UnsafeExpr* ptr = memdup(x, sizeof(v__ast__UnsafeExpr));
|
||
return (v__ast__Expr){ ._v__ast__UnsafeExpr = ptr, ._typ = 298};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__LockExpr_to_sumtype_v__ast__Expr(v__ast__LockExpr* x) {
|
||
v__ast__LockExpr* ptr = memdup(x, sizeof(v__ast__LockExpr));
|
||
return (v__ast__Expr){ ._v__ast__LockExpr = ptr, ._typ = 278};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__IsRefType_to_sumtype_v__ast__Expr(v__ast__IsRefType* x) {
|
||
v__ast__IsRefType* ptr = memdup(x, sizeof(v__ast__IsRefType));
|
||
return (v__ast__Expr){ ._v__ast__IsRefType = ptr, ._typ = 276};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__SizeOf_to_sumtype_v__ast__Expr(v__ast__SizeOf* x) {
|
||
v__ast__SizeOf* ptr = memdup(x, sizeof(v__ast__SizeOf));
|
||
return (v__ast__Expr){ ._v__ast__SizeOf = ptr, ._typ = 291};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__TypeOf_to_sumtype_v__ast__Expr(v__ast__TypeOf* x) {
|
||
v__ast__TypeOf* ptr = memdup(x, sizeof(v__ast__TypeOf));
|
||
return (v__ast__Expr){ ._v__ast__TypeOf = ptr, ._typ = 297};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__DumpExpr_to_sumtype_v__ast__Expr(v__ast__DumpExpr* x) {
|
||
v__ast__DumpExpr* ptr = memdup(x, sizeof(v__ast__DumpExpr));
|
||
return (v__ast__Expr){ ._v__ast__DumpExpr = ptr, ._typ = 265};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__OffsetOf_to_sumtype_v__ast__Expr(v__ast__OffsetOf* x) {
|
||
v__ast__OffsetOf* ptr = memdup(x, sizeof(v__ast__OffsetOf));
|
||
return (v__ast__Expr){ ._v__ast__OffsetOf = ptr, ._typ = 283};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__Likely_to_sumtype_v__ast__Expr(v__ast__Likely* x) {
|
||
v__ast__Likely* ptr = memdup(x, sizeof(v__ast__Likely));
|
||
return (v__ast__Expr){ ._v__ast__Likely = ptr, ._typ = 277};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__AnonFn_to_sumtype_v__ast__Expr(v__ast__AnonFn* x) {
|
||
v__ast__AnonFn* ptr = memdup(x, sizeof(v__ast__AnonFn));
|
||
return (v__ast__Expr){ ._v__ast__AnonFn = ptr, ._typ = 248};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__AsCast_to_sumtype_v__ast__Expr(v__ast__AsCast* x) {
|
||
v__ast__AsCast* ptr = memdup(x, sizeof(v__ast__AsCast));
|
||
return (v__ast__Expr){ ._v__ast__AsCast = ptr, ._typ = 251};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__PostfixExpr_to_sumtype_v__ast__Expr(v__ast__PostfixExpr* x) {
|
||
v__ast__PostfixExpr* ptr = memdup(x, sizeof(v__ast__PostfixExpr));
|
||
return (v__ast__Expr){ ._v__ast__PostfixExpr = ptr, ._typ = 286};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__PrefixExpr_to_sumtype_v__ast__Expr(v__ast__PrefixExpr* x) {
|
||
v__ast__PrefixExpr* ptr = memdup(x, sizeof(v__ast__PrefixExpr));
|
||
return (v__ast__Expr){ ._v__ast__PrefixExpr = ptr, ._typ = 287};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ArrayDecompose_to_sumtype_v__ast__Expr(v__ast__ArrayDecompose* x) {
|
||
v__ast__ArrayDecompose* ptr = memdup(x, sizeof(v__ast__ArrayDecompose));
|
||
return (v__ast__Expr){ ._v__ast__ArrayDecompose = ptr, ._typ = 249};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__IfGuardExpr_to_sumtype_v__ast__Expr(v__ast__IfGuardExpr* x) {
|
||
v__ast__IfGuardExpr* ptr = memdup(x, sizeof(v__ast__IfGuardExpr));
|
||
return (v__ast__Expr){ ._v__ast__IfGuardExpr = ptr, ._typ = 272};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__RangeExpr_to_sumtype_v__ast__Expr(v__ast__RangeExpr* x) {
|
||
v__ast__RangeExpr* ptr = memdup(x, sizeof(v__ast__RangeExpr));
|
||
return (v__ast__Expr){ ._v__ast__RangeExpr = ptr, ._typ = 288};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__GenericInst_to_sumtype_v__ast__TypeInfo(v__ast__GenericInst* x) {
|
||
v__ast__GenericInst* ptr = memdup(x, sizeof(v__ast__GenericInst));
|
||
return (v__ast__TypeInfo){ ._v__ast__GenericInst = ptr, ._typ = 449};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__Module_to_sumtype_v__ast__Stmt(v__ast__Module* x) {
|
||
v__ast__Module* ptr = memdup(x, sizeof(v__ast__Module));
|
||
return (v__ast__Stmt){ ._v__ast__Module = ptr, ._typ = 320, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__Module, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__Import_to_sumtype_v__ast__Stmt(v__ast__Import* x) {
|
||
v__ast__Import* ptr = memdup(x, sizeof(v__ast__Import));
|
||
return (v__ast__Stmt){ ._v__ast__Import = ptr, ._typ = 318, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__Import, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__ConstDecl_to_sumtype_v__ast__Stmt(v__ast__ConstDecl* x) {
|
||
v__ast__ConstDecl* ptr = memdup(x, sizeof(v__ast__ConstDecl));
|
||
return (v__ast__Stmt){ ._v__ast__ConstDecl = ptr, ._typ = 306, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ConstDecl, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__StructDecl_to_sumtype_v__ast__Stmt(v__ast__StructDecl* x) {
|
||
v__ast__StructDecl* ptr = memdup(x, sizeof(v__ast__StructDecl));
|
||
return (v__ast__Stmt){ ._v__ast__StructDecl = ptr, ._typ = 323, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__StructDecl, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__EnumDecl_to_sumtype_v__ast__Stmt(v__ast__EnumDecl* x) {
|
||
v__ast__EnumDecl* ptr = memdup(x, sizeof(v__ast__EnumDecl));
|
||
return (v__ast__Stmt){ ._v__ast__EnumDecl = ptr, ._typ = 309, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__EnumDecl, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__TypeDecl_to_sumtype_v__ast__Stmt(v__ast__TypeDecl* x) {
|
||
v__ast__TypeDecl* ptr = memdup(x, sizeof(v__ast__TypeDecl));
|
||
return (v__ast__Stmt){ ._v__ast__TypeDecl = ptr, ._typ = 247, .pos = ptr->pos};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__AsmStmt_to_sumtype_v__ast__Stmt(v__ast__AsmStmt* x) {
|
||
v__ast__AsmStmt* ptr = memdup(x, sizeof(v__ast__AsmStmt));
|
||
return (v__ast__Stmt){ ._v__ast__AsmStmt = ptr, ._typ = 300, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AsmStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__GlobalDecl_to_sumtype_v__ast__Stmt(v__ast__GlobalDecl* x) {
|
||
v__ast__GlobalDecl* ptr = memdup(x, sizeof(v__ast__GlobalDecl));
|
||
return (v__ast__Stmt){ ._v__ast__GlobalDecl = ptr, ._typ = 314, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__GlobalDecl, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__HashStmt_to_sumtype_v__ast__Stmt(v__ast__HashStmt* x) {
|
||
v__ast__HashStmt* ptr = memdup(x, sizeof(v__ast__HashStmt));
|
||
return (v__ast__Stmt){ ._v__ast__HashStmt = ptr, ._typ = 317, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__HashStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__Block_to_sumtype_v__ast__Stmt(v__ast__Block* x) {
|
||
v__ast__Block* ptr = memdup(x, sizeof(v__ast__Block));
|
||
return (v__ast__Stmt){ ._v__ast__Block = ptr, ._typ = 303, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__Block, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__SqlStmt_to_sumtype_v__ast__Stmt(v__ast__SqlStmt* x) {
|
||
v__ast__SqlStmt* ptr = memdup(x, sizeof(v__ast__SqlStmt));
|
||
return (v__ast__Stmt){ ._v__ast__SqlStmt = ptr, ._typ = 322, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__SqlStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__GotoLabel_to_sumtype_v__ast__Stmt(v__ast__GotoLabel* x) {
|
||
v__ast__GotoLabel* ptr = memdup(x, sizeof(v__ast__GotoLabel));
|
||
return (v__ast__Stmt){ ._v__ast__GotoLabel = ptr, ._typ = 315, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__GotoLabel, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__ComptimeFor_to_sumtype_v__ast__Stmt(v__ast__ComptimeFor* x) {
|
||
v__ast__ComptimeFor* ptr = memdup(x, sizeof(v__ast__ComptimeFor));
|
||
return (v__ast__Stmt){ ._v__ast__ComptimeFor = ptr, ._typ = 305, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__ComptimeFor, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__BranchStmt_to_sumtype_v__ast__Stmt(v__ast__BranchStmt* x) {
|
||
v__ast__BranchStmt* ptr = memdup(x, sizeof(v__ast__BranchStmt));
|
||
return (v__ast__Stmt){ ._v__ast__BranchStmt = ptr, ._typ = 304, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__BranchStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__DeferStmt_to_sumtype_v__ast__Stmt(v__ast__DeferStmt* x) {
|
||
v__ast__DeferStmt* ptr = memdup(x, sizeof(v__ast__DeferStmt));
|
||
return (v__ast__Stmt){ ._v__ast__DeferStmt = ptr, ._typ = 307, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__DeferStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__Stmt v__ast__GotoStmt_to_sumtype_v__ast__Stmt(v__ast__GotoStmt* x) {
|
||
v__ast__GotoStmt* ptr = memdup(x, sizeof(v__ast__GotoStmt));
|
||
return (v__ast__Stmt){ ._v__ast__GotoStmt = ptr, ._typ = 316, .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__GotoStmt, pos))};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__FloatLiteral_to_sumtype_v__ast__AsmArg(v__ast__FloatLiteral* x) {
|
||
v__ast__FloatLiteral* ptr = memdup(x, sizeof(v__ast__FloatLiteral));
|
||
return (v__ast__AsmArg){ ._v__ast__FloatLiteral = ptr, ._typ = 268};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__AsmDisp_to_sumtype_v__ast__AsmArg(v__ast__AsmDisp* x) {
|
||
v__ast__AsmDisp* ptr = memdup(x, sizeof(v__ast__AsmDisp));
|
||
return (v__ast__AsmArg){ ._v__ast__AsmDisp = ptr, ._typ = 402};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__IntegerLiteral_to_sumtype_v__ast__AsmArg(v__ast__IntegerLiteral* x) {
|
||
v__ast__IntegerLiteral* ptr = memdup(x, sizeof(v__ast__IntegerLiteral));
|
||
return (v__ast__AsmArg){ ._v__ast__IntegerLiteral = ptr, ._typ = 275};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__CharLiteral_to_sumtype_v__ast__AsmArg(v__ast__CharLiteral* x) {
|
||
v__ast__CharLiteral* ptr = memdup(x, sizeof(v__ast__CharLiteral));
|
||
return (v__ast__AsmArg){ ._v__ast__CharLiteral = ptr, ._typ = 259};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__AsmAddressing_to_sumtype_v__ast__AsmArg(v__ast__AsmAddressing* x) {
|
||
v__ast__AsmAddressing* ptr = memdup(x, sizeof(v__ast__AsmAddressing));
|
||
return (v__ast__AsmArg){ ._v__ast__AsmAddressing = ptr, ._typ = 400};
|
||
}
|
||
|
||
static inline v__ast__AsmArg v__ast__AsmAlias_to_sumtype_v__ast__AsmArg(v__ast__AsmAlias* x) {
|
||
v__ast__AsmAlias* ptr = memdup(x, sizeof(v__ast__AsmAlias));
|
||
return (v__ast__AsmArg){ ._v__ast__AsmAlias = ptr, ._typ = 401};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ConcatExpr_to_sumtype_v__ast__Expr(v__ast__ConcatExpr* x) {
|
||
v__ast__ConcatExpr* ptr = memdup(x, sizeof(v__ast__ConcatExpr));
|
||
return (v__ast__Expr){ ._v__ast__ConcatExpr = ptr, ._typ = 264};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__ChanInit_to_sumtype_v__ast__Expr(v__ast__ChanInit* x) {
|
||
v__ast__ChanInit* ptr = memdup(x, sizeof(v__ast__ChanInit));
|
||
return (v__ast__Expr){ ._v__ast__ChanInit = ptr, ._typ = 258};
|
||
}
|
||
|
||
static inline v__ast__Expr v__ast__StringInterLiteral_to_sumtype_v__ast__Expr(v__ast__StringInterLiteral* x) {
|
||
v__ast__StringInterLiteral* ptr = memdup(x, sizeof(v__ast__StringInterLiteral));
|
||
return (v__ast__Expr){ ._v__ast__StringInterLiteral = ptr, ._typ = 293};
|
||
}
|
||
|
||
static inline v__ast__ScopeObject v__ast__GlobalField_to_sumtype_v__ast__ScopeObject(v__ast__GlobalField* x) {
|
||
v__ast__GlobalField* ptr = memdup(x, sizeof(v__ast__GlobalField));
|
||
return (v__ast__ScopeObject){ ._v__ast__GlobalField = ptr, ._typ = 327, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__GlobalField, name)), .typ = (v__ast__Type*)((char*)ptr + __offsetof_ptr(ptr, v__ast__GlobalField, typ))};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Enum_to_sumtype_v__ast__TypeInfo(v__ast__Enum* x) {
|
||
v__ast__Enum* ptr = memdup(x, sizeof(v__ast__Enum));
|
||
return (v__ast__TypeInfo){ ._v__ast__Enum = ptr, ._typ = 450};
|
||
}
|
||
|
||
static inline v__ast__TypeDecl v__ast__SumTypeDecl_to_sumtype_v__ast__TypeDecl(v__ast__SumTypeDecl* x) {
|
||
v__ast__SumTypeDecl* ptr = memdup(x, sizeof(v__ast__SumTypeDecl));
|
||
return (v__ast__TypeDecl){ ._v__ast__SumTypeDecl = ptr, ._typ = 246, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__SumTypeDecl, name)), .is_pub = (bool*)((char*)ptr + __offsetof_ptr(ptr, v__ast__SumTypeDecl, is_pub)), .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__SumTypeDecl, pos)), .comments = (Array_v__ast__Comment*)((char*)ptr + __offsetof_ptr(ptr, v__ast__SumTypeDecl, comments))};
|
||
}
|
||
|
||
static inline v__ast__TypeDecl v__ast__FnTypeDecl_to_sumtype_v__ast__TypeDecl(v__ast__FnTypeDecl* x) {
|
||
v__ast__FnTypeDecl* ptr = memdup(x, sizeof(v__ast__FnTypeDecl));
|
||
return (v__ast__TypeDecl){ ._v__ast__FnTypeDecl = ptr, ._typ = 245, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__FnTypeDecl, name)), .is_pub = (bool*)((char*)ptr + __offsetof_ptr(ptr, v__ast__FnTypeDecl, is_pub)), .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__FnTypeDecl, pos)), .comments = (Array_v__ast__Comment*)((char*)ptr + __offsetof_ptr(ptr, v__ast__FnTypeDecl, comments))};
|
||
}
|
||
|
||
static inline v__ast__TypeDecl v__ast__AliasTypeDecl_to_sumtype_v__ast__TypeDecl(v__ast__AliasTypeDecl* x) {
|
||
v__ast__AliasTypeDecl* ptr = memdup(x, sizeof(v__ast__AliasTypeDecl));
|
||
return (v__ast__TypeDecl){ ._v__ast__AliasTypeDecl = ptr, ._typ = 244, .name = (string*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AliasTypeDecl, name)), .is_pub = (bool*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AliasTypeDecl, is_pub)), .pos = (v__token__Pos*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AliasTypeDecl, pos)), .comments = (Array_v__ast__Comment*)((char*)ptr + __offsetof_ptr(ptr, v__ast__AliasTypeDecl, comments))};
|
||
}
|
||
|
||
static inline v__ast__TypeInfo v__ast__Alias_to_sumtype_v__ast__TypeInfo(v__ast__Alias* x) {
|
||
v__ast__Alias* ptr = memdup(x, sizeof(v__ast__Alias));
|
||
return (v__ast__TypeInfo){ ._v__ast__Alias = ptr, ._typ = 436};
|
||
}
|
||
|
||
static inline v__ast__Node v__ast__File_to_sumtype_v__ast__Node(v__ast__File* x) {
|
||
v__ast__File* ptr = memdup(x, sizeof(v__ast__File));
|
||
return (v__ast__Node){ ._v__ast__File = ptr, ._typ = 176};
|
||
}
|
||
|
||
static bool Array_string_contains(Array_string a, string v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (fast_string_eq(((string*)a.data)[i], v)) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_v__token__Kind_contains(Array_v__token__Kind a, v__token__Kind v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (((v__token__Kind*)a.data)[i] == v) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_u8_contains(Array_u8 a, u8 v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (((u8*)a.data)[i] == v) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_Array_v__ast__Type_contains(Array_Array_v__ast__Type a, Array_v__ast__Type v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (Array_v__ast__Type_arr_eq(((Array_v__ast__Type*)a.data)[i], v)) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_v__ast__Type_contains(Array_v__ast__Type a, v__ast__Type v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (v__ast__Type_alias_eq(((v__ast__Type*)a.data)[i], v)) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_int_contains(Array_int a, int v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (((int*)a.data)[i] == v) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_i64_contains(Array_i64 a, i64 v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (((i64*)a.data)[i] == v) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_v__gen__c__StrType_contains(Array_v__gen__c__StrType a, v__gen__c__StrType v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (v__gen__c__StrType_struct_eq(((v__gen__c__StrType*)a.data)[i], v)) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_v__gen__c__SumtypeCastingFn_contains(Array_v__gen__c__SumtypeCastingFn a, v__gen__c__SumtypeCastingFn v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (v__gen__c__SumtypeCastingFn_struct_eq(((v__gen__c__SumtypeCastingFn*)a.data)[i], v)) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_v__ast__EmbeddedFile_contains(Array_v__ast__EmbeddedFile a, v__ast__EmbeddedFile v) {
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (v__ast__EmbeddedFile_struct_eq(((v__ast__EmbeddedFile*)a.data)[i], v)) {
|
||
return true;
|
||
}
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static int Array_string_index(Array_string a, string v) {
|
||
string* pelem = a.data;
|
||
for (int i = 0; i < a.len; ++i, ++pelem) {
|
||
if (fast_string_eq(*pelem, v)) {
|
||
return i;
|
||
}
|
||
}
|
||
return -1;
|
||
}
|
||
|
||
static bool Array_rune_arr_eq(Array_rune a, Array_rune b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (*((rune*)((byte*)a.data+(i*a.element_size))) != *((rune*)((byte*)b.data+(i*b.element_size)))) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool time__Duration_alias_eq(time__Duration a, time__Duration b) {
|
||
return a == b;
|
||
}
|
||
|
||
static bool v__ast__Type_alias_eq(v__ast__Type a, v__ast__Type b) {
|
||
return a == b;
|
||
}
|
||
|
||
static bool Array_string_arr_eq(Array_string a, Array_string b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!string__eq(*((string*)((byte*)a.data+(i*a.element_size))), *((string*)((byte*)b.data+(i*b.element_size))))) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__token__Pos_struct_eq(v__token__Pos a, v__token__Pos b) {
|
||
return a.len == b.len
|
||
&& a.line_nr == b.line_nr
|
||
&& a.pos == b.pos
|
||
&& a.col == b.col
|
||
&& a.last_line == b.last_line;
|
||
}
|
||
|
||
static bool Array_v__ast__Type_arr_eq(Array_v__ast__Type a, Array_v__ast__Type b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Type_alias_eq(((v__ast__Type*)a.data)[i], ((v__ast__Type*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__AsmRegister_struct_eq(v__ast__AsmRegister a, v__ast__AsmRegister b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.size == b.size;
|
||
}
|
||
|
||
static bool v__ast__Comment_struct_eq(v__ast__Comment a, v__ast__Comment b) {
|
||
return string__eq(a.text, b.text)
|
||
&& a.is_multi == b.is_multi
|
||
&& a.is_inline == b.is_inline
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool Array_v__ast__Comment_arr_eq(Array_v__ast__Comment a, Array_v__ast__Comment b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Comment_struct_eq(((v__ast__Comment*)a.data)[i], ((v__ast__Comment*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__AsmClobbered_struct_eq(v__ast__AsmClobbered a, v__ast__AsmClobbered b) {
|
||
return v__ast__AsmRegister_struct_eq(a.reg, b.reg)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments);
|
||
}
|
||
|
||
static bool Array_v__ast__AsmClobbered_arr_eq(Array_v__ast__AsmClobbered a, Array_v__ast__AsmClobbered b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__AsmClobbered_struct_eq(((v__ast__AsmClobbered*)a.data)[i], ((v__ast__AsmClobbered*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__AsmAddressing_struct_eq(v__ast__AsmAddressing a, v__ast__AsmAddressing b) {
|
||
return a.scale == b.scale
|
||
&& a.mode == b.mode
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& string__eq(a.segment, b.segment)
|
||
&& v__ast__AsmArg_sumtype_eq(a.displacement, b.displacement)
|
||
&& v__ast__AsmArg_sumtype_eq(a.base, b.base)
|
||
&& v__ast__AsmArg_sumtype_eq(a.index, b.index);
|
||
}
|
||
|
||
static bool v__ast__AsmAlias_struct_eq(v__ast__AsmAlias a, v__ast__AsmAlias b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& string__eq(a.name, b.name);
|
||
}
|
||
|
||
static bool v__ast__AsmDisp_struct_eq(v__ast__AsmDisp a, v__ast__AsmDisp b) {
|
||
return string__eq(a.val, b.val)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__BoolLiteral_struct_eq(v__ast__BoolLiteral a, v__ast__BoolLiteral b) {
|
||
return a.val == b.val
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__CharLiteral_struct_eq(v__ast__CharLiteral a, v__ast__CharLiteral b) {
|
||
return string__eq(a.val, b.val)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__FloatLiteral_struct_eq(v__ast__FloatLiteral a, v__ast__FloatLiteral b) {
|
||
return string__eq(a.val, b.val)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__IntegerLiteral_struct_eq(v__ast__IntegerLiteral a, v__ast__IntegerLiteral b) {
|
||
return string__eq(a.val, b.val)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__AsmArg_sumtype_eq(v__ast__AsmArg a, v__ast__AsmArg b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 400) {
|
||
return v__ast__AsmAddressing_struct_eq(*a._v__ast__AsmAddressing, *b._v__ast__AsmAddressing);
|
||
}
|
||
if (a._typ == 401) {
|
||
return v__ast__AsmAlias_struct_eq(*a._v__ast__AsmAlias, *b._v__ast__AsmAlias);
|
||
}
|
||
if (a._typ == 402) {
|
||
return v__ast__AsmDisp_struct_eq(*a._v__ast__AsmDisp, *b._v__ast__AsmDisp);
|
||
}
|
||
if (a._typ == 325) {
|
||
return v__ast__AsmRegister_struct_eq(*a._v__ast__AsmRegister, *b._v__ast__AsmRegister);
|
||
}
|
||
if (a._typ == 254) {
|
||
return v__ast__BoolLiteral_struct_eq(*a._v__ast__BoolLiteral, *b._v__ast__BoolLiteral);
|
||
}
|
||
if (a._typ == 259) {
|
||
return v__ast__CharLiteral_struct_eq(*a._v__ast__CharLiteral, *b._v__ast__CharLiteral);
|
||
}
|
||
if (a._typ == 268) {
|
||
return v__ast__FloatLiteral_struct_eq(*a._v__ast__FloatLiteral, *b._v__ast__FloatLiteral);
|
||
}
|
||
if (a._typ == 275) {
|
||
return v__ast__IntegerLiteral_struct_eq(*a._v__ast__IntegerLiteral, *b._v__ast__IntegerLiteral);
|
||
}
|
||
if (a._typ == 20) {
|
||
return string__eq(*a._string, *b._string);
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool Array_v__ast__AsmArg_arr_eq(Array_v__ast__AsmArg a, Array_v__ast__AsmArg b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__AsmArg_sumtype_eq(((v__ast__AsmArg*)a.data)[i], ((v__ast__AsmArg*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__AsmTemplate_struct_eq(v__ast__AsmTemplate a, v__ast__AsmTemplate b) {
|
||
return Array_v__ast__AsmArg_arr_eq(a.args, b.args)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_label == b.is_label
|
||
&& a.is_directive == b.is_directive;
|
||
}
|
||
|
||
static bool Array_v__ast__AsmTemplate_arr_eq(Array_v__ast__AsmTemplate a, Array_v__ast__AsmTemplate b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__AsmTemplate_struct_eq(((v__ast__AsmTemplate*)a.data)[i], ((v__ast__AsmTemplate*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__Attr_struct_eq(v__ast__Attr a, v__ast__Attr b) {
|
||
return string__eq(a.name, b.name)
|
||
&& string__eq(a.arg, b.arg)
|
||
&& v__ast__Expr_sumtype_eq(a.ct_expr, b.ct_expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.kind == b.kind
|
||
&& a.has_arg == b.has_arg
|
||
&& a.ct_opt == b.ct_opt
|
||
&& a.ct_evaled == b.ct_evaled
|
||
&& a.ct_skip == b.ct_skip;
|
||
}
|
||
|
||
static bool Array_v__ast__Attr_arr_eq(Array_v__ast__Attr a, Array_v__ast__Attr b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Attr_struct_eq(((v__ast__Attr*)a.data)[i], ((v__ast__Attr*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__StructField_struct_eq(v__ast__StructField a, v__ast__StructField b) {
|
||
return Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& string__eq(a.default_val, b.default_val)
|
||
&& string__eq(a.deprecation_msg, b.deprecation_msg)
|
||
&& string__eq(a.deprecated_after, b.deprecated_after)
|
||
&& v__ast__Expr_sumtype_eq(a.default_expr, b.default_expr)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.type_pos, b.type_pos)
|
||
&& a.i == b.i
|
||
&& v__ast__Type_alias_eq(a.default_expr_typ, b.default_expr_typ)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.has_default_expr == b.has_default_expr
|
||
&& a.is_pub == b.is_pub
|
||
&& a.is_mut == b.is_mut
|
||
&& a.is_global == b.is_global
|
||
&& a.is_volatile == b.is_volatile
|
||
&& a.is_deprecated == b.is_deprecated;
|
||
}
|
||
|
||
static bool v__ast__Param_struct_eq(v__ast__Param a, v__ast__Param b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.type_pos, b.type_pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.is_mut == b.is_mut
|
||
&& a.is_auto_rec == b.is_auto_rec
|
||
&& a.is_hidden == b.is_hidden;
|
||
}
|
||
|
||
static bool Array_v__ast__Param_arr_eq(Array_v__ast__Param a, Array_v__ast__Param b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Param_struct_eq(((v__ast__Param*)a.data)[i], ((v__ast__Param*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Array_v__ast__Stmt_arr_eq(Array_v__ast__Stmt a, Array_v__ast__Stmt b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Stmt_sumtype_eq(((v__ast__Stmt*)a.data)[i], ((v__ast__Stmt*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__EmptyExpr_struct_eq(v__ast__EmptyExpr a, v__ast__EmptyExpr b) {
|
||
return a.x == b.x;
|
||
}
|
||
|
||
static bool v__ast__ComptTimeConstValue_sumtype_eq(v__ast__ComptTimeConstValue a, v__ast__ComptTimeConstValue b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 266) {
|
||
return v__ast__EmptyExpr_struct_eq(*a._v__ast__EmptyExpr, *b._v__ast__EmptyExpr);
|
||
}
|
||
if (a._typ == 15) {
|
||
return *a._f32 == *b._f32;
|
||
}
|
||
if (a._typ == 16) {
|
||
return *a._f64 == *b._f64;
|
||
}
|
||
if (a._typ == 6) {
|
||
return *a._i16 == *b._i16;
|
||
}
|
||
if (a._typ == 8) {
|
||
return *a._i64 == *b._i64;
|
||
}
|
||
if (a._typ == 5) {
|
||
return *a._i8 == *b._i8;
|
||
}
|
||
if (a._typ == 7) {
|
||
return *a._int == *b._int;
|
||
}
|
||
if (a._typ == 21) {
|
||
return *a._rune == *b._rune;
|
||
}
|
||
if (a._typ == 20) {
|
||
return string__eq(*a._string, *b._string);
|
||
}
|
||
if (a._typ == 11) {
|
||
return *a._u16 == *b._u16;
|
||
}
|
||
if (a._typ == 12) {
|
||
return *a._u32 == *b._u32;
|
||
}
|
||
if (a._typ == 13) {
|
||
return *a._u64 == *b._u64;
|
||
}
|
||
if (a._typ == 10) {
|
||
return *a._u8 == *b._u8;
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool v__ast__ConstField_struct_eq(v__ast__ConstField a, v__ast__ConstField b) {
|
||
return string__eq(a.mod, b.mod)
|
||
&& string__eq(a.name, b.name)
|
||
&& a.is_pub == b.is_pub
|
||
&& a.is_markused == b.is_markused
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.end_comments, b.end_comments)
|
||
&& v__ast__ComptTimeConstValue_sumtype_eq(a.comptime_expr_value, b.comptime_expr_value);
|
||
}
|
||
|
||
static bool v__ast__GlobalField_struct_eq(v__ast__GlobalField a, v__ast__GlobalField b) {
|
||
return Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.typ_pos, b.typ_pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.has_expr == b.has_expr
|
||
&& a.is_markused == b.is_markused
|
||
&& a.is_volatile == b.is_volatile;
|
||
}
|
||
|
||
static bool v__ast__Var_struct_eq(v__ast__Var a, v__ast__Var b) {
|
||
return Array_v__ast__Type_arr_eq(a.smartcasts, b.smartcasts)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.orig_type, b.orig_type)
|
||
&& a.share == b.share
|
||
&& a.is_mut == b.is_mut
|
||
&& a.is_autofree_tmp == b.is_autofree_tmp
|
||
&& a.is_arg == b.is_arg
|
||
&& a.is_auto_deref == b.is_auto_deref
|
||
&& a.is_inherited == b.is_inherited
|
||
&& a.is_used == b.is_used
|
||
&& a.is_changed == b.is_changed
|
||
&& a.is_or == b.is_or
|
||
&& a.is_tmp == b.is_tmp
|
||
&& a.is_auto_heap == b.is_auto_heap
|
||
&& a.is_stack_obj == b.is_stack_obj;
|
||
}
|
||
|
||
static bool v__ast__ScopeObject_sumtype_eq(v__ast__ScopeObject a, v__ast__ScopeObject b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 325) {
|
||
return v__ast__AsmRegister_struct_eq(*a._v__ast__AsmRegister, *b._v__ast__AsmRegister);
|
||
}
|
||
if (a._typ == 326) {
|
||
return v__ast__ConstField_struct_eq(*a._v__ast__ConstField, *b._v__ast__ConstField);
|
||
}
|
||
if (a._typ == 327) {
|
||
return v__ast__GlobalField_struct_eq(*a._v__ast__GlobalField, *b._v__ast__GlobalField);
|
||
}
|
||
if (a._typ == 328) {
|
||
return v__ast__Var_struct_eq(*a._v__ast__Var, *b._v__ast__Var);
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool v__ast__IdentFn_struct_eq(v__ast__IdentFn a, v__ast__IdentFn b) {
|
||
return v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__ast__IdentVar_struct_eq(v__ast__IdentVar a, v__ast__IdentVar b) {
|
||
return v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.share == b.share
|
||
&& a.is_mut == b.is_mut
|
||
&& a.is_static == b.is_static
|
||
&& a.is_volatile == b.is_volatile
|
||
&& a.is_optional == b.is_optional;
|
||
}
|
||
|
||
static bool v__ast__IdentInfo_sumtype_eq(v__ast__IdentInfo a, v__ast__IdentInfo b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 379) {
|
||
return v__ast__IdentFn_struct_eq(*a._v__ast__IdentFn, *b._v__ast__IdentFn);
|
||
}
|
||
if (a._typ == 380) {
|
||
return v__ast__IdentVar_struct_eq(*a._v__ast__IdentVar, *b._v__ast__IdentVar);
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool v__ast__Ident_struct_eq(v__ast__Ident a, v__ast__Ident b) {
|
||
return v__ast__ScopeObject_sumtype_eq(a.obj, b.obj)
|
||
&& string__eq(a.mod, b.mod)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__ast__IdentInfo_sumtype_eq(a.info, b.info)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.mut_pos, b.mut_pos)
|
||
&& a.tok_kind == b.tok_kind
|
||
&& a.language == b.language
|
||
&& a.kind == b.kind
|
||
&& a.comptime == b.comptime
|
||
&& a.is_mut == b.is_mut;
|
||
}
|
||
|
||
static bool Array_v__ast__Ident_arr_eq(Array_v__ast__Ident a, Array_v__ast__Ident b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Ident_struct_eq(((v__ast__Ident*)a.data)[i], ((v__ast__Ident*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__DeferStmt_struct_eq(v__ast__DeferStmt a, v__ast__DeferStmt b) {
|
||
return Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& Array_v__ast__Ident_arr_eq(a.defer_vars, b.defer_vars)
|
||
&& string__eq(a.ifdef, b.ifdef)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.idx_in_fn == b.idx_in_fn;
|
||
}
|
||
|
||
static bool Array_v__ast__DeferStmt_arr_eq(Array_v__ast__DeferStmt a, Array_v__ast__DeferStmt b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__DeferStmt_struct_eq(((v__ast__DeferStmt*)a.data)[i], ((v__ast__DeferStmt*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__FnDecl_struct_eq(v__ast__FnDecl a, v__ast__FnDecl b) {
|
||
return v__ast__StructField_struct_eq(a.receiver, b.receiver)
|
||
&& Array_string_arr_eq(a.generic_names, b.generic_names)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& Array_v__ast__Param_arr_eq(a.params, b.params)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& Array_v__ast__DeferStmt_arr_eq(a.defer_stmts, b.defer_stmts)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.end_comments, b.end_comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.next_comments, b.next_comments)
|
||
&& Array_string_arr_eq(a.label_names, b.label_names)
|
||
&& string__eq(a.name, b.name)
|
||
&& string__eq(a.short_name, b.short_name)
|
||
&& string__eq(a.mod, b.mod)
|
||
&& string__eq(a.file, b.file)
|
||
&& a.source_file == b.source_file
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.receiver_pos, b.receiver_pos)
|
||
&& v__token__Pos_struct_eq(a.method_type_pos, b.method_type_pos)
|
||
&& v__token__Pos_struct_eq(a.body_pos, b.body_pos)
|
||
&& v__token__Pos_struct_eq(a.return_type_pos, b.return_type_pos)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.method_idx == b.method_idx
|
||
&& a.ctdefine_idx == b.ctdefine_idx
|
||
&& a.idx == b.idx
|
||
&& v__ast__Type_alias_eq(a.return_type, b.return_type)
|
||
&& a.ninstances == b.ninstances
|
||
&& a.language == b.language
|
||
&& a.file_mode == b.file_mode
|
||
&& a.rec_share == b.rec_share
|
||
&& a.is_deprecated == b.is_deprecated
|
||
&& a.is_pub == b.is_pub
|
||
&& a.is_variadic == b.is_variadic
|
||
&& a.is_anon == b.is_anon
|
||
&& a.is_noreturn == b.is_noreturn
|
||
&& a.is_manualfree == b.is_manualfree
|
||
&& a.is_main == b.is_main
|
||
&& a.is_test == b.is_test
|
||
&& a.is_conditional == b.is_conditional
|
||
&& a.is_exported == b.is_exported
|
||
&& a.is_keep_alive == b.is_keep_alive
|
||
&& a.is_unsafe == b.is_unsafe
|
||
&& a.is_markused == b.is_markused
|
||
&& a.is_method == b.is_method
|
||
&& a.rec_mut == b.rec_mut
|
||
&& a.no_body == b.no_body
|
||
&& a.is_builtin == b.is_builtin
|
||
&& a.is_direct_arr == b.is_direct_arr
|
||
&& a.has_return == b.has_return
|
||
&& a.should_be_skipped == b.should_be_skipped
|
||
&& a.has_await == b.has_await;
|
||
}
|
||
|
||
static bool v__ast__AnonFn_struct_eq(v__ast__AnonFn a, v__ast__AnonFn b) {
|
||
return v__ast__FnDecl_struct_eq(a.decl, b.decl)
|
||
&& Array_v__ast__Param_arr_eq(a.inherited_vars, b.inherited_vars)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.has_gen == b.has_gen;
|
||
}
|
||
|
||
static bool v__ast__ArrayDecompose_struct_eq(v__ast__ArrayDecompose a, v__ast__ArrayDecompose b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type)
|
||
&& v__ast__Type_alias_eq(a.arg_type, b.arg_type);
|
||
}
|
||
|
||
static bool Array_Array_v__ast__Comment_arr_eq(Array_Array_v__ast__Comment a, Array_Array_v__ast__Comment b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!Array_v__ast__Comment_arr_eq(((Array_v__ast__Comment*)a.data)[i], ((Array_v__ast__Comment*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Array_v__ast__Expr_arr_eq(Array_v__ast__Expr a, Array_v__ast__Expr b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Expr_sumtype_eq(((v__ast__Expr*)a.data)[i], ((v__ast__Expr*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__ArrayInit_struct_eq(v__ast__ArrayInit a, v__ast__ArrayInit b) {
|
||
return Array_Array_v__ast__Comment_arr_eq(a.ecmnts, b.ecmnts)
|
||
&& Array_v__ast__Comment_arr_eq(a.pre_cmnts, b.pre_cmnts)
|
||
&& Array_v__ast__Expr_arr_eq(a.exprs, b.exprs)
|
||
&& Array_v__ast__Type_arr_eq(a.expr_types, b.expr_types)
|
||
&& string__eq(a.mod, b.mod)
|
||
&& v__ast__Expr_sumtype_eq(a.len_expr, b.len_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.cap_expr, b.cap_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.default_expr, b.default_expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.elem_type_pos, b.elem_type_pos)
|
||
&& v__ast__Type_alias_eq(a.elem_type, b.elem_type)
|
||
&& v__ast__Type_alias_eq(a.default_type, b.default_type)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.is_fixed == b.is_fixed
|
||
&& a.has_val == b.has_val
|
||
&& a.has_len == b.has_len
|
||
&& a.has_cap == b.has_cap
|
||
&& a.has_default == b.has_default
|
||
&& a.has_it == b.has_it;
|
||
}
|
||
|
||
static bool v__ast__AsCast_struct_eq(v__ast__AsCast a, v__ast__AsCast b) {
|
||
return v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type);
|
||
}
|
||
|
||
static bool v__ast__Assoc_struct_eq(v__ast__Assoc a, v__ast__Assoc b) {
|
||
return Array_string_arr_eq(a.fields, b.fields)
|
||
&& Array_v__ast__Expr_arr_eq(a.exprs, b.exprs)
|
||
&& string__eq(a.var_name, b.var_name)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__ast__AtExpr_struct_eq(v__ast__AtExpr a, v__ast__AtExpr b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.kind == b.kind
|
||
&& string__eq(a.val, b.val);
|
||
}
|
||
|
||
static bool v__ast__CTempVar_struct_eq(v__ast__CTempVar a, v__ast__CTempVar b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.is_ptr == b.is_ptr
|
||
&& v__ast__Expr_sumtype_eq(a.orig, b.orig);
|
||
}
|
||
|
||
static bool v__ast__OrExpr_struct_eq(v__ast__OrExpr a, v__ast__OrExpr b) {
|
||
return Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& a.kind == b.kind
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__CallArg_struct_eq(v__ast__CallArg a, v__ast__CallArg b) {
|
||
return Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.share == b.share
|
||
&& a.is_mut == b.is_mut
|
||
&& a.is_tmp_autofree == b.is_tmp_autofree;
|
||
}
|
||
|
||
static bool Array_v__ast__CallArg_arr_eq(Array_v__ast__CallArg a, Array_v__ast__CallArg b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__CallArg_struct_eq(((v__ast__CallArg*)a.data)[i], ((v__ast__CallArg*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__CallExpr_struct_eq(v__ast__CallExpr a, v__ast__CallExpr b) {
|
||
return v__ast__OrExpr_struct_eq(a.or_block, b.or_block)
|
||
&& Array_v__ast__CallArg_arr_eq(a.args, b.args)
|
||
&& Array_v__ast__Type_arr_eq(a.expected_arg_types, b.expected_arg_types)
|
||
&& Array_v__ast__Type_arr_eq(a.concrete_types, b.concrete_types)
|
||
&& Array_v__ast__Type_arr_eq(a.raw_concrete_types, b.raw_concrete_types)
|
||
&& Array_v__ast__Type_arr_eq(a.from_embed_types, b.from_embed_types)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& string__eq(a.mod, b.mod)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__ast__Expr_sumtype_eq(a.left, b.left)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.name_pos, b.name_pos)
|
||
&& v__token__Pos_struct_eq(a.concrete_list_pos, b.concrete_list_pos)
|
||
&& v__ast__Type_alias_eq(a.left_type, b.left_type)
|
||
&& v__ast__Type_alias_eq(a.receiver_type, b.receiver_type)
|
||
&& v__ast__Type_alias_eq(a.return_type, b.return_type)
|
||
&& v__ast__Type_alias_eq(a.fn_var_type, b.fn_var_type)
|
||
&& a.language == b.language
|
||
&& a.is_method == b.is_method
|
||
&& a.is_field == b.is_field
|
||
&& a.is_fn_var == b.is_fn_var
|
||
&& a.is_keep_alive == b.is_keep_alive
|
||
&& a.is_noreturn == b.is_noreturn
|
||
&& a.is_ctor_new == b.is_ctor_new
|
||
&& a.should_be_skipped == b.should_be_skipped
|
||
&& a.free_receiver == b.free_receiver;
|
||
}
|
||
|
||
static bool v__ast__CastExpr_struct_eq(v__ast__CastExpr a, v__ast__CastExpr b) {
|
||
return v__ast__Expr_sumtype_eq(a.arg, b.arg)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& string__eq(a.typname, b.typname)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type)
|
||
&& a.has_arg == b.has_arg;
|
||
}
|
||
|
||
static bool v__ast__ChanInit_struct_eq(v__ast__ChanInit a, v__ast__ChanInit b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.has_cap == b.has_cap
|
||
&& v__ast__Expr_sumtype_eq(a.cap_expr, b.cap_expr)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.elem_type, b.elem_type);
|
||
}
|
||
|
||
static bool v__ast__Module_struct_eq(v__ast__Module a, v__ast__Module b) {
|
||
return string__eq(a.name, b.name)
|
||
&& string__eq(a.short_name, b.short_name)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.name_pos, b.name_pos)
|
||
&& a.is_skipped == b.is_skipped;
|
||
}
|
||
|
||
static bool v__ast__ImportSymbol_struct_eq(v__ast__ImportSymbol a, v__ast__ImportSymbol b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& string__eq(a.name, b.name);
|
||
}
|
||
|
||
static bool Array_v__ast__ImportSymbol_arr_eq(Array_v__ast__ImportSymbol a, Array_v__ast__ImportSymbol b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__ImportSymbol_struct_eq(((v__ast__ImportSymbol*)a.data)[i], ((v__ast__ImportSymbol*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__Import_struct_eq(v__ast__Import a, v__ast__Import b) {
|
||
return string__eq(a.mod, b.mod)
|
||
&& string__eq(a.alias, b.alias)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.mod_pos, b.mod_pos)
|
||
&& v__token__Pos_struct_eq(a.alias_pos, b.alias_pos)
|
||
&& v__token__Pos_struct_eq(a.syms_pos, b.syms_pos)
|
||
&& Array_v__ast__ImportSymbol_arr_eq(a.syms, b.syms)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.next_comments, b.next_comments);
|
||
}
|
||
|
||
static bool Array_v__ast__Import_arr_eq(Array_v__ast__Import a, Array_v__ast__Import b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Import_struct_eq(((v__ast__Import*)a.data)[i], ((v__ast__Import*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Array_u8_arr_eq(Array_u8 a, Array_u8 b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (*((u8*)((byte*)a.data+(i*a.element_size))) != *((u8*)((byte*)b.data+(i*b.element_size)))) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__EmbeddedFile_struct_eq(v__ast__EmbeddedFile a, v__ast__EmbeddedFile b) {
|
||
return Array_u8_arr_eq(a.bytes, b.bytes)
|
||
&& string__eq(a.rpath, b.rpath)
|
||
&& string__eq(a.apath, b.apath)
|
||
&& string__eq(a.compression_type, b.compression_type)
|
||
&& a.len == b.len
|
||
&& a.is_compressed == b.is_compressed;
|
||
}
|
||
|
||
static bool Array_v__ast__EmbeddedFile_arr_eq(Array_v__ast__EmbeddedFile a, Array_v__ast__EmbeddedFile b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__EmbeddedFile_struct_eq(((v__ast__EmbeddedFile*)a.data)[i], ((v__ast__EmbeddedFile*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Map_string_string_map_eq(Map_string_string a, Map_string_string b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.key_values.len; ++i) {
|
||
if (!DenseArray_has_index(&a.key_values, i)) continue;
|
||
voidptr k = DenseArray_key(&a.key_values, i);
|
||
if (!map_exists(&b, k)) return false;
|
||
string v = *(string*)map_get(&a, k, &(string[]){ 0 });
|
||
if (!fast_string_eq(*(string*)map_get(&b, k, &(string[]){_SLIT("")}), v)) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__errors__Error_struct_eq(v__errors__Error a, v__errors__Error b) {
|
||
return string__eq(a.message, b.message)
|
||
&& string__eq(a.details, b.details)
|
||
&& string__eq(a.file_path, b.file_path)
|
||
&& string__eq(a.backtrace, b.backtrace)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.reporter == b.reporter;
|
||
}
|
||
|
||
static bool Array_v__errors__Error_arr_eq(Array_v__errors__Error a, Array_v__errors__Error b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__errors__Error_struct_eq(((v__errors__Error*)a.data)[i], ((v__errors__Error*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__errors__Warning_struct_eq(v__errors__Warning a, v__errors__Warning b) {
|
||
return string__eq(a.message, b.message)
|
||
&& string__eq(a.details, b.details)
|
||
&& string__eq(a.file_path, b.file_path)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.reporter == b.reporter;
|
||
}
|
||
|
||
static bool Array_v__errors__Warning_arr_eq(Array_v__errors__Warning a, Array_v__errors__Warning b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__errors__Warning_struct_eq(((v__errors__Warning*)a.data)[i], ((v__errors__Warning*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__errors__Notice_struct_eq(v__errors__Notice a, v__errors__Notice b) {
|
||
return string__eq(a.message, b.message)
|
||
&& string__eq(a.details, b.details)
|
||
&& string__eq(a.file_path, b.file_path)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.reporter == b.reporter;
|
||
}
|
||
|
||
static bool Array_v__errors__Notice_arr_eq(Array_v__errors__Notice a, Array_v__errors__Notice b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__errors__Notice_struct_eq(((v__errors__Notice*)a.data)[i], ((v__errors__Notice*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Array_v__ast__FnDecl_ptr_arr_eq(Array_v__ast__FnDecl_ptr a, Array_v__ast__FnDecl_ptr b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (*((v__ast__FnDecl**)((byte*)a.data+(i*a.element_size))) != *((v__ast__FnDecl**)((byte*)b.data+(i*b.element_size)))) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__File_struct_eq(v__ast__File a, v__ast__File b) {
|
||
return a.nr_lines == b.nr_lines
|
||
&& a.nr_bytes == b.nr_bytes
|
||
&& v__ast__Module_struct_eq(a.mod, b.mod)
|
||
&& a.global_scope == b.global_scope
|
||
&& a.is_test == b.is_test
|
||
&& a.is_generated == b.is_generated
|
||
&& a.is_translated == b.is_translated
|
||
&& a.idx == b.idx
|
||
&& string__eq(a.path, b.path)
|
||
&& string__eq(a.path_base, b.path_base)
|
||
&& a.scope == b.scope
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& Array_v__ast__Import_arr_eq(a.imports, b.imports)
|
||
&& Array_string_arr_eq(a.auto_imports, b.auto_imports)
|
||
&& Array_v__ast__EmbeddedFile_arr_eq(a.embedded_files, b.embedded_files)
|
||
&& Map_string_string_map_eq(a.imported_symbols, b.imported_symbols)
|
||
&& Array_v__errors__Error_arr_eq(a.errors, b.errors)
|
||
&& Array_v__errors__Warning_arr_eq(a.warnings, b.warnings)
|
||
&& Array_v__errors__Notice_arr_eq(a.notices, b.notices)
|
||
&& Array_v__ast__FnDecl_ptr_arr_eq(a.generic_fns, b.generic_fns)
|
||
&& Array_string_arr_eq(a.global_labels, b.global_labels);
|
||
}
|
||
|
||
static bool v__ast__ComptimeCall_struct_eq(v__ast__ComptimeCall a, v__ast__ComptimeCall b) {
|
||
return v__ast__File_struct_eq(a.vweb_tmpl, b.vweb_tmpl)
|
||
&& v__ast__EmbeddedFile_struct_eq(a.embed_file, b.embed_file)
|
||
&& Array_v__ast__CallArg_arr_eq(a.args, b.args)
|
||
&& string__eq(a.method_name, b.method_name)
|
||
&& v__ast__Expr_sumtype_eq(a.left, b.left)
|
||
&& string__eq(a.args_var, b.args_var)
|
||
&& string__eq(a.env_value, b.env_value)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.method_pos, b.method_pos)
|
||
&& v__token__Pos_struct_eq(a.env_pos, b.env_pos)
|
||
&& v__ast__Type_alias_eq(a.left_type, b.left_type)
|
||
&& v__ast__Type_alias_eq(a.result_type, b.result_type)
|
||
&& a.has_parens == b.has_parens
|
||
&& a.is_vweb == b.is_vweb
|
||
&& a.is_embed == b.is_embed
|
||
&& a.is_env == b.is_env
|
||
&& a.is_pkgconfig == b.is_pkgconfig;
|
||
}
|
||
|
||
static bool v__ast__ComptimeSelector_struct_eq(v__ast__ComptimeSelector a, v__ast__ComptimeSelector b) {
|
||
return v__ast__Expr_sumtype_eq(a.left, b.left)
|
||
&& v__ast__Expr_sumtype_eq(a.field_expr, b.field_expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.left_type, b.left_type)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.has_parens == b.has_parens;
|
||
}
|
||
|
||
static bool v__ast__ComptimeType_struct_eq(v__ast__ComptimeType a, v__ast__ComptimeType b) {
|
||
return a.kind == b.kind
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__ConcatExpr_struct_eq(v__ast__ConcatExpr a, v__ast__ConcatExpr b) {
|
||
return Array_v__ast__Expr_arr_eq(a.vals, b.vals)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.return_type, b.return_type);
|
||
}
|
||
|
||
static bool v__ast__DumpExpr_struct_eq(v__ast__DumpExpr a, v__ast__DumpExpr b) {
|
||
return v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& string__eq(a.cname, b.cname)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type);
|
||
}
|
||
|
||
static bool v__ast__EnumVal_struct_eq(v__ast__EnumVal a, v__ast__EnumVal b) {
|
||
return string__eq(a.enum_name, b.enum_name)
|
||
&& string__eq(a.val, b.val)
|
||
&& string__eq(a.mod, b.mod)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__ast__GoExpr_struct_eq(v__ast__GoExpr a, v__ast__GoExpr b) {
|
||
return v__ast__CallExpr_struct_eq(a.call_expr, b.call_expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_expr == b.is_expr;
|
||
}
|
||
|
||
static bool v__ast__IfBranch_struct_eq(v__ast__IfBranch a, v__ast__IfBranch b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.body_pos, b.body_pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& v__ast__Expr_sumtype_eq(a.cond, b.cond)
|
||
&& a.pkg_exist == b.pkg_exist
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& a.scope == b.scope;
|
||
}
|
||
|
||
static bool Array_v__ast__IfBranch_arr_eq(Array_v__ast__IfBranch a, Array_v__ast__IfBranch b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__IfBranch_struct_eq(((v__ast__IfBranch*)a.data)[i], ((v__ast__IfBranch*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__IfExpr_struct_eq(v__ast__IfExpr a, v__ast__IfExpr b) {
|
||
return Array_v__ast__Comment_arr_eq(a.post_comments, b.post_comments)
|
||
&& Array_v__ast__IfBranch_arr_eq(a.branches, b.branches)
|
||
&& v__ast__Expr_sumtype_eq(a.left, b.left)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.tok_kind == b.tok_kind
|
||
&& a.is_comptime == b.is_comptime
|
||
&& a.is_expr == b.is_expr
|
||
&& a.has_else == b.has_else;
|
||
}
|
||
|
||
static bool v__ast__IfGuardVar_struct_eq(v__ast__IfGuardVar a, v__ast__IfGuardVar b) {
|
||
return string__eq(a.name, b.name)
|
||
&& a.is_mut == b.is_mut
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool Array_v__ast__IfGuardVar_arr_eq(Array_v__ast__IfGuardVar a, Array_v__ast__IfGuardVar b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__IfGuardVar_struct_eq(((v__ast__IfGuardVar*)a.data)[i], ((v__ast__IfGuardVar*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__IfGuardExpr_struct_eq(v__ast__IfGuardExpr a, v__ast__IfGuardExpr b) {
|
||
return Array_v__ast__IfGuardVar_arr_eq(a.vars, b.vars)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type);
|
||
}
|
||
|
||
static bool v__ast__IndexExpr_struct_eq(v__ast__IndexExpr a, v__ast__IndexExpr b) {
|
||
return v__ast__OrExpr_struct_eq(a.or_expr, b.or_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.index, b.index)
|
||
&& v__ast__Expr_sumtype_eq(a.left, b.left)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.left_type, b.left_type)
|
||
&& a.is_setter == b.is_setter
|
||
&& a.is_map == b.is_map
|
||
&& a.is_array == b.is_array
|
||
&& a.is_farray == b.is_farray
|
||
&& a.is_option == b.is_option
|
||
&& a.is_direct == b.is_direct
|
||
&& a.is_gated == b.is_gated;
|
||
}
|
||
|
||
static bool v__ast__InfixExpr_struct_eq(v__ast__InfixExpr a, v__ast__InfixExpr b) {
|
||
return v__ast__OrExpr_struct_eq(a.or_block, b.or_block)
|
||
&& v__ast__Expr_sumtype_eq(a.left, b.left)
|
||
&& v__ast__Expr_sumtype_eq(a.right, b.right)
|
||
&& string__eq(a.auto_locked, b.auto_locked)
|
||
&& v__ast__ComptTimeConstValue_sumtype_eq(a.ct_left_value, b.ct_left_value)
|
||
&& v__ast__ComptTimeConstValue_sumtype_eq(a.ct_right_value, b.ct_right_value)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.left_type, b.left_type)
|
||
&& v__ast__Type_alias_eq(a.right_type, b.right_type)
|
||
&& a.op == b.op
|
||
&& a.is_stmt == b.is_stmt
|
||
&& a.ct_left_value_evaled == b.ct_left_value_evaled
|
||
&& a.ct_right_value_evaled == b.ct_right_value_evaled;
|
||
}
|
||
|
||
static bool v__ast__IsRefType_struct_eq(v__ast__IsRefType a, v__ast__IsRefType b) {
|
||
return a.is_type == b.is_type
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__ast__Likely_struct_eq(v__ast__Likely a, v__ast__Likely b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_likely == b.is_likely
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr);
|
||
}
|
||
|
||
static bool Array_bool_arr_eq(Array_bool a, Array_bool b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (*((bool*)((byte*)a.data+(i*a.element_size))) != *((bool*)((byte*)b.data+(i*b.element_size)))) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__LockExpr_struct_eq(v__ast__LockExpr a, v__ast__LockExpr b) {
|
||
return Array_bool_arr_eq(a.is_rlock, b.is_rlock)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& Array_v__ast__Expr_arr_eq(a.lockeds, b.lockeds)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& a.is_expr == b.is_expr
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.scope == b.scope;
|
||
}
|
||
|
||
static bool v__ast__MapInit_struct_eq(v__ast__MapInit a, v__ast__MapInit b) {
|
||
return Array_Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.pre_cmnts, b.pre_cmnts)
|
||
&& Array_v__ast__Expr_arr_eq(a.keys, b.keys)
|
||
&& Array_v__ast__Expr_arr_eq(a.vals, b.vals)
|
||
&& Array_v__ast__Type_arr_eq(a.val_types, b.val_types)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.key_type, b.key_type)
|
||
&& v__ast__Type_alias_eq(a.value_type, b.value_type);
|
||
}
|
||
|
||
static bool v__ast__MatchBranch_struct_eq(v__ast__MatchBranch a, v__ast__MatchBranch b) {
|
||
return Array_Array_v__ast__Comment_arr_eq(a.ecmnts, b.ecmnts)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_else == b.is_else
|
||
&& Array_v__ast__Comment_arr_eq(a.post_comments, b.post_comments)
|
||
&& v__token__Pos_struct_eq(a.branch_pos, b.branch_pos)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& Array_v__ast__Expr_arr_eq(a.exprs, b.exprs)
|
||
&& a.scope == b.scope;
|
||
}
|
||
|
||
static bool Array_v__ast__MatchBranch_arr_eq(Array_v__ast__MatchBranch a, Array_v__ast__MatchBranch b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__MatchBranch_struct_eq(((v__ast__MatchBranch*)a.data)[i], ((v__ast__MatchBranch*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__MatchExpr_struct_eq(v__ast__MatchExpr a, v__ast__MatchExpr b) {
|
||
return Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__MatchBranch_arr_eq(a.branches, b.branches)
|
||
&& v__ast__Expr_sumtype_eq(a.cond, b.cond)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.return_type, b.return_type)
|
||
&& v__ast__Type_alias_eq(a.cond_type, b.cond_type)
|
||
&& v__ast__Type_alias_eq(a.expected_type, b.expected_type)
|
||
&& a.tok_kind == b.tok_kind
|
||
&& a.is_expr == b.is_expr
|
||
&& a.is_sum_type == b.is_sum_type;
|
||
}
|
||
|
||
static bool v__ast__NodeError_struct_eq(v__ast__NodeError a, v__ast__NodeError b) {
|
||
return a.idx == b.idx
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__None_struct_eq(v__ast__None a, v__ast__None b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__OffsetOf_struct_eq(v__ast__OffsetOf a, v__ast__OffsetOf b) {
|
||
return string__eq(a.field, b.field)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.struct_type, b.struct_type);
|
||
}
|
||
|
||
static bool v__ast__ParExpr_struct_eq(v__ast__ParExpr a, v__ast__ParExpr b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr);
|
||
}
|
||
|
||
static bool v__ast__PostfixExpr_struct_eq(v__ast__PostfixExpr a, v__ast__PostfixExpr b) {
|
||
return a.op == b.op
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_c2v_prefix == b.is_c2v_prefix
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& string__eq(a.auto_locked, b.auto_locked);
|
||
}
|
||
|
||
static bool v__ast__PrefixExpr_struct_eq(v__ast__PrefixExpr a, v__ast__PrefixExpr b) {
|
||
return v__ast__OrExpr_struct_eq(a.or_block, b.or_block)
|
||
&& v__ast__Expr_sumtype_eq(a.right, b.right)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.right_type, b.right_type)
|
||
&& a.op == b.op
|
||
&& a.is_option == b.is_option;
|
||
}
|
||
|
||
static bool v__ast__RangeExpr_struct_eq(v__ast__RangeExpr a, v__ast__RangeExpr b) {
|
||
return v__ast__Expr_sumtype_eq(a.low, b.low)
|
||
&& v__ast__Expr_sumtype_eq(a.high, b.high)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.has_high == b.has_high
|
||
&& a.has_low == b.has_low
|
||
&& a.is_gated == b.is_gated;
|
||
}
|
||
|
||
static bool v__ast__SelectBranch_struct_eq(v__ast__SelectBranch a, v__ast__SelectBranch b) {
|
||
return v__ast__Comment_struct_eq(a.comment, b.comment)
|
||
&& Array_v__ast__Comment_arr_eq(a.post_comments, b.post_comments)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& v__ast__Stmt_sumtype_eq(a.stmt, b.stmt)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_else == b.is_else
|
||
&& a.is_timeout == b.is_timeout;
|
||
}
|
||
|
||
static bool Array_v__ast__SelectBranch_arr_eq(Array_v__ast__SelectBranch a, Array_v__ast__SelectBranch b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__SelectBranch_struct_eq(((v__ast__SelectBranch*)a.data)[i], ((v__ast__SelectBranch*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__SelectExpr_struct_eq(v__ast__SelectExpr a, v__ast__SelectExpr b) {
|
||
return Array_v__ast__SelectBranch_arr_eq(a.branches, b.branches)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.has_exception == b.has_exception
|
||
&& a.is_expr == b.is_expr
|
||
&& v__ast__Type_alias_eq(a.expected_type, b.expected_type);
|
||
}
|
||
|
||
static bool v__ast__SelectorExpr_struct_eq(v__ast__SelectorExpr a, v__ast__SelectorExpr b) {
|
||
return Array_v__ast__Type_arr_eq(a.from_embed_types, b.from_embed_types)
|
||
&& string__eq(a.field_name, b.field_name)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.mut_pos, b.mut_pos)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.name_type, b.name_type)
|
||
&& a.next_token == b.next_token
|
||
&& a.gkind_field == b.gkind_field
|
||
&& a.is_mut == b.is_mut
|
||
&& a.has_hidden_receiver == b.has_hidden_receiver;
|
||
}
|
||
|
||
static bool v__ast__SizeOf_struct_eq(v__ast__SizeOf a, v__ast__SizeOf b) {
|
||
return a.is_type == b.is_type
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__ast__TypeNode_struct_eq(v__ast__TypeNode a, v__ast__TypeNode b) {
|
||
return v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool Array_v__ast__StructField_arr_eq(Array_v__ast__StructField a, Array_v__ast__StructField b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__StructField_struct_eq(((v__ast__StructField*)a.data)[i], ((v__ast__StructField*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Map_int_v__ast__SqlExpr_map_eq(Map_int_v__ast__SqlExpr a, Map_int_v__ast__SqlExpr b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.key_values.len; ++i) {
|
||
if (!DenseArray_has_index(&a.key_values, i)) continue;
|
||
voidptr k = DenseArray_key(&a.key_values, i);
|
||
if (!map_exists(&b, k)) return false;
|
||
v__ast__SqlExpr v = *(v__ast__SqlExpr*)map_get(&a, k, &(v__ast__SqlExpr[]){ 0 });
|
||
if (!v__ast__SqlExpr_struct_eq(*(v__ast__SqlExpr*)map_get(&b, k, &(v__ast__SqlExpr[]){ 0 }), v)) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__SqlExpr_struct_eq(v__ast__SqlExpr a, v__ast__SqlExpr b) {
|
||
return v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.is_count == b.is_count
|
||
&& a.has_where == b.has_where
|
||
&& a.has_order == b.has_order
|
||
&& a.has_limit == b.has_limit
|
||
&& a.has_offset == b.has_offset
|
||
&& a.has_desc == b.has_desc
|
||
&& a.is_array == b.is_array
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.db_expr, b.db_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.where_expr, b.where_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.order_expr, b.order_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.limit_expr, b.limit_expr)
|
||
&& v__ast__Expr_sumtype_eq(a.offset_expr, b.offset_expr)
|
||
&& v__ast__TypeNode_struct_eq(a.table_expr, b.table_expr)
|
||
&& Array_v__ast__StructField_arr_eq(a.fields, b.fields)
|
||
&& Map_int_v__ast__SqlExpr_map_eq(a.sub_structs, b.sub_structs);
|
||
}
|
||
|
||
static bool Array_int_arr_eq(Array_int a, Array_int b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (*((int*)((byte*)a.data+(i*a.element_size))) != *((int*)((byte*)b.data+(i*b.element_size)))) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool Array_v__token__Pos_arr_eq(Array_v__token__Pos a, Array_v__token__Pos b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__token__Pos_struct_eq(((v__token__Pos*)a.data)[i], ((v__token__Pos*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__StringInterLiteral_struct_eq(v__ast__StringInterLiteral a, v__ast__StringInterLiteral b) {
|
||
return Array_string_arr_eq(a.vals, b.vals)
|
||
&& Array_int_arr_eq(a.fwidths, b.fwidths)
|
||
&& Array_int_arr_eq(a.precisions, b.precisions)
|
||
&& Array_bool_arr_eq(a.pluss, b.pluss)
|
||
&& Array_bool_arr_eq(a.fills, b.fills)
|
||
&& Array_v__token__Pos_arr_eq(a.fmt_poss, b.fmt_poss)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Expr_arr_eq(a.exprs, b.exprs)
|
||
&& Array_v__ast__Type_arr_eq(a.expr_types, b.expr_types)
|
||
&& Array_u8_arr_eq(a.fmts, b.fmts)
|
||
&& Array_bool_arr_eq(a.need_fmts, b.need_fmts);
|
||
}
|
||
|
||
static bool v__ast__StringLiteral_struct_eq(v__ast__StringLiteral a, v__ast__StringLiteral b) {
|
||
return string__eq(a.val, b.val)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.language == b.language
|
||
&& a.is_raw == b.is_raw;
|
||
}
|
||
|
||
static bool v__ast__StructInitField_struct_eq(v__ast__StructInitField a, v__ast__StructInitField b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.name_pos, b.name_pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.next_comments, b.next_comments)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.expected_type, b.expected_type)
|
||
&& v__ast__Type_alias_eq(a.parent_type, b.parent_type);
|
||
}
|
||
|
||
static bool Array_v__ast__StructInitField_arr_eq(Array_v__ast__StructInitField a, Array_v__ast__StructInitField b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__StructInitField_struct_eq(((v__ast__StructInitField*)a.data)[i], ((v__ast__StructInitField*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__StructInitEmbed_struct_eq(v__ast__StructInitEmbed a, v__ast__StructInitEmbed b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.next_comments, b.next_comments)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.expected_type, b.expected_type);
|
||
}
|
||
|
||
static bool Array_v__ast__StructInitEmbed_arr_eq(Array_v__ast__StructInitEmbed a, Array_v__ast__StructInitEmbed b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__StructInitEmbed_struct_eq(((v__ast__StructInitEmbed*)a.data)[i], ((v__ast__StructInitEmbed*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__StructInit_struct_eq(v__ast__StructInit a, v__ast__StructInit b) {
|
||
return Array_v__ast__Comment_arr_eq(a.pre_comments, b.pre_comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.update_expr_comments, b.update_expr_comments)
|
||
&& Array_v__ast__StructInitField_arr_eq(a.fields, b.fields)
|
||
&& Array_v__ast__StructInitEmbed_arr_eq(a.embeds, b.embeds)
|
||
&& Array_v__ast__Type_arr_eq(a.generic_types, b.generic_types)
|
||
&& string__eq(a.typ_str, b.typ_str)
|
||
&& v__ast__Expr_sumtype_eq(a.update_expr, b.update_expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.name_pos, b.name_pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__ast__Type_alias_eq(a.update_expr_type, b.update_expr_type)
|
||
&& a.is_short == b.is_short
|
||
&& a.is_short_syntax == b.is_short_syntax
|
||
&& a.unresolved == b.unresolved
|
||
&& a.is_update_embed == b.is_update_embed
|
||
&& a.has_update_expr == b.has_update_expr;
|
||
}
|
||
|
||
static bool v__ast__TypeOf_struct_eq(v__ast__TypeOf a, v__ast__TypeOf b) {
|
||
return v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.expr_type, b.expr_type);
|
||
}
|
||
|
||
static bool v__ast__UnsafeExpr_struct_eq(v__ast__UnsafeExpr a, v__ast__UnsafeExpr b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr);
|
||
}
|
||
|
||
static bool v__ast__Expr_sumtype_eq(v__ast__Expr a, v__ast__Expr b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 248) {
|
||
return v__ast__AnonFn_struct_eq(*a._v__ast__AnonFn, *b._v__ast__AnonFn);
|
||
}
|
||
if (a._typ == 249) {
|
||
return v__ast__ArrayDecompose_struct_eq(*a._v__ast__ArrayDecompose, *b._v__ast__ArrayDecompose);
|
||
}
|
||
if (a._typ == 250) {
|
||
return v__ast__ArrayInit_struct_eq(*a._v__ast__ArrayInit, *b._v__ast__ArrayInit);
|
||
}
|
||
if (a._typ == 251) {
|
||
return v__ast__AsCast_struct_eq(*a._v__ast__AsCast, *b._v__ast__AsCast);
|
||
}
|
||
if (a._typ == 252) {
|
||
return v__ast__Assoc_struct_eq(*a._v__ast__Assoc, *b._v__ast__Assoc);
|
||
}
|
||
if (a._typ == 253) {
|
||
return v__ast__AtExpr_struct_eq(*a._v__ast__AtExpr, *b._v__ast__AtExpr);
|
||
}
|
||
if (a._typ == 254) {
|
||
return v__ast__BoolLiteral_struct_eq(*a._v__ast__BoolLiteral, *b._v__ast__BoolLiteral);
|
||
}
|
||
if (a._typ == 255) {
|
||
return v__ast__CTempVar_struct_eq(*a._v__ast__CTempVar, *b._v__ast__CTempVar);
|
||
}
|
||
if (a._typ == 256) {
|
||
return v__ast__CallExpr_struct_eq(*a._v__ast__CallExpr, *b._v__ast__CallExpr);
|
||
}
|
||
if (a._typ == 257) {
|
||
return v__ast__CastExpr_struct_eq(*a._v__ast__CastExpr, *b._v__ast__CastExpr);
|
||
}
|
||
if (a._typ == 258) {
|
||
return v__ast__ChanInit_struct_eq(*a._v__ast__ChanInit, *b._v__ast__ChanInit);
|
||
}
|
||
if (a._typ == 259) {
|
||
return v__ast__CharLiteral_struct_eq(*a._v__ast__CharLiteral, *b._v__ast__CharLiteral);
|
||
}
|
||
if (a._typ == 260) {
|
||
return v__ast__Comment_struct_eq(*a._v__ast__Comment, *b._v__ast__Comment);
|
||
}
|
||
if (a._typ == 261) {
|
||
return v__ast__ComptimeCall_struct_eq(*a._v__ast__ComptimeCall, *b._v__ast__ComptimeCall);
|
||
}
|
||
if (a._typ == 262) {
|
||
return v__ast__ComptimeSelector_struct_eq(*a._v__ast__ComptimeSelector, *b._v__ast__ComptimeSelector);
|
||
}
|
||
if (a._typ == 263) {
|
||
return v__ast__ComptimeType_struct_eq(*a._v__ast__ComptimeType, *b._v__ast__ComptimeType);
|
||
}
|
||
if (a._typ == 264) {
|
||
return v__ast__ConcatExpr_struct_eq(*a._v__ast__ConcatExpr, *b._v__ast__ConcatExpr);
|
||
}
|
||
if (a._typ == 265) {
|
||
return v__ast__DumpExpr_struct_eq(*a._v__ast__DumpExpr, *b._v__ast__DumpExpr);
|
||
}
|
||
if (a._typ == 266) {
|
||
return v__ast__EmptyExpr_struct_eq(*a._v__ast__EmptyExpr, *b._v__ast__EmptyExpr);
|
||
}
|
||
if (a._typ == 267) {
|
||
return v__ast__EnumVal_struct_eq(*a._v__ast__EnumVal, *b._v__ast__EnumVal);
|
||
}
|
||
if (a._typ == 268) {
|
||
return v__ast__FloatLiteral_struct_eq(*a._v__ast__FloatLiteral, *b._v__ast__FloatLiteral);
|
||
}
|
||
if (a._typ == 269) {
|
||
return v__ast__GoExpr_struct_eq(*a._v__ast__GoExpr, *b._v__ast__GoExpr);
|
||
}
|
||
if (a._typ == 270) {
|
||
return v__ast__Ident_struct_eq(*a._v__ast__Ident, *b._v__ast__Ident);
|
||
}
|
||
if (a._typ == 271) {
|
||
return v__ast__IfExpr_struct_eq(*a._v__ast__IfExpr, *b._v__ast__IfExpr);
|
||
}
|
||
if (a._typ == 272) {
|
||
return v__ast__IfGuardExpr_struct_eq(*a._v__ast__IfGuardExpr, *b._v__ast__IfGuardExpr);
|
||
}
|
||
if (a._typ == 273) {
|
||
return v__ast__IndexExpr_struct_eq(*a._v__ast__IndexExpr, *b._v__ast__IndexExpr);
|
||
}
|
||
if (a._typ == 274) {
|
||
return v__ast__InfixExpr_struct_eq(*a._v__ast__InfixExpr, *b._v__ast__InfixExpr);
|
||
}
|
||
if (a._typ == 275) {
|
||
return v__ast__IntegerLiteral_struct_eq(*a._v__ast__IntegerLiteral, *b._v__ast__IntegerLiteral);
|
||
}
|
||
if (a._typ == 276) {
|
||
return v__ast__IsRefType_struct_eq(*a._v__ast__IsRefType, *b._v__ast__IsRefType);
|
||
}
|
||
if (a._typ == 277) {
|
||
return v__ast__Likely_struct_eq(*a._v__ast__Likely, *b._v__ast__Likely);
|
||
}
|
||
if (a._typ == 278) {
|
||
return v__ast__LockExpr_struct_eq(*a._v__ast__LockExpr, *b._v__ast__LockExpr);
|
||
}
|
||
if (a._typ == 279) {
|
||
return v__ast__MapInit_struct_eq(*a._v__ast__MapInit, *b._v__ast__MapInit);
|
||
}
|
||
if (a._typ == 280) {
|
||
return v__ast__MatchExpr_struct_eq(*a._v__ast__MatchExpr, *b._v__ast__MatchExpr);
|
||
}
|
||
if (a._typ == 281) {
|
||
return v__ast__NodeError_struct_eq(*a._v__ast__NodeError, *b._v__ast__NodeError);
|
||
}
|
||
if (a._typ == 282) {
|
||
return v__ast__None_struct_eq(*a._v__ast__None, *b._v__ast__None);
|
||
}
|
||
if (a._typ == 283) {
|
||
return v__ast__OffsetOf_struct_eq(*a._v__ast__OffsetOf, *b._v__ast__OffsetOf);
|
||
}
|
||
if (a._typ == 284) {
|
||
return v__ast__OrExpr_struct_eq(*a._v__ast__OrExpr, *b._v__ast__OrExpr);
|
||
}
|
||
if (a._typ == 285) {
|
||
return v__ast__ParExpr_struct_eq(*a._v__ast__ParExpr, *b._v__ast__ParExpr);
|
||
}
|
||
if (a._typ == 286) {
|
||
return v__ast__PostfixExpr_struct_eq(*a._v__ast__PostfixExpr, *b._v__ast__PostfixExpr);
|
||
}
|
||
if (a._typ == 287) {
|
||
return v__ast__PrefixExpr_struct_eq(*a._v__ast__PrefixExpr, *b._v__ast__PrefixExpr);
|
||
}
|
||
if (a._typ == 288) {
|
||
return v__ast__RangeExpr_struct_eq(*a._v__ast__RangeExpr, *b._v__ast__RangeExpr);
|
||
}
|
||
if (a._typ == 289) {
|
||
return v__ast__SelectExpr_struct_eq(*a._v__ast__SelectExpr, *b._v__ast__SelectExpr);
|
||
}
|
||
if (a._typ == 290) {
|
||
return v__ast__SelectorExpr_struct_eq(*a._v__ast__SelectorExpr, *b._v__ast__SelectorExpr);
|
||
}
|
||
if (a._typ == 291) {
|
||
return v__ast__SizeOf_struct_eq(*a._v__ast__SizeOf, *b._v__ast__SizeOf);
|
||
}
|
||
if (a._typ == 292) {
|
||
return v__ast__SqlExpr_struct_eq(*a._v__ast__SqlExpr, *b._v__ast__SqlExpr);
|
||
}
|
||
if (a._typ == 293) {
|
||
return v__ast__StringInterLiteral_struct_eq(*a._v__ast__StringInterLiteral, *b._v__ast__StringInterLiteral);
|
||
}
|
||
if (a._typ == 294) {
|
||
return v__ast__StringLiteral_struct_eq(*a._v__ast__StringLiteral, *b._v__ast__StringLiteral);
|
||
}
|
||
if (a._typ == 295) {
|
||
return v__ast__StructInit_struct_eq(*a._v__ast__StructInit, *b._v__ast__StructInit);
|
||
}
|
||
if (a._typ == 296) {
|
||
return v__ast__TypeNode_struct_eq(*a._v__ast__TypeNode, *b._v__ast__TypeNode);
|
||
}
|
||
if (a._typ == 297) {
|
||
return v__ast__TypeOf_struct_eq(*a._v__ast__TypeOf, *b._v__ast__TypeOf);
|
||
}
|
||
if (a._typ == 298) {
|
||
return v__ast__UnsafeExpr_struct_eq(*a._v__ast__UnsafeExpr, *b._v__ast__UnsafeExpr);
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool v__ast__AsmIO_struct_eq(v__ast__AsmIO a, v__ast__AsmIO b) {
|
||
return string__eq(a.alias, b.alias)
|
||
&& string__eq(a.constraint, b.constraint)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool Array_v__ast__AsmIO_arr_eq(Array_v__ast__AsmIO a, Array_v__ast__AsmIO b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__AsmIO_struct_eq(((v__ast__AsmIO*)a.data)[i], ((v__ast__AsmIO*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__AsmStmt_struct_eq(v__ast__AsmStmt a, v__ast__AsmStmt b) {
|
||
return Array_v__ast__AsmClobbered_arr_eq(a.clobbered, b.clobbered)
|
||
&& Array_v__ast__AsmTemplate_arr_eq(a.templates, b.templates)
|
||
&& Array_v__ast__AsmIO_arr_eq(a.output, b.output)
|
||
&& Array_v__ast__AsmIO_arr_eq(a.input, b.input)
|
||
&& Array_string_arr_eq(a.global_labels, b.global_labels)
|
||
&& Array_string_arr_eq(a.local_labels, b.local_labels)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.arch == b.arch
|
||
&& a.is_basic == b.is_basic
|
||
&& a.is_volatile == b.is_volatile
|
||
&& a.is_goto == b.is_goto;
|
||
}
|
||
|
||
static bool v__ast__AssertStmt_struct_eq(v__ast__AssertStmt a, v__ast__AssertStmt b) {
|
||
return v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_used == b.is_used;
|
||
}
|
||
|
||
static bool v__ast__AssignStmt_struct_eq(v__ast__AssignStmt a, v__ast__AssignStmt b) {
|
||
return Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.end_comments, b.end_comments)
|
||
&& Array_v__ast__Expr_arr_eq(a.right, b.right)
|
||
&& Array_v__ast__Expr_arr_eq(a.left, b.left)
|
||
&& Array_v__ast__Type_arr_eq(a.left_types, b.left_types)
|
||
&& Array_v__ast__Type_arr_eq(a.right_types, b.right_types)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.op == b.op
|
||
&& a.is_static == b.is_static
|
||
&& a.is_volatile == b.is_volatile
|
||
&& a.is_simple == b.is_simple
|
||
&& a.has_cross_var == b.has_cross_var;
|
||
}
|
||
|
||
static bool v__ast__Block_struct_eq(v__ast__Block a, v__ast__Block b) {
|
||
return Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& a.is_unsafe == b.is_unsafe
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__BranchStmt_struct_eq(v__ast__BranchStmt a, v__ast__BranchStmt b) {
|
||
return string__eq(a.label, b.label)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.kind == b.kind;
|
||
}
|
||
|
||
static bool v__ast__ComptimeFor_struct_eq(v__ast__ComptimeFor a, v__ast__ComptimeFor b) {
|
||
return string__eq(a.val_var, b.val_var)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& a.kind == b.kind
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.typ_pos, b.typ_pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool Array_v__ast__ConstField_arr_eq(Array_v__ast__ConstField a, Array_v__ast__ConstField b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__ConstField_struct_eq(((v__ast__ConstField*)a.data)[i], ((v__ast__ConstField*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__ConstDecl_struct_eq(v__ast__ConstDecl a, v__ast__ConstDecl b) {
|
||
return Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& Array_v__ast__ConstField_arr_eq(a.fields, b.fields)
|
||
&& Array_v__ast__Comment_arr_eq(a.end_comments, b.end_comments)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_pub == b.is_pub
|
||
&& a.is_block == b.is_block;
|
||
}
|
||
|
||
static bool v__ast__EmptyStmt_struct_eq(v__ast__EmptyStmt a, v__ast__EmptyStmt b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__EnumField_struct_eq(v__ast__EnumField a, v__ast__EnumField b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Comment_arr_eq(a.next_comments, b.next_comments)
|
||
&& a.has_expr == b.has_expr
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr);
|
||
}
|
||
|
||
static bool Array_v__ast__EnumField_arr_eq(Array_v__ast__EnumField a, Array_v__ast__EnumField b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__EnumField_struct_eq(((v__ast__EnumField*)a.data)[i], ((v__ast__EnumField*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__EnumDecl_struct_eq(v__ast__EnumDecl a, v__ast__EnumDecl b) {
|
||
return Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__EnumField_arr_eq(a.fields, b.fields)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_pub == b.is_pub
|
||
&& a.is_flag == b.is_flag
|
||
&& a.is_multi_allowed == b.is_multi_allowed;
|
||
}
|
||
|
||
static bool v__ast__ExprStmt_struct_eq(v__ast__ExprStmt a, v__ast__ExprStmt b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& v__ast__Expr_sumtype_eq(a.expr, b.expr)
|
||
&& a.is_expr == b.is_expr
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__ast__ForCStmt_struct_eq(v__ast__ForCStmt a, v__ast__ForCStmt b) {
|
||
return a.has_init == b.has_init
|
||
&& a.has_cond == b.has_cond
|
||
&& a.has_inc == b.has_inc
|
||
&& a.is_multi == b.is_multi
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Stmt_sumtype_eq(a.init, b.init)
|
||
&& v__ast__Expr_sumtype_eq(a.cond, b.cond)
|
||
&& v__ast__Stmt_sumtype_eq(a.inc, b.inc)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& string__eq(a.label, b.label)
|
||
&& a.scope == b.scope;
|
||
}
|
||
|
||
static bool v__ast__ForInStmt_struct_eq(v__ast__ForInStmt a, v__ast__ForInStmt b) {
|
||
return Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& string__eq(a.key_var, b.key_var)
|
||
&& string__eq(a.val_var, b.val_var)
|
||
&& v__ast__Expr_sumtype_eq(a.high, b.high)
|
||
&& v__ast__Expr_sumtype_eq(a.cond, b.cond)
|
||
&& string__eq(a.label, b.label)
|
||
&& a.scope == b.scope
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.key_type, b.key_type)
|
||
&& v__ast__Type_alias_eq(a.val_type, b.val_type)
|
||
&& v__ast__Type_alias_eq(a.cond_type, b.cond_type)
|
||
&& v__ast__Type_alias_eq(a.high_type, b.high_type)
|
||
&& a.kind == b.kind
|
||
&& a.is_range == b.is_range
|
||
&& a.val_is_mut == b.val_is_mut;
|
||
}
|
||
|
||
static bool v__ast__ForStmt_struct_eq(v__ast__ForStmt a, v__ast__ForStmt b) {
|
||
return a.is_inf == b.is_inf
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.cond, b.cond)
|
||
&& Array_v__ast__Stmt_arr_eq(a.stmts, b.stmts)
|
||
&& string__eq(a.label, b.label)
|
||
&& a.scope == b.scope;
|
||
}
|
||
|
||
static bool Array_v__ast__GlobalField_arr_eq(Array_v__ast__GlobalField a, Array_v__ast__GlobalField b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__GlobalField_struct_eq(((v__ast__GlobalField*)a.data)[i], ((v__ast__GlobalField*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__GlobalDecl_struct_eq(v__ast__GlobalDecl a, v__ast__GlobalDecl b) {
|
||
return string__eq(a.mod, b.mod)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.is_block == b.is_block
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& Array_v__ast__GlobalField_arr_eq(a.fields, b.fields)
|
||
&& Array_v__ast__Comment_arr_eq(a.end_comments, b.end_comments);
|
||
}
|
||
|
||
static bool v__ast__GotoLabel_struct_eq(v__ast__GotoLabel a, v__ast__GotoLabel b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__GotoStmt_struct_eq(v__ast__GotoStmt a, v__ast__GotoStmt b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos);
|
||
}
|
||
|
||
static bool v__ast__HashStmt_struct_eq(v__ast__HashStmt a, v__ast__HashStmt b) {
|
||
return string__eq(a.mod, b.mod)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& string__eq(a.source_file, b.source_file)
|
||
&& string__eq(a.val, b.val)
|
||
&& string__eq(a.kind, b.kind)
|
||
&& string__eq(a.main, b.main)
|
||
&& string__eq(a.msg, b.msg)
|
||
&& Array_v__ast__Expr_arr_eq(a.ct_conds, b.ct_conds);
|
||
}
|
||
|
||
static bool Array_v__ast__FnDecl_arr_eq(Array_v__ast__FnDecl a, Array_v__ast__FnDecl b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__FnDecl_struct_eq(((v__ast__FnDecl*)a.data)[i], ((v__ast__FnDecl*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__InterfaceEmbedding_struct_eq(v__ast__InterfaceEmbedding a, v__ast__InterfaceEmbedding b) {
|
||
return string__eq(a.name, b.name)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments);
|
||
}
|
||
|
||
static bool Array_v__ast__InterfaceEmbedding_arr_eq(Array_v__ast__InterfaceEmbedding a, Array_v__ast__InterfaceEmbedding b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__InterfaceEmbedding_struct_eq(((v__ast__InterfaceEmbedding*)a.data)[i], ((v__ast__InterfaceEmbedding*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__InterfaceDecl_struct_eq(v__ast__InterfaceDecl a, v__ast__InterfaceDecl b) {
|
||
return Array_string_arr_eq(a.field_names, b.field_names)
|
||
&& Array_v__ast__Comment_arr_eq(a.pre_comments, b.pre_comments)
|
||
&& Array_v__ast__Type_arr_eq(a.generic_types, b.generic_types)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& Array_v__ast__FnDecl_arr_eq(a.methods, b.methods)
|
||
&& Array_v__ast__StructField_arr_eq(a.fields, b.fields)
|
||
&& Array_v__ast__InterfaceEmbedding_arr_eq(a.embeds, b.embeds)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.name_pos, b.name_pos)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& a.mut_pos == b.mut_pos
|
||
&& a.language == b.language
|
||
&& a.is_pub == b.is_pub
|
||
&& a.are_embeds_expanded == b.are_embeds_expanded;
|
||
}
|
||
|
||
static bool v__ast__Return_struct_eq(v__ast__Return a, v__ast__Return b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Expr_arr_eq(a.exprs, b.exprs)
|
||
&& Array_v__ast__Type_arr_eq(a.types, b.types);
|
||
}
|
||
|
||
static bool Map_int_v__ast__SqlStmtLine_map_eq(Map_int_v__ast__SqlStmtLine a, Map_int_v__ast__SqlStmtLine b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.key_values.len; ++i) {
|
||
if (!DenseArray_has_index(&a.key_values, i)) continue;
|
||
voidptr k = DenseArray_key(&a.key_values, i);
|
||
if (!map_exists(&b, k)) return false;
|
||
v__ast__SqlStmtLine v = *(v__ast__SqlStmtLine*)map_get(&a, k, &(v__ast__SqlStmtLine[]){ 0 });
|
||
if (!v__ast__SqlStmtLine_struct_eq(*(v__ast__SqlStmtLine*)map_get(&b, k, &(v__ast__SqlStmtLine[]){ 0 }), v)) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__SqlStmtLine_struct_eq(v__ast__SqlStmtLine a, v__ast__SqlStmtLine b) {
|
||
return a.kind == b.kind
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.where_expr, b.where_expr)
|
||
&& Array_v__ast__Expr_arr_eq(a.update_exprs, b.update_exprs)
|
||
&& string__eq(a.object_var_name, b.object_var_name)
|
||
&& Array_string_arr_eq(a.updated_columns, b.updated_columns)
|
||
&& v__ast__TypeNode_struct_eq(a.table_expr, b.table_expr)
|
||
&& Array_v__ast__StructField_arr_eq(a.fields, b.fields)
|
||
&& Map_int_v__ast__SqlStmtLine_map_eq(a.sub_structs, b.sub_structs);
|
||
}
|
||
|
||
static bool Array_v__ast__SqlStmtLine_arr_eq(Array_v__ast__SqlStmtLine a, Array_v__ast__SqlStmtLine b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__SqlStmtLine_struct_eq(((v__ast__SqlStmtLine*)a.data)[i], ((v__ast__SqlStmtLine*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__SqlStmt_struct_eq(v__ast__SqlStmt a, v__ast__SqlStmt b) {
|
||
return v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__ast__Expr_sumtype_eq(a.db_expr, b.db_expr)
|
||
&& Array_v__ast__SqlStmtLine_arr_eq(a.lines, b.lines);
|
||
}
|
||
|
||
static bool v__ast__Embed_struct_eq(v__ast__Embed a, v__ast__Embed b) {
|
||
return v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments);
|
||
}
|
||
|
||
static bool Array_v__ast__Embed_arr_eq(Array_v__ast__Embed a, Array_v__ast__Embed b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__Embed_struct_eq(((v__ast__Embed*)a.data)[i], ((v__ast__Embed*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__StructDecl_struct_eq(v__ast__StructDecl a, v__ast__StructDecl b) {
|
||
return Array_v__ast__Type_arr_eq(a.generic_types, b.generic_types)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& Array_v__ast__Comment_arr_eq(a.end_comments, b.end_comments)
|
||
&& Array_v__ast__Embed_arr_eq(a.embeds, b.embeds)
|
||
&& Array_v__ast__StructField_arr_eq(a.fields, b.fields)
|
||
&& string__eq(a.name, b.name)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& a.mut_pos == b.mut_pos
|
||
&& a.pub_pos == b.pub_pos
|
||
&& a.pub_mut_pos == b.pub_mut_pos
|
||
&& a.global_pos == b.global_pos
|
||
&& a.module_pos == b.module_pos
|
||
&& a.language == b.language
|
||
&& a.is_pub == b.is_pub
|
||
&& a.is_union == b.is_union;
|
||
}
|
||
|
||
static bool v__ast__AliasTypeDecl_struct_eq(v__ast__AliasTypeDecl a, v__ast__AliasTypeDecl b) {
|
||
return string__eq(a.name, b.name)
|
||
&& a.is_pub == b.is_pub
|
||
&& v__ast__Type_alias_eq(a.parent_type, b.parent_type)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.type_pos, b.type_pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments);
|
||
}
|
||
|
||
static bool v__ast__FnTypeDecl_struct_eq(v__ast__FnTypeDecl a, v__ast__FnTypeDecl b) {
|
||
return string__eq(a.name, b.name)
|
||
&& a.is_pub == b.is_pub
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.type_pos, b.type_pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs);
|
||
}
|
||
|
||
static bool Array_v__ast__TypeNode_arr_eq(Array_v__ast__TypeNode a, Array_v__ast__TypeNode b) {
|
||
if (a.len != b.len) {
|
||
return false;
|
||
}
|
||
for (int i = 0; i < a.len; ++i) {
|
||
if (!v__ast__TypeNode_struct_eq(((v__ast__TypeNode*)a.data)[i], ((v__ast__TypeNode*)b.data)[i])) {
|
||
return false;
|
||
}
|
||
}
|
||
return true;
|
||
}
|
||
|
||
static bool v__ast__SumTypeDecl_struct_eq(v__ast__SumTypeDecl a, v__ast__SumTypeDecl b) {
|
||
return string__eq(a.name, b.name)
|
||
&& a.is_pub == b.is_pub
|
||
&& v__token__Pos_struct_eq(a.pos, b.pos)
|
||
&& v__token__Pos_struct_eq(a.name_pos, b.name_pos)
|
||
&& Array_v__ast__Comment_arr_eq(a.comments, b.comments)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ)
|
||
&& Array_v__ast__Type_arr_eq(a.generic_types, b.generic_types)
|
||
&& Array_v__ast__Attr_arr_eq(a.attrs, b.attrs)
|
||
&& Array_v__ast__TypeNode_arr_eq(a.variants, b.variants);
|
||
}
|
||
|
||
static bool v__ast__TypeDecl_sumtype_eq(v__ast__TypeDecl a, v__ast__TypeDecl b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 244) {
|
||
return v__ast__AliasTypeDecl_struct_eq(*a._v__ast__AliasTypeDecl, *b._v__ast__AliasTypeDecl);
|
||
}
|
||
if (a._typ == 245) {
|
||
return v__ast__FnTypeDecl_struct_eq(*a._v__ast__FnTypeDecl, *b._v__ast__FnTypeDecl);
|
||
}
|
||
if (a._typ == 246) {
|
||
return v__ast__SumTypeDecl_struct_eq(*a._v__ast__SumTypeDecl, *b._v__ast__SumTypeDecl);
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool v__ast__Stmt_sumtype_eq(v__ast__Stmt a, v__ast__Stmt b) {
|
||
if (a._typ != b._typ) { return false; }
|
||
if (a._typ == 300) {
|
||
return v__ast__AsmStmt_struct_eq(*a._v__ast__AsmStmt, *b._v__ast__AsmStmt);
|
||
}
|
||
if (a._typ == 301) {
|
||
return v__ast__AssertStmt_struct_eq(*a._v__ast__AssertStmt, *b._v__ast__AssertStmt);
|
||
}
|
||
if (a._typ == 302) {
|
||
return v__ast__AssignStmt_struct_eq(*a._v__ast__AssignStmt, *b._v__ast__AssignStmt);
|
||
}
|
||
if (a._typ == 303) {
|
||
return v__ast__Block_struct_eq(*a._v__ast__Block, *b._v__ast__Block);
|
||
}
|
||
if (a._typ == 304) {
|
||
return v__ast__BranchStmt_struct_eq(*a._v__ast__BranchStmt, *b._v__ast__BranchStmt);
|
||
}
|
||
if (a._typ == 305) {
|
||
return v__ast__ComptimeFor_struct_eq(*a._v__ast__ComptimeFor, *b._v__ast__ComptimeFor);
|
||
}
|
||
if (a._typ == 306) {
|
||
return v__ast__ConstDecl_struct_eq(*a._v__ast__ConstDecl, *b._v__ast__ConstDecl);
|
||
}
|
||
if (a._typ == 307) {
|
||
return v__ast__DeferStmt_struct_eq(*a._v__ast__DeferStmt, *b._v__ast__DeferStmt);
|
||
}
|
||
if (a._typ == 308) {
|
||
return v__ast__EmptyStmt_struct_eq(*a._v__ast__EmptyStmt, *b._v__ast__EmptyStmt);
|
||
}
|
||
if (a._typ == 309) {
|
||
return v__ast__EnumDecl_struct_eq(*a._v__ast__EnumDecl, *b._v__ast__EnumDecl);
|
||
}
|
||
if (a._typ == 310) {
|
||
return v__ast__ExprStmt_struct_eq(*a._v__ast__ExprStmt, *b._v__ast__ExprStmt);
|
||
}
|
||
if (a._typ == 185) {
|
||
return v__ast__FnDecl_struct_eq(*a._v__ast__FnDecl, *b._v__ast__FnDecl);
|
||
}
|
||
if (a._typ == 311) {
|
||
return v__ast__ForCStmt_struct_eq(*a._v__ast__ForCStmt, *b._v__ast__ForCStmt);
|
||
}
|
||
if (a._typ == 312) {
|
||
return v__ast__ForInStmt_struct_eq(*a._v__ast__ForInStmt, *b._v__ast__ForInStmt);
|
||
}
|
||
if (a._typ == 313) {
|
||
return v__ast__ForStmt_struct_eq(*a._v__ast__ForStmt, *b._v__ast__ForStmt);
|
||
}
|
||
if (a._typ == 314) {
|
||
return v__ast__GlobalDecl_struct_eq(*a._v__ast__GlobalDecl, *b._v__ast__GlobalDecl);
|
||
}
|
||
if (a._typ == 315) {
|
||
return v__ast__GotoLabel_struct_eq(*a._v__ast__GotoLabel, *b._v__ast__GotoLabel);
|
||
}
|
||
if (a._typ == 316) {
|
||
return v__ast__GotoStmt_struct_eq(*a._v__ast__GotoStmt, *b._v__ast__GotoStmt);
|
||
}
|
||
if (a._typ == 317) {
|
||
return v__ast__HashStmt_struct_eq(*a._v__ast__HashStmt, *b._v__ast__HashStmt);
|
||
}
|
||
if (a._typ == 318) {
|
||
return v__ast__Import_struct_eq(*a._v__ast__Import, *b._v__ast__Import);
|
||
}
|
||
if (a._typ == 319) {
|
||
return v__ast__InterfaceDecl_struct_eq(*a._v__ast__InterfaceDecl, *b._v__ast__InterfaceDecl);
|
||
}
|
||
if (a._typ == 320) {
|
||
return v__ast__Module_struct_eq(*a._v__ast__Module, *b._v__ast__Module);
|
||
}
|
||
if (a._typ == 281) {
|
||
return v__ast__NodeError_struct_eq(*a._v__ast__NodeError, *b._v__ast__NodeError);
|
||
}
|
||
if (a._typ == 321) {
|
||
return v__ast__Return_struct_eq(*a._v__ast__Return, *b._v__ast__Return);
|
||
}
|
||
if (a._typ == 322) {
|
||
return v__ast__SqlStmt_struct_eq(*a._v__ast__SqlStmt, *b._v__ast__SqlStmt);
|
||
}
|
||
if (a._typ == 323) {
|
||
return v__ast__StructDecl_struct_eq(*a._v__ast__StructDecl, *b._v__ast__StructDecl);
|
||
}
|
||
if (a._typ == 247) {
|
||
return v__ast__TypeDecl_sumtype_eq(*a._v__ast__TypeDecl, *b._v__ast__TypeDecl);
|
||
}
|
||
return false;
|
||
}
|
||
|
||
static bool v__gen__c__StrType_struct_eq(v__gen__c__StrType a, v__gen__c__StrType b) {
|
||
return string__eq(a.styp, b.styp)
|
||
&& v__ast__Type_alias_eq(a.typ, b.typ);
|
||
}
|
||
|
||
static bool v__gen__c__SumtypeCastingFn_struct_eq(v__gen__c__SumtypeCastingFn a, v__gen__c__SumtypeCastingFn b) {
|
||
return string__eq(a.fn_name, b.fn_name)
|
||
&& v__ast__Type_alias_eq(a.got, b.got)
|
||
&& v__ast__Type_alias_eq(a.exp, b.exp);
|
||
}
|
||
|
||
void v__ast__Param_free(v__ast__Param* it) {
|
||
string_free(&(it->name));
|
||
v__token__Pos_free(&(it->pos));
|
||
v__token__Pos_free(&(it->type_pos));
|
||
}
|
||
|
||
void Array_v__ast__Param_free(Array_v__ast__Param* it) {
|
||
for (int i = 0; i < it->len; i++) {
|
||
v__ast__Param_free(&(((v__ast__Param*)it->data)[i]));
|
||
}
|
||
array_free(it);
|
||
}
|
||
|
||
void v__ast__Attr_free(v__ast__Attr* it) {
|
||
string_free(&(it->name));
|
||
string_free(&(it->arg));
|
||
v__token__Pos_free(&(it->pos));
|
||
}
|
||
|
||
void Array_v__ast__Attr_free(Array_v__ast__Attr* it) {
|
||
for (int i = 0; i < it->len; i++) {
|
||
v__ast__Attr_free(&(((v__ast__Attr*)it->data)[i]));
|
||
}
|
||
array_free(it);
|
||
}
|
||
|
||
void v__ast__Fn_free(v__ast__Fn* it) {
|
||
Array_v__ast__Param_free(&(it->params));
|
||
Array_string_free(&(it->generic_names));
|
||
Array_string_free(&(it->dep_names));
|
||
Array_v__ast__Attr_free(&(it->attrs));
|
||
string_free(&(it->mod));
|
||
string_free(&(it->file));
|
||
string_free(&(it->name));
|
||
v__token__Pos_free(&(it->pos));
|
||
v__token__Pos_free(&(it->return_type_pos));
|
||
}
|
||
|
||
void Array_v__ast__Fn_free(Array_v__ast__Fn* it) {
|
||
for (int i = 0; i < it->len; i++) {
|
||
v__ast__Fn_free(&(((v__ast__Fn*)it->data)[i]));
|
||
}
|
||
array_free(it);
|
||
}
|
||
|
||
void v__ast__TypeSymbol_free(v__ast__TypeSymbol* it) {
|
||
Array_v__ast__Fn_free(&(it->methods));
|
||
string_free(&(it->name));
|
||
string_free(&(it->cname));
|
||
string_free(&(it->mod));
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL void anon_fn_6b7dbc3eb6b094a7__82(void) {
|
||
println(_SLIT("}"));
|
||
}
|
||
|
||
|
||
|
||
// V out
|
||
|
||
// >> typeof() support for sum types / interfaces
|
||
static char * v_typeof_interface_IError(int sidx) { /* IError */
|
||
if (sidx == _IError_None___index) return "None__";
|
||
if (sidx == _IError_Error_index) return "Error";
|
||
if (sidx == _IError_MessageError_index) return "MessageError";
|
||
if (sidx == _IError_time__TimeParseError_index) return "time.TimeParseError";
|
||
if (sidx == _IError_flag__UnkownFlagError_index) return "flag.UnkownFlagError";
|
||
if (sidx == _IError_flag__ArgsCountError_index) return "flag.ArgsCountError";
|
||
if (sidx == _IError_semver__InvalidComparatorFormatError_index) return "semver.InvalidComparatorFormatError";
|
||
if (sidx == _IError_semver__EmptyInputError_index) return "semver.EmptyInputError";
|
||
if (sidx == _IError_semver__InvalidVersionFormatError_index) return "semver.InvalidVersionFormatError";
|
||
if (sidx == _IError_os__FileNotOpenedError_index) return "os.FileNotOpenedError";
|
||
if (sidx == _IError_os__SizeOfTypeIs0Error_index) return "os.SizeOfTypeIs0Error";
|
||
if (sidx == _IError_os__ExecutableNotFoundError_index) return "os.ExecutableNotFoundError";
|
||
if (sidx == _IError_v__gen__c__UnsupportedAssertCtempTransform_index) return "v.gen.c.UnsupportedAssertCtempTransform";
|
||
return "unknown IError";
|
||
}
|
||
|
||
static int v_typeof_interface_idx_IError(int sidx) { /* IError */
|
||
if (sidx == _IError_None___index) return 65610;
|
||
if (sidx == _IError_Error_index) return 75;
|
||
if (sidx == _IError_MessageError_index) return 76;
|
||
if (sidx == _IError_time__TimeParseError_index) return 224;
|
||
if (sidx == _IError_flag__UnkownFlagError_index) return 66099;
|
||
if (sidx == _IError_flag__ArgsCountError_index) return 66100;
|
||
if (sidx == _IError_semver__InvalidComparatorFormatError_index) return 66111;
|
||
if (sidx == _IError_semver__EmptyInputError_index) return 66113;
|
||
if (sidx == _IError_semver__InvalidVersionFormatError_index) return 66114;
|
||
if (sidx == _IError_os__FileNotOpenedError_index) return 65650;
|
||
if (sidx == _IError_os__SizeOfTypeIs0Error_index) return 65651;
|
||
if (sidx == _IError_os__ExecutableNotFoundError_index) return 65664;
|
||
if (sidx == _IError_v__gen__c__UnsupportedAssertCtempTransform_index) return 505;
|
||
return 29;
|
||
}
|
||
static char * v_typeof_interface_rand__PRNG(int sidx) { /* rand.PRNG */
|
||
if (sidx == _rand__PRNG_rand__wyrand__WyRandRNG_index) return "rand.wyrand.WyRandRNG";
|
||
return "unknown rand.PRNG";
|
||
}
|
||
|
||
static int v_typeof_interface_idx_rand__PRNG(int sidx) { /* rand.PRNG */
|
||
if (sidx == _rand__PRNG_rand__wyrand__WyRandRNG_index) return 65740;
|
||
return 198;
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__TypeDecl(int sidx) { /* v.ast.TypeDecl */
|
||
switch(sidx) {
|
||
case 247: return "v.ast.TypeDecl";
|
||
case 244: return "v.ast.AliasTypeDecl";
|
||
case 245: return "v.ast.FnTypeDecl";
|
||
case 246: return "v.ast.SumTypeDecl";
|
||
default: return "unknown v.ast.TypeDecl";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__TypeDecl(int sidx) { /* v.ast.TypeDecl */
|
||
switch(sidx) {
|
||
case 247: return 247;
|
||
case 244: return 244;
|
||
case 245: return 245;
|
||
case 246: return 246;
|
||
default: return 247;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__Expr(int sidx) { /* v.ast.Expr */
|
||
switch(sidx) {
|
||
case 299: return "v.ast.Expr";
|
||
case 248: return "v.ast.AnonFn";
|
||
case 249: return "v.ast.ArrayDecompose";
|
||
case 250: return "v.ast.ArrayInit";
|
||
case 251: return "v.ast.AsCast";
|
||
case 252: return "v.ast.Assoc";
|
||
case 253: return "v.ast.AtExpr";
|
||
case 254: return "v.ast.BoolLiteral";
|
||
case 255: return "v.ast.CTempVar";
|
||
case 256: return "v.ast.CallExpr";
|
||
case 257: return "v.ast.CastExpr";
|
||
case 258: return "v.ast.ChanInit";
|
||
case 259: return "v.ast.CharLiteral";
|
||
case 260: return "v.ast.Comment";
|
||
case 261: return "v.ast.ComptimeCall";
|
||
case 262: return "v.ast.ComptimeSelector";
|
||
case 263: return "v.ast.ComptimeType";
|
||
case 264: return "v.ast.ConcatExpr";
|
||
case 265: return "v.ast.DumpExpr";
|
||
case 266: return "v.ast.EmptyExpr";
|
||
case 267: return "v.ast.EnumVal";
|
||
case 268: return "v.ast.FloatLiteral";
|
||
case 269: return "v.ast.GoExpr";
|
||
case 270: return "v.ast.Ident";
|
||
case 271: return "v.ast.IfExpr";
|
||
case 272: return "v.ast.IfGuardExpr";
|
||
case 273: return "v.ast.IndexExpr";
|
||
case 274: return "v.ast.InfixExpr";
|
||
case 275: return "v.ast.IntegerLiteral";
|
||
case 276: return "v.ast.IsRefType";
|
||
case 277: return "v.ast.Likely";
|
||
case 278: return "v.ast.LockExpr";
|
||
case 279: return "v.ast.MapInit";
|
||
case 280: return "v.ast.MatchExpr";
|
||
case 281: return "v.ast.NodeError";
|
||
case 282: return "v.ast.None";
|
||
case 283: return "v.ast.OffsetOf";
|
||
case 284: return "v.ast.OrExpr";
|
||
case 285: return "v.ast.ParExpr";
|
||
case 286: return "v.ast.PostfixExpr";
|
||
case 287: return "v.ast.PrefixExpr";
|
||
case 288: return "v.ast.RangeExpr";
|
||
case 289: return "v.ast.SelectExpr";
|
||
case 290: return "v.ast.SelectorExpr";
|
||
case 291: return "v.ast.SizeOf";
|
||
case 292: return "v.ast.SqlExpr";
|
||
case 293: return "v.ast.StringInterLiteral";
|
||
case 294: return "v.ast.StringLiteral";
|
||
case 295: return "v.ast.StructInit";
|
||
case 296: return "v.ast.TypeNode";
|
||
case 297: return "v.ast.TypeOf";
|
||
case 298: return "v.ast.UnsafeExpr";
|
||
default: return "unknown v.ast.Expr";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__Expr(int sidx) { /* v.ast.Expr */
|
||
switch(sidx) {
|
||
case 299: return 299;
|
||
case 248: return 248;
|
||
case 249: return 249;
|
||
case 250: return 250;
|
||
case 251: return 251;
|
||
case 252: return 252;
|
||
case 253: return 253;
|
||
case 254: return 254;
|
||
case 255: return 255;
|
||
case 256: return 256;
|
||
case 257: return 257;
|
||
case 258: return 258;
|
||
case 259: return 259;
|
||
case 260: return 260;
|
||
case 261: return 261;
|
||
case 262: return 262;
|
||
case 263: return 263;
|
||
case 264: return 264;
|
||
case 265: return 265;
|
||
case 266: return 266;
|
||
case 267: return 267;
|
||
case 268: return 268;
|
||
case 269: return 269;
|
||
case 270: return 270;
|
||
case 271: return 271;
|
||
case 272: return 272;
|
||
case 273: return 273;
|
||
case 274: return 274;
|
||
case 275: return 275;
|
||
case 276: return 276;
|
||
case 277: return 277;
|
||
case 278: return 278;
|
||
case 279: return 279;
|
||
case 280: return 280;
|
||
case 281: return 281;
|
||
case 282: return 282;
|
||
case 283: return 283;
|
||
case 284: return 284;
|
||
case 285: return 285;
|
||
case 286: return 286;
|
||
case 287: return 287;
|
||
case 288: return 288;
|
||
case 289: return 289;
|
||
case 290: return 290;
|
||
case 291: return 291;
|
||
case 292: return 292;
|
||
case 293: return 293;
|
||
case 294: return 294;
|
||
case 295: return 295;
|
||
case 296: return 296;
|
||
case 297: return 297;
|
||
case 298: return 298;
|
||
default: return 299;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__Stmt(int sidx) { /* v.ast.Stmt */
|
||
switch(sidx) {
|
||
case 324: return "v.ast.Stmt";
|
||
case 300: return "v.ast.AsmStmt";
|
||
case 301: return "v.ast.AssertStmt";
|
||
case 302: return "v.ast.AssignStmt";
|
||
case 303: return "v.ast.Block";
|
||
case 304: return "v.ast.BranchStmt";
|
||
case 305: return "v.ast.ComptimeFor";
|
||
case 306: return "v.ast.ConstDecl";
|
||
case 307: return "v.ast.DeferStmt";
|
||
case 308: return "v.ast.EmptyStmt";
|
||
case 309: return "v.ast.EnumDecl";
|
||
case 310: return "v.ast.ExprStmt";
|
||
case 185: return "v.ast.FnDecl";
|
||
case 311: return "v.ast.ForCStmt";
|
||
case 312: return "v.ast.ForInStmt";
|
||
case 313: return "v.ast.ForStmt";
|
||
case 314: return "v.ast.GlobalDecl";
|
||
case 315: return "v.ast.GotoLabel";
|
||
case 316: return "v.ast.GotoStmt";
|
||
case 317: return "v.ast.HashStmt";
|
||
case 318: return "v.ast.Import";
|
||
case 319: return "v.ast.InterfaceDecl";
|
||
case 320: return "v.ast.Module";
|
||
case 281: return "v.ast.NodeError";
|
||
case 321: return "v.ast.Return";
|
||
case 322: return "v.ast.SqlStmt";
|
||
case 323: return "v.ast.StructDecl";
|
||
case 247: return "v.ast.TypeDecl";
|
||
default: return "unknown v.ast.Stmt";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__Stmt(int sidx) { /* v.ast.Stmt */
|
||
switch(sidx) {
|
||
case 324: return 324;
|
||
case 300: return 300;
|
||
case 301: return 301;
|
||
case 302: return 302;
|
||
case 303: return 303;
|
||
case 304: return 304;
|
||
case 305: return 305;
|
||
case 306: return 306;
|
||
case 307: return 307;
|
||
case 308: return 308;
|
||
case 309: return 309;
|
||
case 310: return 310;
|
||
case 185: return 185;
|
||
case 311: return 311;
|
||
case 312: return 312;
|
||
case 313: return 313;
|
||
case 314: return 314;
|
||
case 315: return 315;
|
||
case 316: return 316;
|
||
case 317: return 317;
|
||
case 318: return 318;
|
||
case 319: return 319;
|
||
case 320: return 320;
|
||
case 281: return 281;
|
||
case 321: return 321;
|
||
case 322: return 322;
|
||
case 323: return 323;
|
||
case 247: return 247;
|
||
default: return 324;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__ScopeObject(int sidx) { /* v.ast.ScopeObject */
|
||
switch(sidx) {
|
||
case 329: return "v.ast.ScopeObject";
|
||
case 325: return "v.ast.AsmRegister";
|
||
case 326: return "v.ast.ConstField";
|
||
case 327: return "v.ast.GlobalField";
|
||
case 328: return "v.ast.Var";
|
||
default: return "unknown v.ast.ScopeObject";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__ScopeObject(int sidx) { /* v.ast.ScopeObject */
|
||
switch(sidx) {
|
||
case 329: return 329;
|
||
case 325: return 325;
|
||
case 326: return 326;
|
||
case 327: return 327;
|
||
case 328: return 328;
|
||
default: return 329;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__Node(int sidx) { /* v.ast.Node */
|
||
switch(sidx) {
|
||
case 339: return "v.ast.Node";
|
||
case 330: return "v.ast.CallArg";
|
||
case 326: return "v.ast.ConstField";
|
||
case 331: return "v.ast.EmptyNode";
|
||
case 332: return "v.ast.EnumField";
|
||
case 299: return "v.ast.Expr";
|
||
case 176: return "v.ast.File";
|
||
case 327: return "v.ast.GlobalField";
|
||
case 333: return "v.ast.IfBranch";
|
||
case 334: return "v.ast.MatchBranch";
|
||
case 281: return "v.ast.NodeError";
|
||
case 335: return "v.ast.Param";
|
||
case 329: return "v.ast.ScopeObject";
|
||
case 336: return "v.ast.SelectBranch";
|
||
case 324: return "v.ast.Stmt";
|
||
case 337: return "v.ast.StructField";
|
||
case 338: return "v.ast.StructInitField";
|
||
default: return "unknown v.ast.Node";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__Node(int sidx) { /* v.ast.Node */
|
||
switch(sidx) {
|
||
case 339: return 339;
|
||
case 330: return 330;
|
||
case 326: return 326;
|
||
case 331: return 331;
|
||
case 332: return 332;
|
||
case 299: return 299;
|
||
case 176: return 176;
|
||
case 327: return 327;
|
||
case 333: return 333;
|
||
case 334: return 334;
|
||
case 281: return 281;
|
||
case 335: return 335;
|
||
case 329: return 329;
|
||
case 336: return 336;
|
||
case 324: return 324;
|
||
case 337: return 337;
|
||
case 338: return 338;
|
||
default: return 339;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__ComptTimeConstValue(int sidx) { /* v.ast.ComptTimeConstValue */
|
||
switch(sidx) {
|
||
case 353: return "v.ast.ComptTimeConstValue";
|
||
case 266: return "v.ast.EmptyExpr";
|
||
case 15: return "f32";
|
||
case 16: return "f64";
|
||
case 6: return "i16";
|
||
case 8: return "i64";
|
||
case 5: return "i8";
|
||
case 7: return "int";
|
||
case 21: return "rune";
|
||
case 20: return "string";
|
||
case 11: return "u16";
|
||
case 12: return "u32";
|
||
case 13: return "u64";
|
||
case 10: return "u8";
|
||
default: return "unknown v.ast.ComptTimeConstValue";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__ComptTimeConstValue(int sidx) { /* v.ast.ComptTimeConstValue */
|
||
switch(sidx) {
|
||
case 353: return 353;
|
||
case 266: return 266;
|
||
case 15: return 15;
|
||
case 16: return 16;
|
||
case 6: return 6;
|
||
case 8: return 8;
|
||
case 5: return 5;
|
||
case 7: return 7;
|
||
case 21: return 21;
|
||
case 20: return 20;
|
||
case 11: return 11;
|
||
case 12: return 12;
|
||
case 13: return 13;
|
||
case 10: return 10;
|
||
default: return 353;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__IdentInfo(int sidx) { /* v.ast.IdentInfo */
|
||
switch(sidx) {
|
||
case 381: return "v.ast.IdentInfo";
|
||
case 379: return "v.ast.IdentFn";
|
||
case 380: return "v.ast.IdentVar";
|
||
default: return "unknown v.ast.IdentInfo";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__IdentInfo(int sidx) { /* v.ast.IdentInfo */
|
||
switch(sidx) {
|
||
case 381: return 381;
|
||
case 379: return 379;
|
||
case 380: return 380;
|
||
default: return 381;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__AsmArg(int sidx) { /* v.ast.AsmArg */
|
||
switch(sidx) {
|
||
case 398: return "v.ast.AsmArg";
|
||
case 400: return "v.ast.AsmAddressing";
|
||
case 401: return "v.ast.AsmAlias";
|
||
case 402: return "v.ast.AsmDisp";
|
||
case 325: return "v.ast.AsmRegister";
|
||
case 254: return "v.ast.BoolLiteral";
|
||
case 259: return "v.ast.CharLiteral";
|
||
case 268: return "v.ast.FloatLiteral";
|
||
case 275: return "v.ast.IntegerLiteral";
|
||
case 20: return "string";
|
||
default: return "unknown v.ast.AsmArg";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__AsmArg(int sidx) { /* v.ast.AsmArg */
|
||
switch(sidx) {
|
||
case 398: return 398;
|
||
case 400: return 400;
|
||
case 401: return 401;
|
||
case 402: return 402;
|
||
case 325: return 325;
|
||
case 254: return 254;
|
||
case 259: return 259;
|
||
case 268: return 268;
|
||
case 275: return 275;
|
||
case 20: return 20;
|
||
default: return 398;
|
||
}
|
||
}
|
||
static char * v_typeof_sumtype_v__ast__TypeInfo(int sidx) { /* v.ast.TypeInfo */
|
||
switch(sidx) {
|
||
case 451: return "v.ast.TypeInfo";
|
||
case 434: return "v.ast.Aggregate";
|
||
case 436: return "v.ast.Alias";
|
||
case 415: return "v.ast.Array";
|
||
case 444: return "v.ast.ArrayFixed";
|
||
case 445: return "v.ast.Chan";
|
||
case 450: return "v.ast.Enum";
|
||
case 448: return "v.ast.FnType";
|
||
case 449: return "v.ast.GenericInst";
|
||
case 439: return "v.ast.Interface";
|
||
case 416: return "v.ast.Map";
|
||
case 447: return "v.ast.MultiReturn";
|
||
case 420: return "v.ast.Struct";
|
||
case 440: return "v.ast.SumType";
|
||
case 446: return "v.ast.Thread";
|
||
default: return "unknown v.ast.TypeInfo";
|
||
}
|
||
}
|
||
|
||
static int v_typeof_sumtype_idx_v__ast__TypeInfo(int sidx) { /* v.ast.TypeInfo */
|
||
switch(sidx) {
|
||
case 451: return 451;
|
||
case 434: return 434;
|
||
case 436: return 436;
|
||
case 415: return 415;
|
||
case 444: return 444;
|
||
case 445: return 445;
|
||
case 450: return 450;
|
||
case 448: return 448;
|
||
case 449: return 449;
|
||
case 439: return 439;
|
||
case 416: return 416;
|
||
case 447: return 447;
|
||
case 420: return 420;
|
||
case 440: return 440;
|
||
case 446: return 446;
|
||
default: return 451;
|
||
}
|
||
}
|
||
static char * v_typeof_interface_hash__Hasher(int sidx) { /* hash.Hasher */
|
||
return "unknown hash.Hasher";
|
||
}
|
||
|
||
static int v_typeof_interface_idx_hash__Hasher(int sidx) { /* hash.Hasher */
|
||
return 500;
|
||
}
|
||
static char * v_typeof_interface_hash__Hash32er(int sidx) { /* hash.Hash32er */
|
||
return "unknown hash.Hash32er";
|
||
}
|
||
|
||
static int v_typeof_interface_idx_hash__Hash32er(int sidx) { /* hash.Hash32er */
|
||
return 501;
|
||
}
|
||
static char * v_typeof_interface_hash__Hash64er(int sidx) { /* hash.Hash64er */
|
||
return "unknown hash.Hash64er";
|
||
}
|
||
|
||
static int v_typeof_interface_idx_hash__Hash64er(int sidx) { /* hash.Hash64er */
|
||
return 502;
|
||
}
|
||
static char * v_typeof_interface_v__ast__walker__Visitor(int sidx) { /* v.ast.walker.Visitor */
|
||
if (sidx == _v__ast__walker__Visitor_v__ast__walker__Inspector_index) return "v.ast.walker.Inspector";
|
||
if (sidx == _v__ast__walker__Visitor_v__callgraph__Mapper_index) return "v.callgraph.Mapper";
|
||
return "unknown v.ast.walker.Visitor";
|
||
}
|
||
|
||
static int v_typeof_interface_idx_v__ast__walker__Visitor(int sidx) { /* v.ast.walker.Visitor */
|
||
if (sidx == _v__ast__walker__Visitor_v__ast__walker__Inspector_index) return 537;
|
||
if (sidx == _v__ast__walker__Visitor_v__callgraph__Mapper_index) return 66029;
|
||
return 535;
|
||
}
|
||
// << typeof() support for sum types
|
||
|
||
// pointers to common sumtype fields
|
||
// pointers to common sumtype fields
|
||
// pointers to common sumtype fields
|
||
// TypeDecl
|
||
strings__Builder strings__new_builder(int initial_size) {
|
||
strings__Builder res = ((__new_array_with_default(0, initial_size, sizeof(u8), 0)));
|
||
ArrayFlags_set(&res.flags, ArrayFlags__noslices);
|
||
return res;
|
||
}
|
||
|
||
// Attr: [unsafe]
|
||
void strings__Builder_write_ptr(strings__Builder* b, u8* ptr, int len) {
|
||
if (len == 0) {
|
||
return;
|
||
}
|
||
array_push_many(b, ptr, len);
|
||
}
|
||
|
||
// Attr: [manualfree]
|
||
void strings__Builder_write_rune(strings__Builder* b, rune r) {
|
||
Array_fixed_u8_5 buffer = {0};
|
||
string res = utf32_to_str_no_malloc(((u32)(r)), &buffer[0]);
|
||
if (res.len == 0) {
|
||
return;
|
||
}
|
||
array_push_many(b, res.str, res.len);
|
||
}
|
||
|
||
void strings__Builder_write_runes(strings__Builder* b, Array_rune runes) {
|
||
Array_fixed_u8_5 buffer = {0};
|
||
for (int _t1 = 0; _t1 < runes.len; ++_t1) {
|
||
rune r = ((rune*)runes.data)[_t1];
|
||
string res = utf32_to_str_no_malloc(((u32)(r)), &buffer[0]);
|
||
if (res.len == 0) {
|
||
continue;
|
||
}
|
||
array_push_many(b, res.str, res.len);
|
||
}
|
||
}
|
||
|
||
void strings__Builder_clear(strings__Builder* b) {
|
||
*b = __new_array_with_default(0, b->cap, sizeof(u8), 0);
|
||
}
|
||
|
||
void strings__Builder_write_u8(strings__Builder* b, u8 data) {
|
||
array_push((array*)b, _MOV((u8[]){ data }));
|
||
}
|
||
|
||
void strings__Builder_write_byte(strings__Builder* b, byte data) {
|
||
array_push((array*)b, _MOV((u8[]){ data }));
|
||
}
|
||
|
||
_option_int strings__Builder_write(strings__Builder* b, Array_u8 data) {
|
||
if (data.len == 0) {
|
||
_option_int _t1;
|
||
opt_ok2(&(int[]) { 0 }, (_option*)(&_t1), sizeof(int));
|
||
return _t1;
|
||
}
|
||
_PUSH_MANY(b, (data), _t2, strings__Builder);
|
||
_option_int _t3;
|
||
opt_ok2(&(int[]) { data.len }, (_option*)(&_t3), sizeof(int));
|
||
return _t3;
|
||
}
|
||
|
||
// Attr: [manualfree]
|
||
void strings__Builder_drain_builder(strings__Builder* b, strings__Builder* other, int other_new_cap) {
|
||
_option_int _t1 = strings__Builder_write(b, *other);
|
||
if (_t1.state != 0) { /*or block*/
|
||
IError err = _t1.err;
|
||
_v_panic(IError_str(err));
|
||
VUNREACHABLE();
|
||
;
|
||
}
|
||
|
||
(*(int*)_t1.data);
|
||
strings__Builder_free(other);
|
||
*other = strings__new_builder(other_new_cap);
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u8 strings__Builder_byte_at(strings__Builder* b, int n) {
|
||
return (*(u8*)/*ee elem_sym */array_get(*(((Array_u8*)(b))), n));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline void strings__Builder_write_string(strings__Builder* b, string s) {
|
||
if (s.len == 0) {
|
||
return;
|
||
}
|
||
array_push_many(b, s.str, s.len);
|
||
}
|
||
|
||
void strings__Builder_go_back(strings__Builder* b, int n) {
|
||
array_trim(b, b->len - n);
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline VV_LOCAL_SYMBOL string strings__Builder_spart(strings__Builder* b, int start_pos, int n) {
|
||
{ // Unsafe block
|
||
u8* x = malloc_noscan(n + 1);
|
||
vmemcpy(x, ((u8*)(b->data)) + start_pos, n);
|
||
x[n] = 0;
|
||
return tos(x, n);
|
||
}
|
||
return (string){.str=(byteptr)"", .is_lit=1};
|
||
}
|
||
|
||
string strings__Builder_cut_last(strings__Builder* b, int n) {
|
||
int cut_pos = b->len - n;
|
||
string res = strings__Builder_spart(b, cut_pos, n);
|
||
array_trim(b, cut_pos);
|
||
return res;
|
||
}
|
||
|
||
string strings__Builder_cut_to(strings__Builder* b, int pos) {
|
||
if (pos > b->len) {
|
||
return _SLIT("");
|
||
}
|
||
return strings__Builder_cut_last(b, b->len - pos);
|
||
}
|
||
|
||
void strings__Builder_go_back_to(strings__Builder* b, int pos) {
|
||
array_trim(b, pos);
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline void strings__Builder_writeln(strings__Builder* b, string s) {
|
||
if (s.len > 0) {
|
||
array_push_many(b, s.str, s.len);
|
||
}
|
||
array_push((array*)b, _MOV((u8[]){ ((u8)('\n')) }));
|
||
}
|
||
|
||
string strings__Builder_last_n(strings__Builder* b, int n) {
|
||
if (n > b->len) {
|
||
return _SLIT("");
|
||
}
|
||
return strings__Builder_spart(b, b->len - n, n);
|
||
}
|
||
|
||
string strings__Builder_after(strings__Builder* b, int n) {
|
||
if (n >= b->len) {
|
||
return _SLIT("");
|
||
}
|
||
return strings__Builder_spart(b, n, b->len - n);
|
||
}
|
||
|
||
string strings__Builder_str(strings__Builder* b) {
|
||
array_push((array*)b, _MOV((u8[]){ ((u8)(0)) }));
|
||
u8* bcopy = ((u8*)(memdup_noscan(b->data, b->len)));
|
||
string s = u8_vstring_with_len(bcopy, b->len - 1);
|
||
array_trim(b, 0);
|
||
return s;
|
||
}
|
||
|
||
void strings__Builder_ensure_cap(strings__Builder* b, int n) {
|
||
if (n <= b->cap) {
|
||
return;
|
||
}
|
||
u8* new_data = vcalloc(n * b->element_size);
|
||
if (b->data != ((voidptr)(0))) {
|
||
vmemcpy(new_data, b->data, b->len * b->element_size);
|
||
if (ArrayFlags_has(&b->flags, ArrayFlags__noslices)) {
|
||
_v_free(b->data);
|
||
}
|
||
}
|
||
{ // Unsafe block
|
||
b->data = new_data;
|
||
b->offset = 0;
|
||
b->cap = n;
|
||
}
|
||
}
|
||
|
||
// Attr: [unsafe]
|
||
void strings__Builder_free(strings__Builder* b) {
|
||
if (b->data != 0) {
|
||
_v_free(b->data);
|
||
{ // Unsafe block
|
||
b->data = ((voidptr)(0));
|
||
}
|
||
}
|
||
}
|
||
|
||
int strings__levenshtein_distance(string a, string b) {
|
||
Array_int f = array_repeat_to_depth(new_array_from_c_array(1, 1, sizeof(int), _MOV((int[1]){0})), b.len + 1, 0);
|
||
for (int j = 0; j < f.len; ++j) {
|
||
array_set(&f, j, &(int[]) { j });
|
||
}
|
||
for (int _t1 = 0; _t1 < a.len; ++_t1) {
|
||
u8 ca = a.str[_t1];
|
||
int j = 1;
|
||
int fj1 = (*(int*)/*ee elem_sym */array_get(f, 0));
|
||
(*(int*)/*ee elem_sym */array_get(f, 0))++;
|
||
for (int _t2 = 0; _t2 < b.len; ++_t2) {
|
||
u8 cb = b.str[_t2];
|
||
int mn = ((*(int*)/*ee elem_sym */array_get(f, j)) + 1 <= (*(int*)/*ee elem_sym */array_get(f, j - 1)) + 1 ? ((*(int*)/*ee elem_sym */array_get(f, j)) + 1) : ((*(int*)/*ee elem_sym */array_get(f, j - 1)) + 1));
|
||
if (cb != ca) {
|
||
mn = (mn <= fj1 + 1 ? (mn) : (fj1 + 1));
|
||
} else {
|
||
mn = (mn <= fj1 ? (mn) : (fj1));
|
||
}
|
||
fj1 = (*(int*)/*ee elem_sym */array_get(f, j));
|
||
array_set(&f, j, &(int[]) { mn });
|
||
j++;
|
||
}
|
||
}
|
||
return (*(int*)/*ee elem_sym */array_get(f, f.len - 1));
|
||
}
|
||
|
||
f32 strings__levenshtein_distance_percentage(string a, string b) {
|
||
int d = strings__levenshtein_distance(a, b);
|
||
int l = (a.len >= b.len ? (a.len) : (b.len));
|
||
return (1.00 - ((f32)(d)) / ((f32)(l))) * 100.00;
|
||
}
|
||
|
||
f32 strings__dice_coefficient(string s1, string s2) {
|
||
if (s1.len == 0 || s2.len == 0) {
|
||
return 0.0;
|
||
}
|
||
if (string__eq(s1, s2)) {
|
||
return 1.0;
|
||
}
|
||
if (s1.len < 2 || s2.len < 2) {
|
||
return 0.0;
|
||
}
|
||
string a = (s1.len > s2.len ? (s1) : (s2));
|
||
string b = (string__eq(a, s1) ? (s2) : (s1));
|
||
Map_string_int first_bigrams = new_map(sizeof(string), sizeof(int), &map_hash_string, &map_eq_string, &map_clone_string, &map_free_string)
|
||
;
|
||
for (int i = 0; i < a.len - 1; ++i) {
|
||
string bigram = string_substr(a, i, i + 2);
|
||
int q = (_IN_MAP(ADDR(string, bigram), ADDR(map, first_bigrams)) ? ((*(int*)map_get(ADDR(map, first_bigrams), &(string[]){bigram}, &(int[]){ 0 })) + 1) : (1));
|
||
map_set(&first_bigrams, &(string[]){bigram}, &(int[]) { q });
|
||
}
|
||
int intersection_size = 0;
|
||
for (int i = 0; i < b.len - 1; ++i) {
|
||
string bigram = string_substr(b, i, i + 2);
|
||
int count = (_IN_MAP(ADDR(string, bigram), ADDR(map, first_bigrams)) ? ((*(int*)map_get(ADDR(map, first_bigrams), &(string[]){bigram}, &(int[]){ 0 }))) : (0));
|
||
if (count > 0) {
|
||
map_set(&first_bigrams, &(string[]){bigram}, &(int[]) { count - 1 });
|
||
intersection_size++;
|
||
}
|
||
}
|
||
return (2.0 * ((f32)(intersection_size))) / (((f32)(a.len)) + ((f32)(b.len)) - 2);
|
||
}
|
||
|
||
string strings__repeat(u8 c, int n) {
|
||
if (n <= 0) {
|
||
return _SLIT("");
|
||
}
|
||
u8* bytes = malloc_noscan(n + 1);
|
||
{ // Unsafe block
|
||
memset(bytes, c, n);
|
||
bytes[n] = '0';
|
||
}
|
||
return u8_vstring_with_len(bytes, n);
|
||
}
|
||
|
||
string strings__repeat_string(string s, int n) {
|
||
if (n <= 0 || s.len == 0) {
|
||
return _SLIT("");
|
||
}
|
||
int slen = s.len;
|
||
int blen = slen * n;
|
||
u8* bytes = malloc_noscan(blen + 1);
|
||
for (int bi = 0; bi < n; ++bi) {
|
||
int bislen = bi * slen;
|
||
for (int si = 0; si < slen; ++si) {
|
||
{ // Unsafe block
|
||
bytes[bislen + si] = string_at(s, si);
|
||
}
|
||
}
|
||
}
|
||
{ // Unsafe block
|
||
bytes[blen] = '0';
|
||
}
|
||
return u8_vstring_with_len(bytes, blen);
|
||
}
|
||
|
||
string strings__find_between_pair_u8(string input, u8 start, u8 end) {
|
||
int marks = 0;
|
||
int start_index = -1;
|
||
for (int i = 0; i < input.len; ++i) {
|
||
u8 b = input.str[i];
|
||
if (b == start) {
|
||
if (start_index == -1) {
|
||
start_index = i + 1;
|
||
}
|
||
marks++;
|
||
continue;
|
||
}
|
||
if (start_index > 0) {
|
||
if (b == end) {
|
||
marks--;
|
||
if (marks == 0) {
|
||
return string_substr(input, start_index, i);
|
||
}
|
||
}
|
||
}
|
||
}
|
||
return _SLIT("");
|
||
}
|
||
|
||
string strings__find_between_pair_rune(string input, rune start, rune end) {
|
||
int marks = 0;
|
||
int start_index = -1;
|
||
Array_rune runes = string_runes(input);
|
||
for (int i = 0; i < runes.len; ++i) {
|
||
rune r = ((rune*)runes.data)[i];
|
||
if (r == start) {
|
||
if (start_index == -1) {
|
||
start_index = i + 1;
|
||
}
|
||
marks++;
|
||
continue;
|
||
}
|
||
if (start_index > 0) {
|
||
if (r == end) {
|
||
marks--;
|
||
if (marks == 0) {
|
||
return Array_rune_string(array_slice(runes, start_index, i));
|
||
}
|
||
}
|
||
}
|
||
}
|
||
return _SLIT("");
|
||
}
|
||
|
||
string strings__find_between_pair_string(string input, string start, string end) {
|
||
int start_index = -1;
|
||
int marks = 0;
|
||
Array_rune start_runes = string_runes(start);
|
||
Array_rune end_runes = string_runes(end);
|
||
Array_rune runes = string_runes(input);
|
||
int i = 0;
|
||
for (; i < runes.len; i++) {
|
||
Array_rune start_slice = array_slice_ni(runes, i, i + start_runes.len);
|
||
if (Array_rune_arr_eq(start_slice, start_runes)) {
|
||
i = i + start_runes.len - 1;
|
||
if (start_index < 0) {
|
||
start_index = i + 1;
|
||
}
|
||
marks++;
|
||
continue;
|
||
}
|
||
if (start_index > 0) {
|
||
Array_rune end_slice = array_slice_ni(runes, i, i + end_runes.len);
|
||
if (Array_rune_arr_eq(end_slice, end_runes)) {
|
||
marks--;
|
||
if (marks == 0) {
|
||
return Array_rune_string(array_slice(runes, start_index, i));
|
||
}
|
||
i = i + end_runes.len - 1;
|
||
continue;
|
||
}
|
||
}
|
||
}
|
||
return _SLIT("");
|
||
}
|
||
|
||
Array_string strings__split_capital(string s) {
|
||
Array_string res = __new_array_with_default(0, 0, sizeof(string), 0);
|
||
int word_start = 0;
|
||
for (int idx = 0; idx < s.len; ++idx) {
|
||
u8 c = s.str[idx];
|
||
if (c >= 'A' && c <= 'Z') {
|
||
if (word_start != idx) {
|
||
array_push((array*)&res, _MOV((string[]){ string_substr_ni(s, word_start, idx) }));
|
||
}
|
||
word_start = idx;
|
||
continue;
|
||
}
|
||
}
|
||
if (word_start != s.len) {
|
||
array_push((array*)&res, _MOV((string[]){ string_substr_ni(s, word_start, (s).len) }));
|
||
}
|
||
return res;
|
||
}
|
||
|
||
int math__bits__leading_zeros_8(u8 x) {
|
||
return 8 - math__bits__len_8(x);
|
||
}
|
||
|
||
int math__bits__leading_zeros_16(u16 x) {
|
||
return 16 - math__bits__len_16(x);
|
||
}
|
||
|
||
int math__bits__leading_zeros_32(u32 x) {
|
||
return 32 - math__bits__len_32(x);
|
||
}
|
||
|
||
int math__bits__leading_zeros_64(u64 x) {
|
||
return 64 - math__bits__len_64(x);
|
||
}
|
||
|
||
int math__bits__trailing_zeros_8(u8 x) {
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__ntz_8_tab, x))));
|
||
}
|
||
|
||
int math__bits__trailing_zeros_16(u16 x) {
|
||
if (x == 0U) {
|
||
return 16;
|
||
}
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__de_bruijn32tab, ((u32)((x & -x))) * _const_math__bits__de_bruijn32 >> (27)))));
|
||
}
|
||
|
||
int math__bits__trailing_zeros_32(u32 x) {
|
||
if (x == 0U) {
|
||
return 32;
|
||
}
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__de_bruijn32tab, ((x & -x)) * _const_math__bits__de_bruijn32 >> (27)))));
|
||
}
|
||
|
||
int math__bits__trailing_zeros_64(u64 x) {
|
||
if (x == 0U) {
|
||
return 64;
|
||
}
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__de_bruijn64tab, ((x & -x)) * _const_math__bits__de_bruijn64 >> (58)))));
|
||
}
|
||
|
||
int math__bits__ones_count_8(u8 x) {
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, x))));
|
||
}
|
||
|
||
int math__bits__ones_count_16(u16 x) {
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, x >> 8U)) + (*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, (x & ((u16)(0xffU)))))));
|
||
}
|
||
|
||
int math__bits__ones_count_32(u32 x) {
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, x >> 24U)) + (*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, (x >> 16U & 0xffU))) + (*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, (x >> 8U & 0xffU))) + (*(u8*)/*ee elem_sym */array_get(_const_math__bits__pop_8_tab, (x & ((u32)(0xffU)))))));
|
||
}
|
||
|
||
int math__bits__ones_count_64(u64 x) {
|
||
u64 y = ((x >> ((u64)(1U)) & ((_const_math__bits__m0 & _const_math__bits__max_u64)))) + ((x & ((_const_math__bits__m0 & _const_math__bits__max_u64))));
|
||
y = ((y >> ((u64)(2U)) & ((_const_math__bits__m1 & _const_math__bits__max_u64)))) + ((y & ((_const_math__bits__m1 & _const_math__bits__max_u64))));
|
||
y = (((y >> 4U) + y) & ((_const_math__bits__m2 & _const_math__bits__max_u64)));
|
||
y += y >> 8U;
|
||
y += y >> 16U;
|
||
y += y >> 32U;
|
||
return (((int)(y)) & ((128) - 1));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u8 math__bits__rotate_left_8(u8 x, int k) {
|
||
u8 s = (((u8)(k)) & (_const_math__bits__n8 - ((u8)(1))));
|
||
return ((x << s) | (x >> (_const_math__bits__n8 - s)));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u16 math__bits__rotate_left_16(u16 x, int k) {
|
||
u16 s = (((u16)(k)) & (_const_math__bits__n16 - ((u16)(1U))));
|
||
return ((x << s) | (x >> (_const_math__bits__n16 - s)));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u32 math__bits__rotate_left_32(u32 x, int k) {
|
||
u32 s = (((u32)(k)) & (_const_math__bits__n32 - ((u32)(1U))));
|
||
return ((x << s) | (x >> (_const_math__bits__n32 - s)));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u64 math__bits__rotate_left_64(u64 x, int k) {
|
||
u64 s = (((u64)(k)) & (_const_math__bits__n64 - ((u64)(1U))));
|
||
return ((x << s) | (x >> (_const_math__bits__n64 - s)));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u8 math__bits__reverse_8(u8 x) {
|
||
return (*(u8*)/*ee elem_sym */array_get(_const_math__bits__rev_8_tab, x));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u16 math__bits__reverse_16(u16 x) {
|
||
return (((u16)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__rev_8_tab, x >> 8U)))) | (((u16)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__rev_8_tab, (x & ((u16)(0xffU))))))) << 8U));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u32 math__bits__reverse_32(u32 x) {
|
||
u64 y = ((((x >> ((u32)(1U)) & ((_const_math__bits__m0 & _const_math__bits__max_u32)))) | (((x & ((_const_math__bits__m0 & _const_math__bits__max_u32)))) << 1U)));
|
||
y = ((((y >> ((u32)(2U)) & ((_const_math__bits__m1 & _const_math__bits__max_u32)))) | (((y & ((_const_math__bits__m1 & _const_math__bits__max_u32)))) << ((u32)(2U)))));
|
||
y = ((((y >> ((u32)(4U)) & ((_const_math__bits__m2 & _const_math__bits__max_u32)))) | (((y & ((_const_math__bits__m2 & _const_math__bits__max_u32)))) << ((u32)(4U)))));
|
||
return math__bits__reverse_bytes_32(((u32)(y)));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u64 math__bits__reverse_64(u64 x) {
|
||
u64 y = ((((x >> ((u64)(1U)) & ((_const_math__bits__m0 & _const_math__bits__max_u64)))) | (((x & ((_const_math__bits__m0 & _const_math__bits__max_u64)))) << 1U)));
|
||
y = ((((y >> ((u64)(2U)) & ((_const_math__bits__m1 & _const_math__bits__max_u64)))) | (((y & ((_const_math__bits__m1 & _const_math__bits__max_u64)))) << 2U)));
|
||
y = ((((y >> ((u64)(4U)) & ((_const_math__bits__m2 & _const_math__bits__max_u64)))) | (((y & ((_const_math__bits__m2 & _const_math__bits__max_u64)))) << 4U)));
|
||
return math__bits__reverse_bytes_64(y);
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u16 math__bits__reverse_bytes_16(u16 x) {
|
||
return ((x >> 8U) | (x << 8U));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u32 math__bits__reverse_bytes_32(u32 x) {
|
||
u64 y = ((((x >> ((u32)(8U)) & ((_const_math__bits__m3 & _const_math__bits__max_u32)))) | (((x & ((_const_math__bits__m3 & _const_math__bits__max_u32)))) << ((u32)(8U)))));
|
||
return ((u32)(((y >> 16U) | (y << 16U))));
|
||
}
|
||
|
||
// Attr: [inline]
|
||
inline u64 math__bits__reverse_bytes_64(u64 x) {
|
||
u64 y = ((((x >> ((u64)(8U)) & ((_const_math__bits__m3 & _const_math__bits__max_u64)))) | (((x & ((_const_math__bits__m3 & _const_math__bits__max_u64)))) << ((u64)(8U)))));
|
||
y = ((((y >> ((u64)(16U)) & ((_const_math__bits__m4 & _const_math__bits__max_u64)))) | (((y & ((_const_math__bits__m4 & _const_math__bits__max_u64)))) << ((u64)(16U)))));
|
||
return ((y >> 32U) | (y << 32U));
|
||
}
|
||
|
||
int math__bits__len_8(u8 x) {
|
||
return ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__len_8_tab, x))));
|
||
}
|
||
|
||
int math__bits__len_16(u16 x) {
|
||
u16 y = x;
|
||
int n = 0;
|
||
if (y >= 256U) {
|
||
y >>= 8U;
|
||
n = 8;
|
||
}
|
||
return n + ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__len_8_tab, y))));
|
||
}
|
||
|
||
int math__bits__len_32(u32 x) {
|
||
u32 y = x;
|
||
int n = 0;
|
||
if (y >= (65536)) {
|
||
y >>= 16U;
|
||
n = 16;
|
||
}
|
||
if (y >= (256)) {
|
||
y >>= 8U;
|
||
n += 8;
|
||
}
|
||
return n + ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__len_8_tab, y))));
|
||
}
|
||
|
||
int math__bits__len_64(u64 x) {
|
||
u64 y = x;
|
||
int n = 0;
|
||
if (y >= ((u64)(1U)) << ((u64)(32U))) {
|
||
y >>= 32U;
|
||
n = 32;
|
||
}
|
||
if (y >= ((u64)(1U)) << ((u64)(16U))) {
|
||
y >>= 16U;
|
||
n += 16;
|
||
}
|
||
if (y >= ((u64)(1U)) << ((u64)(8U))) {
|
||
y >>= 8U;
|
||
n += 8;
|
||
}
|
||
return n + ((int)((*(u8*)/*ee elem_sym */array_get(_const_math__bits__len_8_tab, y))));
|
||
}
|
||
|
||
multi_return_u32_u32 math__bits__add_32(u32 x, u32 y, u32 carry) {
|
||
u64 sum64 = ((u64)(x)) + ((u64)(y)) + ((u64)(carry));
|
||
u32 sum = ((u32)(sum64));
|
||
u32 carry_out = ((u32)(sum64 >> 32U));
|
||
return (multi_return_u32_u32){.arg0=sum, .arg1=carry_out};
|
||
}
|
||
|
||
multi_return_u64_u64 math__bits__add_64(u64 x, u64 y, u64 carry) {
|
||
u64 sum = x + y + carry;
|
||
u64 carry_out = ((((x & y)) | ((((x | y)) & ~sum)))) >> 63U;
|
||
return (multi_return_u64_u64){.arg0=sum, .arg1=carry_out};
|
||
}
|
||
|
||
multi_return_u32_u32 math__bits__sub_32(u32 x, u32 y, u32 borrow) {
|
||
u32 diff = x - y - borrow;
|
||
u32 borrow_out = ((((~x & y)) | ((~((x ^ y)) & diff)))) >> 31U;
|
||
return (multi_return_u32_u32){.arg0=diff, .arg1=borrow_out};
|
||
}
|
||
|
||
multi_return_u64_u64 math__bits__sub_64(u64 x, u64 y, u64 borrow) {
|
||
u64 diff = x - y - borrow;
|
||
u64 borrow_out = ((((~x & y)) | ((~((x ^ y)) & diff)))) >> 63U;
|
||
return (multi_return_u64_u64){.arg0=diff, .arg1=borrow_out};
|
||
}
|
||
|
||
multi_return_u32_u32 math__bits__mul_32(u32 x, u32 y) {
|
||
u64 tmp = ((u64)(x)) * ((u64)(y));
|
||
u32 hi = ((u32)(tmp >> 32U));
|
||
u32 lo = ((u32)(tmp));
|
||
return (multi_return_u32_u32){.arg0=hi, .arg1=lo};
|
||
}
|
||
|
||
multi_return_u64_u64 math__bits__mul_64(u64 x, u64 y) {
|
||
u64 x0 = (x & _const_math__bits__mask32);
|
||
u64 x1 = x >> 32U;
|
||
u64 y0 = (y & _const_math__bits__mask32);
|
||
u64 y1 = y >> 32U;
|
||
u64 w0 = x0 * y0;
|
||
u64 t = x1 * y0 + (w0 >> 32U);
|
||
u64 w1 = (t & _const_math__bits__mask32);
|
||
u64 w2 = t >> 32U;
|
||
w1 += x0 * y1;
|
||
u64 hi = x1 * y1 + w2 + (w1 >> 32U);
|
||
u64 lo = x * y;
|
||
return (multi_return_u64_u64){.arg0=hi, .arg1=lo};
|
||
}
|
||
|
||
multi_return_u32_u32 math__bits__div_32(u32 hi, u32 lo, u32 y) {
|
||
if (y != 0U && y <= hi) {
|
||
_v_panic(_const_math__bits__overflow_error);
|
||
VUNREACHABLE();
|
||
}
|
||
u64 z = ((((u64)(hi)) << 32U) | ((u64)(lo)));
|
||
u32 quo = ((u32)(z / ((u64)(y))));
|
||
u32 rem = ((u32)(z % ((u64)(y))));
|
||
return (multi_return_u32_u32){.arg0=quo, .arg1=rem};
|
||
}
|
||
|
||
multi_return_u64_u64 math__bits__div_64(u64 hi, u64 lo, u64 y1) {
|
||
u64 y = y1;
|
||
if (y == 0U) {
|
||
_v_panic(_const_math__bits__overflow_error);
|
||
VUNREACHABLE();
|
||
}
|
||
if (y <= hi) {
|
||
_v_panic(_const_math__bits__overflow_error);
|
||
VUNREACHABLE();
|
||
}
|
||
u32 s = ((u32)(math__bits__leading_zeros_64(y)));
|
||
y <<= s;
|
||
u64 yn1 = y >> 32U;
|
||
u64 yn0 = (y & _const_math__bits__mask32);
|
||
u64 ss1 = (hi << s);
|
||
u32 xxx = 64 - s;
|
||
u64 ss2 = lo >> xxx;
|
||
if (xxx == 64U) {
|
||
ss2 = 0U;
|
||
}
|
||
u64 un32 = (ss1 | ss2);
|
||
u64 un10 = lo << s;
|
||
u64 un1 = un10 >> 32U;
|
||
u64 un0 = (un10 & _const_math__bits__mask32);
|
||
u64 q1 = un32 / yn1;
|
||
u64 rhat = un32 - (q1 * yn1);
|
||
for (;;) {
|
||
if (!((q1 >= _const_math__bits__two32) || (q1 * yn0) > ((_const_math__bits__two32 * rhat) + un1))) break;
|
||
q1--;
|
||
rhat += yn1;
|
||
if (rhat >= _const_math__bits__two32) {
|
||
break;
|
||
}
|
||
}
|
||
u64 un21 = (un32 * _const_math__bits__two32) + (un1 - (q1 * y));
|
||
u64 q0 = un21 / yn1;
|
||
rhat = un21 - q0 * yn1;
|
||
for (;;) {
|
||
if (!((q0 >= _const_math__bits__two32) || (q0 * yn0) > ((_const_math__bits__two32 * rhat) + un0))) break;
|
||
q0--;
|
||
rhat += yn1;
|
||
if (rhat >= _const_math__bits__two32) {
|
||
break;
|
||
}
|
||
}
|
||
u64 qq = ((q1 * _const_math__bits__two32) + q0);
|
||
u64 rr = ((un21 * _const_math__bits__two32) + un0 - (q0 * y)) >> s;
|
||
return (multi_return_u64_u64){.arg0=qq, .arg1=rr};
|
||
}
|
||
|
||
u32 math__bits__rem_32(u32 hi, u32 lo, u32 y) {
|
||
return ((u32)((((((u64)(hi)) << 32U) | ((u64)(lo)))) % ((u64)(y))));
|
||
}
|
||
|
||
u64 math__bits__rem_64(u64 hi, u64 lo, u64 y) {
|
||
multi_return_u64_u64 mr_16658 = math__bits__div_64(hi % y, lo, y);
|
||
u64 rem = mr_16658.arg1;
|
||
return rem;
|
||
}
|
||
|
||
multi_return_f64_int math__bits__normalize(f64 x) {
|
||
f64 smallest_normal = 2.2250738585072014e-308;
|
||
if (((x > 0.0 ? (x) : (-x))) < smallest_normal) {
|
||
return (multi_return_f64_int){.arg0=x * (((u64)(1U)) << ((u64)(52U))), .arg1=-52};
|
||
}
|
||
return (multi_return_f64_int){.arg0=x, .arg1=0};
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__lsr96(u32 s2, u32 s1, u32 s0) {
|
||
u32 r0 = ((u32)(0U));
|
||
u32 r1 = ((u32)(0U));
|
||
u32 r2 = ((u32)(0U));
|
||
r0 = ((s0 >> 1U) | (((s1 & ((u32)(1U)))) << 31U));
|
||
r1 = ((s1 >> 1U) | (((s2 & ((u32)(1U)))) << 31U));
|
||
r2 = s2 >> 1U;
|
||
return (multi_return_u32_u32_u32){.arg0=r2, .arg1=r1, .arg2=r0};
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__lsl96(u32 s2, u32 s1, u32 s0) {
|
||
u32 r0 = ((u32)(0U));
|
||
u32 r1 = ((u32)(0U));
|
||
u32 r2 = ((u32)(0U));
|
||
r2 = ((s2 << 1U) | (((s1 & (((u32)(1U)) << 31U))) >> 31U));
|
||
r1 = ((s1 << 1U) | (((s0 & (((u32)(1U)) << 31U))) >> 31U));
|
||
r0 = s0 << 1U;
|
||
return (multi_return_u32_u32_u32){.arg0=r2, .arg1=r1, .arg2=r0};
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__add96(u32 s2, u32 s1, u32 s0, u32 d2, u32 d1, u32 d0) {
|
||
u64 w = ((u64)(0U));
|
||
u32 r0 = ((u32)(0U));
|
||
u32 r1 = ((u32)(0U));
|
||
u32 r2 = ((u32)(0U));
|
||
w = ((u64)(s0)) + ((u64)(d0));
|
||
r0 = ((u32)(w));
|
||
w >>= 32U;
|
||
w += ((u64)(s1)) + ((u64)(d1));
|
||
r1 = ((u32)(w));
|
||
w >>= 32U;
|
||
w += ((u64)(s2)) + ((u64)(d2));
|
||
r2 = ((u32)(w));
|
||
return (multi_return_u32_u32_u32){.arg0=r2, .arg1=r1, .arg2=r0};
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL multi_return_u32_u32_u32 strconv__sub96(u32 s2, u32 s1, u32 s0, u32 d2, u32 d1, u32 d0) {
|
||
u64 w = ((u64)(0U));
|
||
u32 r0 = ((u32)(0U));
|
||
u32 r1 = ((u32)(0U));
|
||
u32 r2 = ((u32)(0U));
|
||
w = ((u64)(s0)) - ((u64)(d0));
|
||
r0 = ((u32)(w));
|
||
w >>= 32U;
|
||
w += ((u64)(s1)) - ((u64)(d1));
|
||
r1 = ((u32)(w));
|
||
w >>= 32U;
|
||
w += ((u64)(s2)) - ((u64)(d2));
|
||
r2 = ((u32)(w));
|
||
return (multi_return_u32_u32_u32){.arg0=r2, .arg1=r1, .arg2=r0};
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL bool strconv__is_digit(u8 x) {
|
||
return (x >= _const_strconv__c_zero && x <= _const_strconv__c_nine) == true;
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL bool strconv__is_space(u8 x) {
|
||
return x == '\t' || x == '\n' || x == '\v' || x == '\f' || x == '\r' || x == ' ';
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL bool strconv__is_exp(u8 x) {
|
||
return (x == 'E' || x == 'e') == true;
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL multi_return_strconv__ParserState_strconv__PrepNumber strconv__parser(string s) {
|
||
int digx = 0;
|
||
strconv__ParserState result = strconv__ParserState__ok;
|
||
bool expneg = false;
|
||
int expexp = 0;
|
||
int i = 0;
|
||
strconv__PrepNumber pn = ((strconv__PrepNumber){.negative = 0,.exponent = 0,.mantissa = 0,});
|
||
for (;;) {
|
||
if (!(i < s.len && u8_is_space(string_at(s, i)))) break;
|
||
i++;
|
||
}
|
||
if (string_at(s, i) == '-') {
|
||
pn.negative = true;
|
||
i++;
|
||
}
|
||
if (string_at(s, i) == '+') {
|
||
i++;
|
||
}
|
||
for (;;) {
|
||
if (!(i < s.len && u8_is_digit(string_at(s, i)))) break;
|
||
if (digx < _const_strconv__digits) {
|
||
pn.mantissa *= 10U;
|
||
pn.mantissa += ((u64)(string_at(s, i) - _const_strconv__c_zero));
|
||
digx++;
|
||
} else if (pn.exponent < 2147483647) {
|
||
pn.exponent++;
|
||
}
|
||
i++;
|
||
}
|
||
if ((i < s.len) && (string_at(s, i) == '.')) {
|
||
i++;
|
||
for (;;) {
|
||
if (!(i < s.len && u8_is_digit(string_at(s, i)))) break;
|
||
if (digx < _const_strconv__digits) {
|
||
pn.mantissa *= 10U;
|
||
pn.mantissa += ((u64)(string_at(s, i) - _const_strconv__c_zero));
|
||
pn.exponent--;
|
||
digx++;
|
||
}
|
||
i++;
|
||
}
|
||
}
|
||
if ((i < s.len) && ((string_at(s, i) == 'e') || (string_at(s, i) == 'E'))) {
|
||
i++;
|
||
if (i < s.len) {
|
||
if (string_at(s, i) == _const_strconv__c_plus) {
|
||
i++;
|
||
} else if (string_at(s, i) == _const_strconv__c_minus) {
|
||
expneg = true;
|
||
i++;
|
||
}
|
||
for (;;) {
|
||
if (!(i < s.len && u8_is_digit(string_at(s, i)))) break;
|
||
if (expexp < 214748364) {
|
||
expexp *= 10;
|
||
expexp += ((int)(string_at(s, i) - _const_strconv__c_zero));
|
||
}
|
||
i++;
|
||
}
|
||
}
|
||
}
|
||
if (expneg) {
|
||
expexp = -expexp;
|
||
}
|
||
pn.exponent += expexp;
|
||
if (pn.mantissa == 0U) {
|
||
if (pn.negative) {
|
||
result = strconv__ParserState__mzero;
|
||
} else {
|
||
result = strconv__ParserState__pzero;
|
||
}
|
||
} else if (pn.exponent > 309) {
|
||
if (pn.negative) {
|
||
result = strconv__ParserState__minf;
|
||
} else {
|
||
result = strconv__ParserState__pinf;
|
||
}
|
||
} else if (pn.exponent < -328) {
|
||
if (pn.negative) {
|
||
result = strconv__ParserState__mzero;
|
||
} else {
|
||
result = strconv__ParserState__pzero;
|
||
}
|
||
}
|
||
if (i == 0 && s.len > 0) {
|
||
return (multi_return_strconv__ParserState_strconv__PrepNumber){.arg0=strconv__ParserState__invalid_number, .arg1=pn};
|
||
}
|
||
return (multi_return_strconv__ParserState_strconv__PrepNumber){.arg0=result, .arg1=pn};
|
||
}
|
||
|
||
VV_LOCAL_SYMBOL u64 strconv__converter(strconv__PrepNumber* pn) {
|
||
int binexp = 92;
|
||
u32 s2 = ((u32)(0U));
|
||
u32 s1 = ((u32)(0U));
|
||
u32 s0 = ((u32)(0U));
|
||
u32 q2 = ((u32)(0U));
|
||
u32 q1 = ((u32)(0U));
|
||
u32 q0 = ((u32)(0U));
|
||
u32 r2 = ((u32)(0U));
|
||
u32 r1 = ((u32)(0U));
|
||
u32 r0 = ((u32)(0U));
|
||
u32 mask28 = ((u32)(((u64)(0xFU)) << 28U));
|
||
u64 result = ((u64)(0U));
|
||
s0 = ((u32)((pn->mantissa & ((u64)(0x00000000FFFFFFFFU)))));
|
||
s1 = ((u32)(pn->mantissa >> 32U));
|
||
s2 = ((u32)(0U));
|
||
for (;;) {
|
||
if (!(pn->exponent > 0)) break;
|
||
multi_return_u32_u32_u32 mr_5500 = strconv__lsl96(s2, s1, s0);
|
||
q2 = mr_5500.arg0;
|
||
q1 = mr_5500.arg1;
|
||
q0 = mr_5500.arg2;
|
||
multi_return_u32_u32_u32 mr_5546 = strconv__lsl96(q2, q1, q0);
|
||
r2 = mr_5546.arg0;
|
||
r1 = mr_5546.arg1;
|
||
r0 = mr_5546.arg2;
|
||
multi_return_u32_u32_u32 mr_5602 = strconv__lsl96(r2, r1, r0);
|
||
s2 = mr_5602.arg0;
|
||
s1 = mr_5602.arg1;
|
||
s0 = mr_5602.arg2;
|
||
multi_return_u32_u32_u32 mr_5658 = strconv__add96(s2, s1, s0, q2, q1, q0);
|
||
s2 = mr_5658.arg0;
|
||
s1 = mr_5658.arg1;
|
||
s0 = mr_5658.arg2;
|
||
pn->exponent--;
|
||
for (;;) {
|
||
if (!(((s2 & mask28)) != 0U)) break;
|
||
multi_return_u32_u32_u32 mr_5781 = strconv__lsr96(s2, s1, s0);
|
||
q2 = mr_5781.arg0;
|
||
q1 = mr_5781.arg1;
|
||
q0 = mr_5781.arg2;
|
||
binexp++;
|
||
s2 = q2;
|
||
s1 = q1;
|
||
s0 = q0;
|
||
}
|
||
}
|
||
for (;;) {
|
||
if (!(pn->exponent < 0)) break;
|
||
for (;;) {
|
||
if (!(!(((s2 & (((u32)(1U)) << 31U))) != 0U))) break;
|
||
multi_return_u32_u32_u32 mr_5928 = strconv__lsl96(s2, s1, s0);
|
||
q2 = mr_5928.arg0;
|
||
q1 = mr_5928.arg1;
|
||
q0 = mr_5928.arg2;
|
||
binexp--;
|
||
s2 = q2;
|
||
s1 = q1;
|
||
s0 = q0;
|
||
}
|
||
q2 = s2 / _const_strconv__c_ten;
|
||
r1 = s2 % _const_strconv__c_ten;
|
||
r2 = ((s1 >> 8U) | (r1 << 24U));
|
||
q1 = r2 / _const_strconv__c_ten;
|
||
r1 = r2 % _const_strconv__c_ten;
|
||
r2 = (((((s1 & ((u32)(0xFFU)))) << 16U) | (s0 >> 16U)) | (r1 << 24U));
|
||
r0 = r2 / _const_strconv__c_ten;
|
||
r1 = r2 % _const_strconv__c_ten;
|
||
q1 = ((q1 << 8U) | (((r0 & ((u32)(0x00FF0000U)))) >> 16U));
|
||
q0 = r0 << 16U;
|
||
r2 = (((s0 & ((u32)(0xFFFFU)))) | (r1 << 16U));
|
||
q0 |= r2 / _const_strconv__c_ten;
|
||
s2 = q2;
|
||
s1 = q1;
|
||
s0 = q0;
|
||
pn->exponent++;
|
||
}
|
||
if (s2 != 0U || s1 != 0U || s0 != 0U) {
|
||
for (;;) {
|
||
if (!(((s2 & mask28)) == 0U)) break;
|
||
multi_return_u32_u32_u32 mr_6663 = strconv__lsl96(s2, s1, s0);
|
||
q2 = mr_6663.arg0;
|
||
q1 = mr_6663.arg1;
|
||
q0 = mr_6663.arg2;
|
||
binexp--;
|
||
s2 = q2;
|
||
s1 = q1;
|
||
s0 = q0;
|
||
}
|
||
}
|
||
int nbit = 7;
|
||
u32 check_round_bit = ((u32)(1U)) << ((u32)(nbit));
|
||
u32 check_round_mask = ((u32)(0xFFFFFFFFU)) << ((u32)(nbit));
|
||
if (((s1 & check_round_bit)) != 0U) {
|
||
if (((s1 & ~check_round_mask)) != 0U) {
|
||
multi_return_u32_u32_u32 mr_7745 = strconv__add96(s2, s1, s0, 0U, check_round_bit, 0U);
|
||
s2 = mr_7745.arg0;
|
||
s1 = mr_7745.arg1;
|
||
s0 = mr_7745.arg2;
|
||
} else {
|
||
if (((s1 & (check_round_bit << ((u32)(1U))))) != 0U) {
|
||
multi_return_u32_u32_u32 mr_7937 = strconv__add96(s2, s1, s0, 0U, check_round_bit, 0U);
|
||
s2 = mr_7937.arg0;
|
||
s1 = mr_7937.arg1;
|
||
s0 = mr_7937.arg2;
|
||
}
|
||
}
|
||
s1 = (s1 & check_round_mask);
|
||
s0 = ((u32)(0U));
|
||
if ((s2 & (mask28 << ((u32)(1U)))) != 0U) {
|
||
multi_return_u32_u32_u32 mr_8141 = strconv__lsr96(s2, s1, s0);
|
||
q2 = mr_8141.arg0;
|
||
q1 = mr_8141.arg1;
|
||
q0 = mr_8141.arg2;
|
||
binexp--;
|
||
s2 = q2;
|
||
s1 = q1;
|
||
s0 = q0;
|
||
}
|
||
}
|
||
binexp += 1023;
|
||
if (binexp > 2046) {
|
||
if (pn->negative) {
|
||
result = _const_strconv__double_minus_infinity;
|
||
} else {
|
||
result = _const_strconv__double_plus_infinity;
|
||
}
|
||
} else if (binexp < 1) {
|
||
if (pn->negative) {
|
||
result = _const_strconv__double_minus_zero;
|
||
} else {
|
||
result = _const_strconv__double_plus_zero;
|
||
}
|
||
} else if (s2 != 0U) {
|
||
u64 q = ((u64)(0U));
|
||
u64 binexs2 = ((u64)(binexp)) << 52U;
|
||
q = (((((u64)((s2 & ~mask28))) << 24U) | ((((u64)(s1)) + ((u64)(128U))) >> 8U)) | binexs2);
|
||
if (pn->negative) {
|
||
q |= (((u64)(1U)) << 63U);
|
||
}
|
||
result = q;
|
||
}
|
||
return result;
|
||
}
|
||
|
||
_option_f64 strconv__atof64(string s) {
|
||
if (s.len == 0) {
|
||
return (_option_f64){ .state=2, .err=_v_error(_SLIT("expected a number found an empty string")), .data={EMPTY_STRUCT_INITIALIZATION} };
|
||
}
|
||
strconv__Float64u res = ((strconv__Float64u){0});
|
||
multi_return_strconv__ParserState_strconv__PrepNumber mr_9209 = strconv__parser(s);
|
||
strconv__ParserState res_parsing = mr_9209.arg0;
|
||
strconv__PrepNumber pn = mr_9209.arg1;
|
||
switch (res_parsing) {
|
||
case strconv__ParserState__ok:
|
||
{
|
||
res.u = strconv__converter((voidptr)&/*qq*/pn);
|
||
break;
|
||
}
|
||
case strconv__ParserState__pzero:
|
||
{
|
||
res.u = _const_strconv__double_plus_zero;
|
||
break;
|
||
}
|
||
case strconv__ParserState__mzero:
|
||
{
|
||
res.u = _const_strconv__double_minus_zero;
|
||
break;
|
||
}
|
||
case strconv__ParserState__pinf:
|
||
{
|
||
res.u = _const_strconv__double_plus_infinity;
|
||
break;
|
||
}
|
||
case strconv__ParserState__minf:
|
||
{
|
||
res.u = _const_strconv__double_minus_infinity;
|
||
break;
|
||
}
|
||
case strconv__ParserState__invalid_number:
|
||
{
|
||
return (_option_f64){ .state=2, .err=_v_error(_SLIT("not a number")), .data={EMPTY_STRUCT_INITIALIZATION} };
|
||
break;
|
||
}
|
||
}
|
||
;
|
||
_option_f64 _t3;
|
||
opt_ok2(&(f64[]) { res.f }, (_option*)(&_t3), sizeof(f64));
|
||
return _t3;
|
||
}
|
||
|
||
f64 strconv__atof_quick(string s) {
|
||
strconv__Float64u f = ((strconv__Float64u){0});
|
||
f64 sign = ((f64)(1.0));
|
||
int i = 0;
|
||
for (;;) {
|
||
if (!(i < s.len && string_at(s, i) == ' ')) break;
|
||
i++;
|
||
}
|
||
if (i < s.len) {
|
||
if (string_at(s, i) == '-') {
|
||
sign = -1.0;
|
||
i++;
|
||
} else if (string_at(s, i) == '+') {
|
||
i++;
|
||
}
|
||
}
|
||
if (string_at(s, i) == 'i' && i + 2 < s.len && string_at(s, i + 1) == 'n' && string_at(s, i + 2) == 'f') {
|
||
if (sign > 0.0) {
|
||
f.u = _const_strconv__double_plus_infinity;
|
||