aboutsummaryrefslogtreecommitdiff
path: root/lib/parse.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/parse.js')
-rw-r--r--lib/parse.js24
1 files changed, 19 insertions, 5 deletions
diff --git a/lib/parse.js b/lib/parse.js
index 78311f89..84b14439 100644
--- a/lib/parse.js
+++ b/lib/parse.js
@@ -1342,6 +1342,20 @@ function parse($TEXT, options) {
var start = S.token;
var type = start.type;
var name = as_property_name();
+ if (is("punc", "(")) {
+ var func_start = S.token;
+ var func = function_(AST_Function);
+ func.start = func_start;
+ func.end = prev();
+ a.push(new AST_ObjectKeyVal({
+ start: start,
+ quote: start.quote,
+ key: "" + name,
+ value: func,
+ end: prev(),
+ }));
+ continue;
+ }
if (!is("punc", ":") && type == "name") switch (name) {
case "get":
a.push(new AST_ObjectGetter({
@@ -1379,11 +1393,11 @@ function parse($TEXT, options) {
}
expect(":");
a.push(new AST_ObjectKeyVal({
- start : start,
- quote : start.quote,
- key : "" + name,
- value : expression(false),
- end : prev()
+ start: start,
+ quote: start.quote,
+ key: "" + name,
+ value: expression(false),
+ end: prev(),
}));
}
next();
gnu/packages/statistics.scm, gnu/packages/stenography.scm, gnu/packages/sync.scm, gnu/packages/syncthing.scm, gnu/packages/synergy.scm, gnu/packages/telephony.scm, gnu/packages/terminals.scm, gnu/packages/tex.scm, gnu/packages/texinfo.scm, gnu/packages/text-editors.scm, gnu/packages/textutils.scm, gnu/packages/time.scm, gnu/packages/tmux.scm, gnu/packages/tor.scm, gnu/packages/toys.scm, gnu/packages/version-control.scm, gnu/packages/video.scm, gnu/packages/vim.scm, gnu/packages/virtualization.scm, gnu/packages/vlang.scm, gnu/packages/vnc.scm, gnu/packages/vpn.scm, gnu/packages/web-browsers.scm, gnu/packages/web.scm, gnu/packages/wireservice.scm, gnu/packages/wm.scm, gnu/packages/wxwidgets.scm, gnu/packages/xdisorg.scm, gnu/packages/xml.scm, gnu/packages/xorg.scm, tests/lint.scm: Remove trailing ".git" from 'git-reference' URL. Ludovic Courtès 2020-06-29gnu: sparse: Update to 0.6.2....* gnu/packages/c.scm (sparse): Update to 0.6.2. Tobias Geerinckx-Rice 2020-06-25gnu: Add unifdef....* gnu/packages/c.scm (unifdef): New variable. Maxim Cournoyer 2020-06-12gnu: Add liblogging....* gnu/packages/c.scm (liblogging): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Katherine Cox-Buday 2020-06-12gnu: Add libfastjson....* gnu/packages/c.scm (libfastjson): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Katherine Cox-Buday 2020-06-12gnu: Add libestr....* gnu/packages/c.scm (libestr): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Katherine Cox-Buday 2020-05-30gnu: libhx: Update to 3.25....* gnu/packages/c.scm (libhx): Update to 3.25. Tobias Geerinckx-Rice 2020-05-27gnu: Add packcc....* gnu/packages/c.scm (packcc): New public variable. Marius Bakke 2020-05-14gnu: Add sparse....* gnu/packages/c.scm (sparse): New variable. Jan (janneke) Nieuwenhuizen 2020-02-19gnu: libbytesize: Update to 2.2....* gnu/packages/c.scm (libbytesize): Update to 2.2. Tobias Geerinckx-Rice 2019-12-03gnu: tcc: Add search paths and drop the wrapper....* gnu/packages/c.scm (tcc): Add native search paths. (tcc-wrapper): Remove variable. Andreas Enge 2019-11-26gnu: Add libhx....* gnu/packages/c.scm (libhx): New variable. Signed-off-by: Ludovic Courtès <ludo@gnu.org> Guillaume Le Vaillant 2019-11-22gnu: libbytesize: Update to 2.1....* gnu/packages/c.scm (libbytesize): Update to 2.1. [source, remove]: Remove msgmerge reproducibility work-around. [inputs]: Use pcre@2. Tobias Geerinckx-Rice