2.51 gn help string_replace 英文 中文 状态:todo 2.52 gn help string_split 英文 中文 状态:todo 2.53 gn help template 英文 中文 状态:todo 2.54 gn help tool 英文 中文 状态:todo 2.55 gn help toolchain 英文 中文 状态:todo 2.56 gn help write_file 英文 中文 状态:todo 2.57 gn help current_cpu...
string_replace: Replaces substring in the given string. string_split: Split string into a list of strings. template: Define a template rule. tool: Specify arguments to a toolchain tool. toolchain: Defines a toolchain. write_file: Write a file to disk. Built-in predefined variables (type gn...
executable("hello") {...configs -= [ "//build:no_exceptions" ] # Remove global default.configs += [ "//build:exceptions" ] # Replace with a different one.print("The configs for the target $target_name are $configs")##打印,用来检查 } 使用参数 通过gn help buildargs可以学习参数是如何...
crate_name: [string] The name for the compiled crate. crate_root: [string] The root source file for a binary or library. crate_type: [string] The type of linkage to use on a shared_library. data: [file list] Runtime data file dependencies. data_deps: [label list] Non-linked depend...
String literals字符串字面量 A string literal represents a string value consisting of the quoted characters with possible escape sequences and variable expansions. string = `"` { char | escape | expansion } `"` . escape = `\` ( "$" | `"` | char ) . ...
JSON schema for output: [ { "name": variable_name, "current": { "value": overridden_value, "file": file_name, "line": line_no }, "default": { "value": default_value, "file": file_name, "line": line_no }, "comment": comment_string }, ... ] ...
string_replace: Replaces substring in the given string. string_split: Split string into a list of strings. template: Define a template rule. tool: Specify arguments to a toolchain tool. toolchain: Defines a toolchain. write_file: Write a file to disk. Built-in predefined variables current_...
executable("hello") {...configs -= [ "//build:no_exceptions" ] # Remove global default.configs += [ "//build:exceptions" ] # Replace with a different one.print("The configs for the target $target_name are $configs")##打印,用来检查 } 使用参数 通过gn help buildargs可以学习参数是如何...
mylist=[0,1,2,"some string"] 列表支持连接操作,可以使用’+’ 和 '+='操作符。空值不能连接列表,为增加一个列表成员,列表长度至少为1。 列表还支持删除操作,可以使用’-’ 和 '-='操作符。删除操作会从左边的列表中删除右边的列表中的所有成员。删除不存在的成员时会报错,这会避免笔误,也能检测尝试删...
executable("hello") {...configs -= [ "//build:no_exceptions" ] # Remove global default.configs += [ "//build:exceptions" ] # Replace with a different one.print("The configs for the target $target_name are $configs")##打印,用来检查 ...