我在这里有一行脚本供审查,我注意到带有值的变量声明:
function readConfig {
Param([string]$fileName)
$config = @{}
Get-Content $fileName | Where-Object {
$_ -like '*=*'
} | ForEach-Object {
$key, $value = $_ -split '\s*=\s*', 2
$config[$key] = $value
}
return $config
}
Run Code Online (Sandbox Code Playgroud)
我想知道@{}in是什么意思$config = @{}?