1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

vlib: remove deprecated map{} usages as well as deprecated functions (#11035)

This commit is contained in:
Daniel Däschle
2021-08-04 11:44:41 +02:00
committed by GitHub
parent b870f7a6f1
commit 800c0e5092
142 changed files with 410 additions and 501 deletions

View File

@@ -134,7 +134,7 @@ fn (vd VDoc) render_search_index(out Output) {
}
fn (mut vd VDoc) render_static_html(out Output) {
vd.assets = map{
vd.assets = {
'doc_css': vd.get_resource(css_js_assets[0], out)
'normalize_css': vd.get_resource(css_js_assets[1], out)
'doc_js': vd.get_resource(css_js_assets[2], out)

View File

@@ -17,15 +17,15 @@ const (
excluded_dirs = ['cache', 'vlib']
supported_vcs_systems = ['git', 'hg']
supported_vcs_folders = ['.git', '.hg']
supported_vcs_update_cmds = map{
supported_vcs_update_cmds = {
'git': 'git pull'
'hg': 'hg pull --update'
}
supported_vcs_install_cmds = map{
supported_vcs_install_cmds = {
'git': 'git clone --depth=1'
'hg': 'hg clone'
}
supported_vcs_outdated_steps = map{
supported_vcs_outdated_steps = {
'git': ['git fetch', 'git rev-parse @', 'git rev-parse @{u}']
'hg': ['hg incoming']
}
@@ -467,7 +467,7 @@ fn resolve_dependencies(name string, module_path string, module_names []string)
fn parse_vmod(data string) Vmod {
keys := ['name', 'version', 'deps']
mut m := map{
mut m := {
'name': ''
'version': ''
'deps': ''

View File

@@ -12,7 +12,7 @@ const (
support_color = term.can_show_color_on_stderr() && term.can_show_color_on_stdout()
ecode_timeout = 101
ecode_memout = 102
ecode_details = map{
ecode_details = {
-1: 'worker executable not found'
101: 'too slow'
102: 'too memory hungry'