Skip to content

Commit 883f40f

Browse files
authored
reference: Refactor docs about structure (#195)
* reference: Update FALSE Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Refactor NULL Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Add TURE Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Update structure items Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Rename the item Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Remove python-specific items Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Add $ and remove python-specific items Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Fix the style Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Fix style Signed-off-by: Ce Gao <ce.gao@outlook.com> * reference: Fix style Signed-off-by: Ce Gao <ce.gao@outlook.com>
1 parent 76afe79 commit 883f40f

File tree

25 files changed

+97
-265
lines changed

25 files changed

+97
-265
lines changed
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
category: Structure
2+
subcategory:
3+
description: "
4+
Reserved word representing the logical value \"FALSE\".
5+
"
6+
syntax: ""
7+
related:
8+
- TRUE

examples/reference/False/.property.yml

Lines changed: 0 additions & 9 deletions
This file was deleted.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
category: Structure
2+
subcategory:
3+
description: " NULL is often used to represent the absences of a value.
4+
"
5+
syntax: "x = NULL"

examples/reference/None/.property.yml

Lines changed: 0 additions & 12 deletions
This file was deleted.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
category: Structure
2+
subcategory:
3+
description: "
4+
Reserved word representing the logical value \"TRUE\".
5+
"
6+
syntax: " x = TRUE\n y ==TRUE"
7+
related:
8+
- FALSE

examples/reference/True/.property.yml

Lines changed: 0 additions & 11 deletions
This file was deleted.

examples/reference/add_library/.property.yml

Lines changed: 0 additions & 10 deletions
This file was deleted.

examples/reference/addassign/.property.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,19 @@
11
category: Structure
22
subcategory:
33
description: "
4-
Assigns a value to a variable. The \"=\" sign does not mean \"equals\", but is used to place data within a variable. The \"=\" operator is formally called the assignment operator. There are many different types of variables (int, floats, strings, etc.) and the assignment operator can only assign values which are the same type as the variable it is assigning. For example, if the variable is of type <b>int</b>, the value must also be an <b>int</b>.
4+
There are three different assignment operators: two of them have leftwards and rightwards forms.<br />
5+
<br />
6+
The operators <- and = assign into the environment in which they are evaluated. The operator <- can be used anywhere, whereas the operator = is only allowed at the top level (e.g., in the complete expression typed at the command prompt) or as one of the subexpressions in a braced list of expressions.<br />
7+
<br />
8+
The operators <<- and ->> are normally only used in functions, and cause a search to be made through parent environments for an existing definition of the variable being assigned. If such a variable is found (and its binding is not locked) then its value is redefined, otherwise assignment takes place in the global environment. Note that their semantics differ from that in the S language, but are useful in conjunction with the scoping rules of R. See ‘The R Language Definition’ manual for further details and examples.<br />
9+
<br />
10+
In all the assignment operator expressions, x can be a name or an expression defining a part of an object to be replaced (e.g., z[[1]]). A syntactic name does not need to be quoted, though it can be (preferably by backticks).<br />
11+
<br />
12+
The leftwards forms of assignment <- = <<- group right to left, the other from left to right.<br />
513
"
6-
syntax: "<c>var</c> = <c>value</c>"
14+
syntax: "x <- value\nx <<- value\nvalue -> x\nvalue ->> x\n\nx = value"
715
parameters:
8-
- label: 'var'
9-
description: "any valid variable name"
16+
- label: 'x'
17+
description: "a variable name (possibly quoted)."
1018
- label: 'value'
11-
description: "any value of the same type as the variable. For example, if the variable is of type \"int\", the value must also be an int"
12-
related:
13-
- addassign
14-
- subtractassign
19+
description: "a value to be assigned to x."

examples/reference/colon/.property.yml

Lines changed: 0 additions & 14 deletions
This file was deleted.

0 commit comments

Comments
 (0)