bison-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[WIP PATCH for Dlang support] d: token constructors


From: Adela Vais
Subject: [WIP PATCH for Dlang support] d: token constructors
Date: Wed, 20 Jan 2021 00:54:00 +0200

Hello,

I need some help with the patches I am writing.
I talked today with Akim and I am sending the WIP patches I have as
attachments. If it is easier, here is a Github link [1].
Thank you, Akim, in advance, for your help. After yyaction() works
properly, I can continue modifying the patches. I already expect some
problems with the Symbol's constructors, but that is a D-related problem I
will solve.

A bit of context:

I started working on token constructors and I made them work for the type
of parser that uses %union.

I had trouble when I tried to implement api.value.type union.
(I initially thought I should implement variant, so that is why the second
patch uses it. I tried making my own b4_union_if, that was mimicking
b4_variant_if, but I had no luck, so this is why I still have b4_variant_if
in the code. Regardless, they should be similar enough at this stage.)
The problem is that when I use api.value.type union or variant, in yyaction(),
b4_user_actions uses the type of the union field instead of the union
field. For example:
{ (yyval.int) = ((yystack.valueAt (0)).int); }

Adela

[1] https://github.com/adelavais/bison/tree/token-constructors-squash

Attachment: 0001-d-create-token-constructors.patch
Description: Binary data

Attachment: 0002-d-add-api.value.type-union-support.patch
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]