-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Description
Build on f43 has these yacc warnings:
...
index-parse.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
index-parse.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
index-parse.y: note: rerun with option '-Wcounterexamples' to generate conflict counterexamples
...
updating index-parse.h
/usr/bin/make all-am
LEX index-scan.c
Running with -Wcounterexamples gives this output. I have not attempted to make sense of it, so I'm just documenting it here
/home/crobinso/src/guestfs-tools/builder/index-parse.y: warning: 2 shift/reduce conflicts [-Wconflicts-sr]
/home/crobinso/src/guestfs-tools/builder/index-parse.y: warning: 2 reduce/reduce conflicts [-Wconflicts-rr]
/home/crobinso/src/guestfs-tools/builder/index-parse.y: warning: shift/reduce conflict on token EMPTY_LINE [-Wcounterexamples]
First example: emptylines section EMPTY_LINE • EMPTY_LINE emptylines emptylines sections $end
Shift derivation
$accept
↳ 0: index $end
↳ 1: sections
↳ 4: emptylines section emptylines emptylines sections
↳ 13: EMPTY_LINE emptylines
↳ 13: • EMPTY_LINE emptylines
Second example: emptylines section EMPTY_LINE EMPTY_LINE • EMPTY_LINE emptylines section emptylines $end
Reduce derivation
$accept
↳ 0: index $end
↳ 1: sections
↳ 4: emptylines section EMPTY_LINE emptylines sections
↳ 13: EMPTY_LINE emptylines ↳ 3: emptylines section emptylines
↳ 12: ε • ↳ 13: EMPTY_LINE emptylines
/home/crobinso/src/guestfs-tools/builder/index-parse.y: warning: shift/reduce conflict on token EMPTY_LINE [-Wcounterexamples]
Example: emptylines section EMPTY_LINE • EMPTY_LINE emptylines section
Shift derivation
sections
↳ 4: emptylines section EMPTY_LINE emptylines sections
↳ 13: • EMPTY_LINE emptylines ↳ 3: emptylines section emptylines
↳ 13: ε ↳ 3: ε
Reduce derivation
sections
↳ 4: emptylines section EMPTY_LINE emptylines sections
↳ 12: ε • ↳ 3: emptylines section emptylines
↳ 13: EMPTY_LINE emptylines ↳ 3: ε
/home/crobinso/src/guestfs-tools/builder/index-parse.y: warning: reduce/reduce conflict on tokens $end, PGP_EPILOGUE [-Wcounterexamples]
Example: emptylines section EMPTY_LINE emptylines •
First reduce derivation
sections
↳ 4: emptylines section EMPTY_LINE emptylines sections
↳ 5: emptylines
↳ 12: ε •
Second reduce derivation
sections
↳ 3: emptylines section emptylines
↳ 13: EMPTY_LINE emptylines •
updating index-parse.h
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels