aboutsummaryrefslogtreecommitdiff
path: root/doc/spec.md
diff options
context:
space:
mode:
authoralandonovan <adonovan@google.com>2021-01-21 17:58:09 -0500
committerGitHub <noreply@github.com>2021-01-21 17:58:09 -0500
commitcea917ab6e0f5d6548d516f8c30e197d63db9baa (patch)
tree899c6a22cc01630d69f93cb014987daed5e98208 /doc/spec.md
parentfb04d37e5d7fe9cdcc59adfcfd94d1863ac6cb38 (diff)
downloadstarlark-go-cea917ab6e0f5d6548d516f8c30e197d63db9baa.tar.gz
resolver: make -nesteddef and -lambda always on (#328)
See https://github.com/bazelbuild/starlark/pull/145 for spec changes. Updates https://github.com/bazelbuild/starlark/issues/20
Diffstat (limited to 'doc/spec.md')
-rw-r--r--doc/spec.md21
1 files changed, 2 insertions, 19 deletions
diff --git a/doc/spec.md b/doc/spec.md
index 15be009..2b83ffa 100644
--- a/doc/spec.md
+++ b/doc/spec.md
@@ -2518,13 +2518,6 @@ def twice(x):
twice = lambda x: x * 2
```
-<b>Implementation note:</b>
-The Go implementation of Starlark requires the `-lambda` flag
-to enable support for lambda expressions.
-The Java implementation does not support them.
-See Google Issue b/36358844.
-
-
## Statements
```grammar {.good}
@@ -2739,12 +2732,6 @@ current module.
<!-- this is too implementation-oriented; it's not a spec. -->
-<b>Implementation note:</b>
-The Go implementation of Starlark requires the `-nesteddef`
-flag to enable support for nested `def` statements.
-The Java implementation does not permit a `def` expression to be
-nested within the body of another function.
-
### Return statements
@@ -4244,14 +4231,10 @@ applications to mimic the Bazel dialect more closely. Our goal is
eventually to eliminate all such differences on a case-by-case basis.
See [Starlark spec issue 20](https://github.com/bazelbuild/starlark/issues/20).
-* Integers are represented with infinite precision.
-* Integer arithmetic is exact.
-* String interpolation supports the `[ioxXc]` conversions.
-* `def` statements may be nested (option: `-nesteddef`).
-* `lambda` expressions are supported (option: `-lambda`).
+* String interpolation supports the `[ixXc]` conversions.
* String elements are bytes.
* Non-ASCII strings are encoded using UTF-8.
-* Strings support octal and hex byte escapes.
+* Strings support hex byte escapes.
* Strings have the additional methods `elem_ords`, `codepoint_ords`, and `codepoints`.
* The `chr` and `ord` built-in functions are supported.
* The `set` built-in function is provided (option: `-set`).