tvl-depot/users/flokli/presentations/2023-09-09-nixcon-tvix/cppnix-example-lexer.cpp
Florian Klink b8ef3e5263 feat(users/flokli): add NixCon 2023 presentation
This adds the materials for the talk held at NixCon 2023, Darmstadt.

It seems it's not really possible to export a PDF out of this,
at least I couldn't get reveal-md to do it properly.

The video recordings live on
https://media.ccc.de/v/nixcon-2023-35254-tvix and
https://www.youtube.com/watch?v=j67prAPYScY .

Change-Id: Id27dc8c8637ffd455981141383c54d8d1484679e
Reviewed-on: https://cl.tvl.fyi/c/depot/+/9750
Reviewed-by: flokli <flokli@flokli.de>
Tested-by: BuildkiteCI
2023-10-16 11:49:06 +00:00

13 lines
364 B
C++

attrpath
: attrpath '.' attr {
$$ = $1; $1->push_back(AttrName(data->symbols.create($3)));
}
| attrpath '.' string_attr
{ $$ = $1;
ExprString * str = dynamic_cast<ExprString *>($3);
if (str) {
$$->push_back(AttrName(data->symbols.create(str->s)));
delete str;
} else
$$->push_back(AttrName($3));
}