checker: more default field fixes
parent
925f1781b3
commit
ea31f75098
|
@ -11,7 +11,7 @@ const (
|
||||||
|
|
||||||
pub struct TempFileOptions {
|
pub struct TempFileOptions {
|
||||||
path string = os.temp_dir()
|
path string = os.temp_dir()
|
||||||
pattern string = ''
|
pattern string
|
||||||
}
|
}
|
||||||
|
|
||||||
// temp_file returns an uniquely named, open, writable, `os.File` and it's path
|
// temp_file returns an uniquely named, open, writable, `os.File` and it's path
|
||||||
|
@ -49,7 +49,7 @@ pub fn temp_file(tfo TempFileOptions) ?(os.File, string) {
|
||||||
|
|
||||||
pub struct TempDirOptions {
|
pub struct TempDirOptions {
|
||||||
path string = os.temp_dir()
|
path string = os.temp_dir()
|
||||||
pattern string = ''
|
pattern string
|
||||||
}
|
}
|
||||||
|
|
||||||
// temp_dir returns an uniquely named, writable, directory path
|
// temp_dir returns an uniquely named, writable, directory path
|
||||||
|
|
|
@ -5,7 +5,7 @@ struct Stack {
|
||||||
null_element int = C.INT_MIN
|
null_element int = C.INT_MIN
|
||||||
mut:
|
mut:
|
||||||
elements []int
|
elements []int
|
||||||
size int = 0
|
size int
|
||||||
}
|
}
|
||||||
|
|
||||||
fn (stack Stack) is_null(data int) bool {
|
fn (stack Stack) is_null(data int) bool {
|
||||||
|
@ -44,7 +44,7 @@ fn (mut stack Stack) push(item int) {
|
||||||
struct BTree {
|
struct BTree {
|
||||||
mut:
|
mut:
|
||||||
all_tags []Tag
|
all_tags []Tag
|
||||||
node_pointer int = 0
|
node_pointer int
|
||||||
childrens [][]int
|
childrens [][]int
|
||||||
parents []int
|
parents []int
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,11 +7,11 @@ mut:
|
||||||
current_tag &Tag
|
current_tag &Tag
|
||||||
open_tag bool = false
|
open_tag bool = false
|
||||||
open_code bool = false
|
open_code bool = false
|
||||||
open_string int = 0
|
open_string int
|
||||||
open_comment bool = false
|
open_comment bool = false
|
||||||
is_attribute bool = false
|
is_attribute bool = false
|
||||||
opened_code_type string = ''
|
opened_code_type string
|
||||||
line_count int = 0
|
line_count int
|
||||||
lexeme_builder string
|
lexeme_builder string
|
||||||
code_tags map[string]bool = {
|
code_tags map[string]bool = {
|
||||||
'script': true
|
'script': true
|
||||||
|
|
|
@ -15,7 +15,7 @@ mut:
|
||||||
attributes map[string]string // attributes will be like map[name]value
|
attributes map[string]string // attributes will be like map[name]value
|
||||||
last_attribute string
|
last_attribute string
|
||||||
parent &Tag = C.NULL
|
parent &Tag = C.NULL
|
||||||
position_in_parent int = 0
|
position_in_parent int
|
||||||
closed bool = false
|
closed bool = false
|
||||||
close_type CloseTagType = .in_name
|
close_type CloseTagType = .in_name
|
||||||
}
|
}
|
||||||
|
|
|
@ -61,7 +61,7 @@ pub struct MT19937RNG {
|
||||||
mut:
|
mut:
|
||||||
state []u64 = calculate_state(util.time_seed_array(2), mut []u64{len: nn})
|
state []u64 = calculate_state(util.time_seed_array(2), mut []u64{len: nn})
|
||||||
mti int = nn
|
mti int = nn
|
||||||
next_rnd u32 = 0
|
next_rnd u32
|
||||||
has_next bool = false
|
has_next bool = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -302,7 +302,7 @@ pub mut:
|
||||||
|
|
||||||
// char classes storage
|
// char classes storage
|
||||||
cc []CharClass // char class list
|
cc []CharClass // char class list
|
||||||
cc_index int = 0 // index
|
cc_index int // index
|
||||||
|
|
||||||
// state index
|
// state index
|
||||||
state_stack_index int= -1
|
state_stack_index int= -1
|
||||||
|
@ -310,7 +310,7 @@ pub mut:
|
||||||
|
|
||||||
|
|
||||||
// groups
|
// groups
|
||||||
group_count int = 0 // number of groups in this regex struct
|
group_count int // number of groups in this regex struct
|
||||||
groups []int // groups index results
|
groups []int // groups index results
|
||||||
group_max_nested int = 3 // max nested group
|
group_max_nested int = 3 // max nested group
|
||||||
group_max int = 8 // max allowed number of different groups
|
group_max int = 8 // max allowed number of different groups
|
||||||
|
@ -321,10 +321,10 @@ pub mut:
|
||||||
group_map map[string]int // groups names map
|
group_map map[string]int // groups names map
|
||||||
|
|
||||||
// flags
|
// flags
|
||||||
flag int = 0 // flag for optional parameters
|
flag int // flag for optional parameters
|
||||||
|
|
||||||
// Debug/log
|
// Debug/log
|
||||||
debug int = 0 // enable in order to have the unroll of the code 0 = NO_DEBUG, 1 = LIGHT 2 = VERBOSE
|
debug int // enable in order to have the unroll of the code 0 = NO_DEBUG, 1 = LIGHT 2 = VERBOSE
|
||||||
log_func FnLog = simple_log // log function, can be customized by the user
|
log_func FnLog = simple_log // log function, can be customized by the user
|
||||||
query string = "" // query string
|
query string = "" // query string
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,8 +8,8 @@ import regex
|
||||||
struct TestItem {
|
struct TestItem {
|
||||||
src string
|
src string
|
||||||
q string
|
q string
|
||||||
s int = 0
|
s int
|
||||||
e int = 0
|
e int
|
||||||
}
|
}
|
||||||
|
|
||||||
const(
|
const(
|
||||||
|
|
|
@ -7,7 +7,7 @@ const (
|
||||||
|
|
||||||
struct Counter {
|
struct Counter {
|
||||||
mut:
|
mut:
|
||||||
counter u64 = 0
|
counter u64
|
||||||
}
|
}
|
||||||
|
|
||||||
// without proper syncronization this would fail
|
// without proper syncronization this would fail
|
||||||
|
|
|
@ -3,7 +3,7 @@ module vtest
|
||||||
import os
|
import os
|
||||||
|
|
||||||
pub struct FilterVTestConfig {
|
pub struct FilterVTestConfig {
|
||||||
basepath string = ''
|
basepath string
|
||||||
fix_slashes bool = true
|
fix_slashes bool = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -230,8 +230,8 @@ struct SimpleTcpClientConfig {
|
||||||
host string = 'static.dev'
|
host string = 'static.dev'
|
||||||
path string = '/'
|
path string = '/'
|
||||||
agent string = 'v/net.tcp.v'
|
agent string = 'v/net.tcp.v'
|
||||||
headers string = ''
|
headers string
|
||||||
content string = ''
|
content string
|
||||||
}
|
}
|
||||||
|
|
||||||
fn simple_tcp_client(config SimpleTcpClientConfig) ?string {
|
fn simple_tcp_client(config SimpleTcpClientConfig) ?string {
|
||||||
|
|
Loading…
Reference in New Issue