summaryrefslogtreecommitdiff
path: root/xmake/core
diff options
context:
space:
mode:
authorwtz <[email protected]>2023-07-19 12:35:52 +0800
committerwtz <[email protected]>2023-07-19 12:35:52 +0800
commitf75224a8435d0eb9cdda79f8bc571eeef25a8e33 (patch)
tree278e00b17c8f5558df1c1a21f1204078ea62a58f /xmake/core
parentca83e9a78b7f2d45e833fa705c880867ad2381c6 (diff)
Fix grammar
Diffstat (limited to 'xmake/core')
-rw-r--r--xmake/core/base/interpreter.lua8
-rw-r--r--xmake/core/base/os.lua2
-rw-r--r--xmake/core/base/scheduler.lua6
-rw-r--r--xmake/core/base/scopeinfo.lua4
-rw-r--r--xmake/core/base/task.lua2
-rw-r--r--xmake/core/base/winos.lua4
-rw-r--r--xmake/core/package/package.lua14
-rw-r--r--xmake/core/platform/platform.lua4
-rw-r--r--xmake/core/project/package.lua2
-rw-r--r--xmake/core/project/policy.lua2
-rw-r--r--xmake/core/project/project.lua8
-rw-r--r--xmake/core/project/target.lua14
-rw-r--r--xmake/core/sandbox/modules/import/lib/detect/find_path.lua2
-rw-r--r--xmake/core/sandbox/modules/import/lib/detect/find_program.lua2
-rw-r--r--xmake/core/tool/builder.lua2
-rw-r--r--xmake/core/tool/linker.lua2
-rw-r--r--xmake/core/tool/tool.lua6
-rw-r--r--xmake/core/tool/toolchain.lua8
-rw-r--r--xmake/core/ui/view.lua6
19 files changed, 49 insertions, 49 deletions
diff --git a/xmake/core/base/interpreter.lua b/xmake/core/base/interpreter.lua
index b82b71bcd..bb41831f7 100644
--- a/xmake/core/base/interpreter.lua
+++ b/xmake/core/base/interpreter.lua
@@ -92,7 +92,7 @@ function interpreter._merge_root_scope(root, root_prev, override)
root_prev = root_prev or {}
for scope_kind_and_name, _ in pairs(root or {}) do
-- only merge sub-scope for each kind("target@@xxxx") or __rootkind
- -- we need ignore the sub-root scope e.g. target{} after fetching root scope
+ -- we need to ignore the sub-root scope e.g. target{} after fetching root scope
--
if scope_kind_and_name:find("@@", 1, true) or scope_kind_and_name == "__rootkind" then
local scope_values = root_prev[scope_kind_and_name] or {}
@@ -481,7 +481,7 @@ function interpreter:_handle(scope, deduplicate, enable_filter)
-- filter values
--
- -- @note we need do filter before removing repeat values
+ -- @note we need to do filter before removing repeat values
-- https://github.com/xmake-io/xmake/issues/1732
if enable_filter then
values = self:_filter(values)
@@ -1080,7 +1080,7 @@ function interpreter:api_register_set_values(scope_kind, ...)
extra_config = nil
end
- -- @note we need mark table value as meta object to avoid wrap/unwrap
+ -- @note we need to mark table value as meta object to avoid wrap/unwrap
-- if these values cannot be expanded, especially when there is only one value
--
-- e.g. set_shflags({"-Wl,-exported_symbols_list", exportfile}, {force = true, expand = false})
@@ -1130,7 +1130,7 @@ function interpreter:api_register_add_values(scope_kind, ...)
extra_config = nil
end
- -- @note we need mark table value as meta object to avoid wrap/unwrap
+ -- @note we need to mark table value as meta object to avoid wrap/unwrap
-- if these values cannot be expanded, especially when there is only one value
--
-- e.g. add_shflags({"-Wl,-exported_symbols_list", exportfile}, {force = true, expand = false})
diff --git a/xmake/core/base/os.lua b/xmake/core/base/os.lua
index bb2ebec53..870f4bdf6 100644
--- a/xmake/core/base/os.lua
+++ b/xmake/core/base/os.lua
@@ -771,7 +771,7 @@ function os.execv(program, argv, opt)
local head = file:read("l")
if head and head:startswith("#!") then
-- we cannot run `/bin/sh` directly on msys2/cygwin
- -- because `/bin/sh` is not real file path, maybe we need convert it.
+ -- because `/bin/sh` is not real file path, maybe we need to convert it.
local subhost = os.subhost()
if subhost == "msys" or subhost == "cygwin" then
filename = "sh"
diff --git a/xmake/core/base/scheduler.lua b/xmake/core/base/scheduler.lua
index 61c438f4a..e89c8c604 100644
--- a/xmake/core/base/scheduler.lua
+++ b/xmake/core/base/scheduler.lua
@@ -443,7 +443,7 @@ function scheduler:co_suspend(...)
-- suspend it
local results = table.pack(coroutine.yield(...))
- -- if the current directory has been changed? restore it
+ -- Has the current directory been changed? restore it
local running = assert(self:co_running())
local curdir = self._CO_CURDIR_HASH
local olddir = self._CO_CURDIRS and self._CO_CURDIRS[running] or nil
@@ -451,7 +451,7 @@ function scheduler:co_suspend(...)
os.cd(olddir[2])
end
- -- if the current environments has been changed? restore it
+ -- Has the current environments been changed? restore it
local curenvs = self._CO_CURENVS_HASH
local oldenvs = self._CO_CURENVS and self._CO_CURENVS[running] or nil
if oldenvs and curenvs ~= oldenvs[1] and running:is_isolated() then -- hash changed?
@@ -470,7 +470,7 @@ end
-- sleep some times (ms)
function scheduler:co_sleep(ms)
- -- we need not do sleep
+ -- we don't need to sleep
if ms == 0 then
return true
end
diff --git a/xmake/core/base/scopeinfo.lua b/xmake/core/base/scopeinfo.lua
index cdc43c4bc..d7215917f 100644
--- a/xmake/core/base/scopeinfo.lua
+++ b/xmake/core/base/scopeinfo.lua
@@ -113,7 +113,7 @@ function _instance:_api_set_values(name, ...)
extra_config = nil
end
- -- @note we need mark table value as meta object to avoid wrap/unwrap
+ -- @note we need to mark table value as meta object to avoid wrap/unwrap
-- if these values cannot be expanded, especially when there is only one value
--
-- e.g. target:set("shflags", {"-Wl,-exported_symbols_list", exportfile}, {force = true, expand = false})
@@ -162,7 +162,7 @@ function _instance:_api_add_values(name, ...)
extra_config = nil
end
- -- @note we need mark table value as meta object to avoid wrap/unwrap
+ -- @note we need to mark table value as meta object to avoid wrap/unwrap
-- if these values cannot be expanded, especially when there is only one value
--
-- e.g. target:add("shflags", {"-Wl,-exported_symbols_list", exportfile}, {force = true, expand = false})
diff --git a/xmake/core/base/task.lua b/xmake/core/base/task.lua
index 78b476c2b..8c361463b 100644
--- a/xmake/core/base/task.lua
+++ b/xmake/core/base/task.lua
@@ -150,7 +150,7 @@ function task._translate_menu(menu)
end
end
- -- add common options, we need avoid repeat because the main/build task will be inserted twice
+ -- add common options, we need to avoid repeat because the main/build task will be inserted twice
if not menu._common_options then
for i, v in ipairs(task.common_options()) do
table.insert(options, i, v)
diff --git a/xmake/core/base/winos.lua b/xmake/core/base/winos.lua
index 79c1f9ce0..68815bec8 100644
--- a/xmake/core/base/winos.lua
+++ b/xmake/core/base/winos.lua
@@ -170,7 +170,7 @@ function winos.cmdargv(argv, opt)
local argsfile = os.tmpfile(opt.tmpkey or os.args(argv)) .. ".args.txt"
local f = io.open(argsfile, 'w', {encoding = "ansi"})
if f then
- -- we need split args file to solve `fatal error LNK1170: line in command file contains 131071 or more characters`
+ -- we need to split args file to solve `fatal error LNK1170: line in command file contains 131071 or more characters`
-- @see https://github.com/xmake-io/xmake/issues/812
local idx = 1
while idx <= #argv do
@@ -179,7 +179,7 @@ function winos.cmdargv(argv, opt)
if arg1 then
arg1 = tostring(arg1)
end
- -- we need ensure `/name value` in same line,
+ -- we need to ensure `/name value` in same line,
-- otherwise cl.exe will prompt that the corresponding parameter value cannot be found
--
-- e.g.
diff --git a/xmake/core/package/package.lua b/xmake/core/package/package.lua
index 8c86d0abb..3d7dbb23e 100644
--- a/xmake/core/package/package.lua
+++ b/xmake/core/package/package.lua
@@ -89,7 +89,7 @@ end
function _instance:get(name)
local value = self._INFO:get(name)
if name == "configs" then
- -- we need merge it, because current builtin configs always exists
+ -- we need to merge it, because current builtin configs always exists
if self:base() then
local configs_base = self:base():get("configs")
if configs_base then
@@ -555,7 +555,7 @@ function _instance:is_system()
end
-- is the third-party package? e.g. brew::pcre2/libpcre2-8, conan::OpenSSL/1.0.2n@conan/stable
--- we need install and find package by third-party package manager directly
+-- we need to install and find package by third-party package manager directly
--
function _instance:is_thirdparty()
return self._is_thirdparty
@@ -1066,7 +1066,7 @@ function _instance:build_envs(lazy_loading)
for _, opt in ipairs(table.join(language_menu.options("config"), platform_menu.options("config"))) do
local optname = opt[2]
if type(optname) == "string" then
- -- we need only index it to force load it's value
+ -- we only need to index it to force load it's value
local value = build_envs[optname]
end
end
@@ -1544,7 +1544,7 @@ function _instance:_fetch_tool(opt)
else
fetchinfo = self:find_tool(self:name(), {require_version = opt.require_version,
cachekey = "fetch_package_xmake",
- norun = true, -- we need not run it to check for xmake/packages, @see https://github.com/xmake-io/xmake-repo/issues/66
+ norun = true, -- we don't need to run it to check for xmake/packages, @see https://github.com/xmake-io/xmake-repo/issues/66
system = false, -- we only find it from xmake/packages, @see https://github.com/xmake-io/xmake-repo/pull/2085
force = opt.force})
@@ -1713,7 +1713,7 @@ function _instance:fetch(opt)
-- @see https://github.com/xmake-io/xmake/issues/726
system = nil
elseif self:is_cross() then
- -- we need disable system package for cross-compilation
+ -- we need to disable system package for cross-compilation
system = false
end
@@ -1767,7 +1767,7 @@ function _instance:fetch(opt)
-- save to cache
self._FETCHINFO = fetchinfo
- -- we need update the real version if it's system package
+ -- we need to update the real version if it's system package
-- @see https://github.com/xmake-io/xmake/issues/3333
if is_system and fetchinfo and fetchinfo.version then
local fetch_version = semver.new(fetchinfo.version)
@@ -2585,7 +2585,7 @@ function package.load_from_repository(packagename, packagedir, opt)
-- get interpreter
local interp = package._interpreter()
- -- we need modify plat/arch in description scope at same time
+ -- we need to modify plat/arch in description scope at same time
-- if plat/arch are passed to add_requires.
--
-- @see https://github.com/orgs/xmake-io/discussions/3439
diff --git a/xmake/core/platform/platform.lua b/xmake/core/platform/platform.lua
index cc46b8d41..01d5b0e5e 100644
--- a/xmake/core/platform/platform.lua
+++ b/xmake/core/platform/platform.lua
@@ -66,7 +66,7 @@ end
-- set platform architecture
function _instance:arch_set(arch)
if self:arch() ~= arch then
- -- we need clean the dirty cache if architecture has been changed
+ -- we need to clean the dirty cache if architecture has been changed
platform._PLATFORMS[self:name() .. "_" .. self:arch()] = nil
platform._PLATFORMS[self:name() .. "_" .. arch] = self
self._ARCH = arch
@@ -243,7 +243,7 @@ function _instance:check()
local toolchains_valid = {}
while idx <= num do
local toolchain = toolchains[idx]
- -- we need remove other standalone toolchains if standalone toolchain found
+ -- we need to remove other standalone toolchains if standalone toolchain found
if (standalone and toolchain:is_standalone()) or not toolchain:check() then
table.remove(toolchains, idx)
num = num - 1
diff --git a/xmake/core/project/package.lua b/xmake/core/project/package.lua
index bf1e61ea8..0e16a7e1b 100644
--- a/xmake/core/project/package.lua
+++ b/xmake/core/project/package.lua
@@ -298,7 +298,7 @@ function _instance:_sort_componentdeps(name)
return orderdeps
end
--- we need sort package set keys by this string
+-- we need to sort package set keys by this string
-- @see https://github.com/xmake-io/xmake/pull/2971#issuecomment-1290052169
function _instance:__tostring()
return "<package: " .. self:name() .. ">"
diff --git a/xmake/core/project/policy.lua b/xmake/core/project/policy.lua
index 82944d415..03fc2aaf9 100644
--- a/xmake/core/project/policy.lua
+++ b/xmake/core/project/policy.lua
@@ -70,7 +70,7 @@ function policy.policies()
["preprocessor.linemarkers"] = {description = "Enable linemarkers for preprocessor.", default = true, type = "boolean"},
-- preprocessor configuration for ccache/distcc, we can disable it to avoid cache object file with __DATE__, __TIME__
["preprocessor.gcc.directives_only"] = {description = "Enable -fdirectives-only for gcc preprocessor.", type = "boolean"},
- -- we need enable longpaths when building target or installing package
+ -- we need to enable longpaths when building target or installing package
["platform.longpaths"] = {description = "Enable long paths when building target or installing package on windows.", default = false, type = "boolean"},
-- lock required packages
["package.requires_lock"] = {description = "Enable xmake-requires.lock to lock required packages.", default = false, type = "boolean"},
diff --git a/xmake/core/project/project.lua b/xmake/core/project/project.lua
index 81181c72d..3ac9ab7e2 100644
--- a/xmake/core/project/project.lua
+++ b/xmake/core/project/project.lua
@@ -375,7 +375,7 @@ function project._load_targets()
t._RULES[deprule:name()] = deprule
end
end
- -- we need ignore `@package/rulename`, it will be loaded later
+ -- we need to ignore `@package/rulename`, it will be loaded later
elseif not rulename:match("@.-/") then
return nil, string.format("unknown rule(%s) in target(%s)!", rulename, t:name())
end
@@ -387,7 +387,7 @@ function project._load_targets()
return nil, errors
end
- -- we need call on_load() before building deps/rules,
+ -- we need to call on_load() before building deps/rules,
-- so we can use `target:add("deps", "xxx")` to add deps in on_load
ok, errors = t:_load()
if not ok then
@@ -799,7 +799,7 @@ end
function project.name()
local name = project.get("project")
-- TODO multi project names? we only get the first name now.
- -- and we need improve it in the future.
+ -- and we need to improve it in the future.
if type(name) == "table" then
name = name[1]
end
@@ -1004,7 +1004,7 @@ end
-- get the given toolchain
function project.toolchain(name, opt)
- local toolchain_name = toolchain.parsename(name) -- we need ignore `@packagename`
+ local toolchain_name = toolchain.parsename(name) -- we need to ignore `@packagename`
local info = project._toolchains()[toolchain_name]
if info then
return toolchain.load_withinfo(name, info, opt)
diff --git a/xmake/core/project/target.lua b/xmake/core/project/target.lua
index 3c8c14085..ae3212343 100644
--- a/xmake/core/project/target.lua
+++ b/xmake/core/project/target.lua
@@ -273,7 +273,7 @@ end
function _instance:_invalidate(name)
self._CACHEID = self._CACHEID + 1
self._POLICIES = nil
- -- we need flush the source files cache if target/files are modified, e.g. `target:add("files", "xxx.c")`
+ -- we need to flush the source files cache if target/files are modified, e.g. `target:add("files", "xxx.c")`
if name == "files" then
self._SOURCEFILES = nil
elseif name == "deps" then
@@ -1140,7 +1140,7 @@ function _instance:autogenfile(sourcefile, opt)
-- objectfile: project/build/.objs/xxxx/../../xxx.c will be out of range for objectdir
-- autogenfile: project/build/.gens/xxxx/../../xxx.c will be out of range for autogendir
--
- -- we need replace '..' to '__' in this case
+ -- we need to replace '..' with '__' in this case
--
if path.is_absolute(relativedir) and os.host() == "windows" then
-- remove C:\\ and whitespaces and fix long path issue
@@ -1539,7 +1539,7 @@ function _instance:sourcefiles()
pattern = pattern:sub(3)
end
pattern = path.pattern(pattern)
- -- we need match whole pattern, https://github.com/xmake-io/xmake/issues/3523
+ -- we need to match whole pattern, https://github.com/xmake-io/xmake/issues/3523
if sourcefile:match("^" .. pattern .. "$") then
return true
end
@@ -1574,14 +1574,14 @@ function _instance:objectfiles()
local batchcount = 0
local sourcebatches = self:sourcebatches()
local orderkeys = table.keys(sourcebatches)
- table.sort(orderkeys) -- @note we need guarantee the order of objectfiles for depend.is_changed() and etc.
+ table.sort(orderkeys) -- @note we need to guarantee the order of objectfiles for depend.is_changed() and etc.
for _, k in ipairs(orderkeys) do
local sourcebatch = sourcebatches[k]
table.join2(objectfiles, sourcebatch.objectfiles)
batchcount = batchcount + 1
end
- -- some object files may be repeat and appear link errors if multi-batches exists, so we need remove all repeat object files
+ -- some object files may be repeat and appear link errors if multi-batches exists, so we need to remove all repeat object files
-- e.g. add_files("src/*.c", {rules = {"rule1", "rule2"}})
local deduplicate = batchcount > 1
@@ -1810,7 +1810,7 @@ function _instance:dependfile(objectfile)
-- originfile: project/build/.objs/xxxx/../../xxx.c will be out of range for objectdir
--
- -- we need replace '..' to '__' in this case
+ -- we need to replace '..' to '__' in this case
--
relativedir = relativedir:gsub("%.%.", "__")
@@ -2194,7 +2194,7 @@ function _instance:tool(toolkind)
if program and not toolname then
local pos = program:find('@', 1, true)
if pos then
- -- we need ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
+ -- we need to ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
-- https://github.com/xmake-io/xmake/issues/2853
local prefix = program:sub(1, pos - 1)
if prefix and not prefix:find("[/\\]") then
diff --git a/xmake/core/sandbox/modules/import/lib/detect/find_path.lua b/xmake/core/sandbox/modules/import/lib/detect/find_path.lua
index 78b9f4c9d..0f79c9825 100644
--- a/xmake/core/sandbox/modules/import/lib/detect/find_path.lua
+++ b/xmake/core/sandbox/modules/import/lib/detect/find_path.lua
@@ -37,7 +37,7 @@ function sandbox_lib_detect_find_path._find(filedir, name)
if results and #results > 0 then
local filepath = results[1]
if filepath then
- -- we need translate name first, https://github.com/xmake-io/xmake-repo/issues/1315
+ -- we need to translate name first, https://github.com/xmake-io/xmake-repo/issues/1315
local p = filepath:lastof(path.pattern(path.translate(name)))
if p then
filepath = path.translate(filepath:sub(1, p - 1))
diff --git a/xmake/core/sandbox/modules/import/lib/detect/find_program.lua b/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
index a4e3c2849..c0755cbf3 100644
--- a/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
+++ b/xmake/core/sandbox/modules/import/lib/detect/find_program.lua
@@ -84,7 +84,7 @@ function sandbox_lib_detect_find_program._check(program, opt)
end
elseif os.subhost() == "msys" and os.isfile(program) and os.filesize(program) < 256 then
-- only a sh script on msys2? e.g. c:/msys64/usr/bin/7z
- -- we need use sh to wrap it, otherwise os.exec cannot run it
+ -- we need to use sh to wrap it, otherwise os.exec cannot run it
program = "sh " .. program
findname = program
end
diff --git a/xmake/core/tool/builder.lua b/xmake/core/tool/builder.lua
index 9070cca85..3eda6ce6a 100644
--- a/xmake/core/tool/builder.lua
+++ b/xmake/core/tool/builder.lua
@@ -393,7 +393,7 @@ end
-- preprocess flags
function builder:_preprocess_flags(flags)
- -- remove repeat by right direction, because we need consider links/deps order
+ -- remove repeat by right direction, because we need to consider links/deps order
-- @note https://github.com/xmake-io/xmake/issues/1240
local unique = {}
local count = #flags
diff --git a/xmake/core/tool/linker.lua b/xmake/core/tool/linker.lua
index aa7b1bb8c..3048cd955 100644
--- a/xmake/core/tool/linker.lua
+++ b/xmake/core/tool/linker.lua
@@ -114,7 +114,7 @@ function linker.load(targetkind, sourcekinds, target)
-- wrap sourcekinds first
sourcekinds = table.wrap(sourcekinds)
if #sourcekinds == 0 then
- -- we need detect the sourcekinds of all deps if the current target has not any source files
+ -- we need to detect the sourcekinds of all deps if the current target has not any source files
for _, dep in ipairs(target:orderdeps()) do
table.join2(sourcekinds, dep:sourcekinds())
end
diff --git a/xmake/core/tool/tool.lua b/xmake/core/tool/tool.lua
index 46e3e664b..45ac78a08 100644
--- a/xmake/core/tool/tool.lua
+++ b/xmake/core/tool/tool.lua
@@ -41,7 +41,7 @@ function _instance.new(kind, name, program, plat, arch, toolchain_inst)
-- import "core.tools.xxx"
local toolclass = nil
if os.isfile(path.join(os.programdir(), "modules", "core", "tools", name .. ".lua")) then
- toolclass = import("core.tools." .. name, {nocache = true}) -- @note we need create a tool instance with unique toolclass context (_g)
+ toolclass = import("core.tools." .. name, {nocache = true}) -- @note we need to create a tool instance with unique toolclass context (_g)
end
-- not found?
@@ -202,7 +202,7 @@ function _instance:_sysflags(toolkind, flagkind)
table.insert(sourceflags, flagkind)
table.insert(sourceflags, "mxxflags")
else
- -- flagkind may be ldflags, we need ignore it
+ -- flagkind may be ldflags, we need to ignore it
-- and we should use more precise flagkind, e.g. rcldflags instead of ldflags
end
end
@@ -255,7 +255,7 @@ function tool.load(kind, opt)
if program then
local pos = program:find('@', 1, true)
if pos then
- -- we need ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
+ -- we need to ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
-- https://github.com/xmake-io/xmake/issues/2853
local prefix = program:sub(1, pos - 1)
if prefix and not prefix:find("[/\\]") then
diff --git a/xmake/core/tool/toolchain.lua b/xmake/core/tool/toolchain.lua
index b230bf674..4831bce5c 100644
--- a/xmake/core/tool/toolchain.lua
+++ b/xmake/core/tool/toolchain.lua
@@ -345,7 +345,7 @@ function _instance:_on_load()
return on_load
end
--- do load, @note we need load it repeatly for each architectures
+-- do load, @note we need to load it repeatly for each architectures
function _instance:_load()
local info = self:info()
if not info:get("__loaded") and not info:get("__loading") then
@@ -456,7 +456,7 @@ function _instance:_checktool(toolkind, toolpath)
if toolpath then
local pos = toolpath:find('@', 1, true)
if pos then
- -- we need ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
+ -- we need to ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
-- https://github.com/xmake-io/xmake/issues/2853
local prefix = toolpath:sub(1, pos - 1)
if prefix and not prefix:find("[/\\]") then
@@ -698,7 +698,7 @@ function toolchain.load_fromfile(filepath, opt)
local scope_opt = {interpreter = toolchain._interpreter(), deduplicate = true, enable_filter = true}
local info = scopeinfo.new("toolchain", fileinfo.info, scope_opt)
local instance = toolchain.load_withinfo(fileinfo.name, info, opt)
- -- we need skip check
+ -- we need to skip check
instance._CHECKED = true
return instance
end
@@ -753,7 +753,7 @@ function toolchain.tool(toolchains, toolkind, opt)
if program and type(program) == "string" then
local pos = program:find('@', 1, true)
if pos then
- -- we need ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
+ -- we need to ignore valid path with `@`, e.g. /usr/local/opt/[email protected]/bin/go
-- https://github.com/xmake-io/xmake/issues/2853
local prefix = program:sub(1, pos - 1)
if prefix and not prefix:find("[/\\]") then
diff --git a/xmake/core/ui/view.lua b/xmake/core/ui/view.lua
index 5655aedc7..45a46c6f6 100644
--- a/xmake/core/ui/view.lua
+++ b/xmake/core/ui/view.lua
@@ -305,7 +305,7 @@ end
-- set state
function view:state_set(name, enable)
- -- state is not changed?
+ -- state not changed?
enable = enable or false
if self:state(name) == enable then
return self
@@ -324,7 +324,7 @@ end
-- set option
function view:option_set(name, enable)
- -- state is not changed?
+ -- state not changed?
enable = enable or false
if self:option(name) == enable then
return
@@ -444,7 +444,7 @@ function view:_mark_resize()
-- need resize it
self:state_set("resize", true)
- -- @note we need trigger on_resize() of the root view and pass it to this subview
+ -- @note we need to trigger on_resize() of the root view and pass it to this subview
if self:parent() then
self:parent():invalidate(true)
end