[sr #110539] bison segv under Cygwin 64 in fatal-signal.c:318

2021-09-12 Thread anonymous
URL:
  

 Summary: bison segv under Cygwin 64 in fatal-signal.c:318
 Project: Bison
Submitted by: None
Submitted on: Sun 12 Sep 2021 06:03:14 PM UTC
Category: None
Priority: 5 - Normal
Severity: 4 - Important
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: brian.ing...@systematicsw.ab.ca
 Open/Closed: Open
 Discussion Lock: Any
Operating System: Microsoft Windows

___

Details:

Trying to package bison 3.8/.1 for Cygwin - previous releases to 3.7.6 built
and checked okay - bison 3.8.1 checked okay on 32 bit - all tests segv on 64
bit!

Reran build and check with bison 3.8 and 3.8.1 using gcc 10.2.0 and 11.2.0
with no change in all tests segv @ 0x0001. 

Build runs with autoreconf et al as per normal on 32 and 64 bit; adding debug
output allowed me see test commands to narrow down cause. 

Ran using gdb against tests/c/bistromathic/parse.y (see attached for gdb
command, script, and full log) getting the output below. 

It appears to be possible that `gl_lock_lock` expansion to `pthread_in_use() ?
pthread_mutex_lock(...)` -> glthread_in_use() ? ...` has avoided defining the
latter in the build, or some underlying dynamic library function may not be
loaded? 

Thread 1 "bison" hit Breakpoint 10, block_fatal_signals () at
/usr/src/debug/bison-3.8.1-1/lib/fatal-signal.c:318
318   if (mt) gl_lock_lock (fatal_signals_block_lock);
Continuing.

Thread 1 "bison" received signal SIGSEGV, Segmentation fault.
0x0001 in ?? ()
#0  0x0001 in ?? ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)



___

File Attachments:


---
Date: Sun 12 Sep 2021 06:03:14 PM UTC  Name: bison-segv-cygwin-64-gdb.sh 
Size: 223B   By: None
Attached gdb invocation command, gdb commands setup script, and gdb output log

---
Date: Sun 12 Sep 2021 06:03:14 PM UTC  Name: bison-segv-cygwin-64.gdb  Size:
1KiB   By: None
Attached gdb invocation command, gdb commands setup script, and gdb output log

---
Date: Sun 12 Sep 2021 06:03:14 PM UTC  Name: bison-segv-cygwin-64-gdb.log 
Size: 4KiB   By: None
Attached gdb invocation command, gdb commands setup script, and gdb output log


___

Reply to this item at:

  

___
  Message sent via Savannah
  https://savannah.gnu.org/




[sr #110669] error: ‘free’ of ‘yyss1’ which points to memory not on the heap

2022-06-02 Thread anonymous
URL:
  <https://savannah.gnu.org/support/?110669>

 Summary: error: ‘free’ of ‘yyss1’ which points to
memory not on the heap
 Project: Bison
   Submitter: None
   Submitted: Thu 02 Jun 2022 07:18:54 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: seir...@member.fsf.org
 Open/Closed: Open
 Discussion Lock: Any
Operating System: None


___

Follow-up Comments:


---
Date: Thu 02 Jun 2022 07:18:54 PM UTC By: Anonymous
GCC 11.2.0 -fanalyzer reports the following error in a generated parser:


error: ‘free’ of ‘yyss1’ which points to memory not on the heap
[CWE-590] [-Werror=analyzer-free-of-non-heap]


referring to the following part:


#  undef YYSTACK_RELOCATE
if (yyss1 != yyssa)
  YYSTACK_FREE (yyss1);
  }
# endif


Since this does not seem specific to my parser, I'm posting here.

This may be a false positive from the static analyzer, though.







___

Reply to this item at:

  <https://savannah.gnu.org/support/?110669>

___
Message sent via Savannah
https://savannah.gnu.org/




[sr #110801] C++ example directories are missing necessary files

2022-12-13 Thread anonymous
URL:
  <https://savannah.gnu.org/support/?110801>

 Summary: C++ example directories are missing necessary files
 Project: Bison
   Submitter: None
   Submitted: Tue 13 Dec 2022 07:02:56 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: gy...@stebbi.is
 Open/Closed: Open
 Discussion Lock: Any
Operating System: GNU/Linux


___

Follow-up Comments:


---
Date: Tue 13 Dec 2022 07:02:56 PM UTC By: Anonymous
The files necessary to build the examples in `examples/c++/` are listed in the
`.gitignore` file for some reason and thus not avaiable in the remote source
repository.







___

Reply to this item at:

  <https://savannah.gnu.org/support/?110801>

___
Message sent via Savannah
https://savannah.gnu.org/




[sr #108335] git access request

2013-07-05 Thread anonymous
URL:
  

 Summary: git access request
 Project: bison
Submitted by: None
Submitted on: Fri 05 Jul 2013 09:44:11 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Private
 Assigned to: None
Originator Email: valentin.tol...@gmail.com
 Open/Closed: Open
 Discussion Lock: Any
Operating System: None

___

Details:

Hello,

My name is Valentin Tolmer, and I'm working with Akim Demaille on Bison (I'm
doing a Google Summer of Code), and I'd like to be able to access the bison
git repository to share my progress (on separate branches, of course).

Thank you

Valentin Tolmer




___

Reply to this item at:

  

___
  Message sent via/by Savannah
  http://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #108364] Makefile uses `perl -f` without checking for availability

2013-08-16 Thread anonymous
URL:
  

 Summary: Makefile uses `perl -f` without checking for
availability
 Project: bison
Submitted by: None
Submitted on: Fri 16 Aug 2013 04:39:53 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: mi...@brew.sh
 Open/Closed: Open
 Discussion Lock: Any
Operating System: Mac OS

___

Details:

The bison makefile uses `perl -f` for its extract script, but doesn't check
for availability of that flag.

The `-f` flag, which ignores $sitelib/sitecustomize.pl at startup, was added
to perl sometime after 5.8. I encountered this error when trying to install
bison on Mac OS X 10.4.11, which shipped with perl 5.8.6. Bison doesn't have a
documented perl version requirement that I can find, and the configure script
accepted the version of perl found.

Perl exits with an error on encountering unknown flags, so the bison build
fails instantly because of this.

Sample extract variable from the makefile:

> extract = VERSION="$(VERSION)" $(PERL) -f $(extexi) $(doc) --




___

Reply to this item at:

  

___
  Message sent via/by Savannah
  http://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #108481] Assertion `!yytname_' failed.

2014-01-23 Thread anonymous
URL:
  

 Summary:  Assertion `!yytname_' failed.
 Project: bison
Submitted by: None
Submitted on: Thu 23 Jan 2014 04:30:53 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: amsilvacorr...@hotmail.com
 Open/Closed: Open
 Discussion Lock: Any
Operating System: GNU/Linux

___

Details:

Hi all,
I was testing error recovery with bison and I'm getting this assertion here:

/// Instantiate an empty \a T in here.
template 
T&
build ()
{
  YYASSERT (!yytname_);
  YYASSERT (sizeof (T) <= S);
  yytname_ = typeid (T).name ();
  return *new (yyas_ ()) T;
}
when using this simple grammar.

%token  CHAR  "char"
%token   NUM   "number"
%tokenSEMICOLON ";"
%tokenEND   0   "end of file"

%%

stms : stms CHAR ";"
 | CHAR ";"
 | error ";"{yyerrok;}
 ;

%%

I've used bison 3.0.2 and flex 2.5.37.
I'm attaching all the code I used with this test.

I was expecting two error messages, and in fact I get those messages when I
remove the parse.assert definition.

I used g++ *.cpp -o test to compile the code, after bison and flex.

Cheers,
Antonio



___

File Attachments:


---
Date: Thu 23 Jan 2014 04:30:53 PM UTC  Name: assert_error.zip  Size: 34kB  
By: None
Example to reproduce the problem


___

Reply to this item at:

  

___
  Message sent via/by Savannah
  http://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #108692] generated src/scan-gram.c file does not compile

2014-11-28 Thread anonymous
URL:
  

 Summary: generated src/scan-gram.c file does not compile
 Project: bison
Submitted by: None
Submitted on: Sat 29 Nov 2014 12:07:07 AM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
Operating System: None

___

Details:

For bison 3.0.2.

tar xpfz bison-3.0.2.tar.gz
cd bison-3.0.2
mv src/scan-gram.c src/scan-gram.c.orig
./configure
...
make
  GEN  examples/extracted.stamp
extexi:  GEN examples/rpcalc/rpcalc.y
extexi:  GEN examples/mfcalc/mfcalc.y
extexi:  GEN examples/mfcalc/calc.h
extexi:  GEN examples/calc++/calc++-driver.hh
extexi:  GEN examples/calc++/calc++-driver.cc
extexi:  GEN examples/calc++/calc++-parser.yy
extexi:  GEN examples/calc++/calc++-scanner.ll
extexi:  GEN examples/calc++/calc++.cc
  GEN  lib/alloca.h
  GEN  lib/configmake.h
  GEN  lib/c++defs.h
  GEN  lib/arg-nonnull.h
  GEN  lib/warn-on-use.h
  GEN  lib/fcntl.h
  GEN  lib/getopt.h
  GEN  lib/inttypes.h
  GEN  lib/math.h
  GEN  lib/signal.h
  GEN  lib/spawn.h
  GEN  lib/stdio.h
  GEN  lib/stdlib.h
  GEN  lib/string.h
  GEN  lib/sys/stat.h
  GEN  lib/sys/types.h
  GEN  lib/sys/wait.h
  GEN  lib/time.h
  GEN  lib/unistd.h
  GEN  lib/unitypes.h
  GEN  lib/uniwidth.h
  GEN  lib/wchar.h
  GEN  lib/wctype.h
  LEX  src/scan-gram.c
make  all-recursive
make[1]: Entering directory `/export/home/kim/tmp/bison-3.0.2'
Making all in po
make[2]: Entering directory `/export/home/kim/tmp/bison-3.0.2/po'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/export/home/kim/tmp/bison-3.0.2/po'
Making all in runtime-po
make[2]: Entering directory `/export/home/kim/tmp/bison-3.0.2/runtime-po'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/export/home/kim/tmp/bison-3.0.2/runtime-po'
Making all in .
make[2]: Entering directory `/export/home/kim/tmp/bison-3.0.2'
  CC   src/bison-AnnotationList.o
  CC   src/bison-InadequacyList.o
  CC   src/bison-LR0.o
  CC   src/bison-Sbitset.o
  CC   src/bison-assoc.o
  CC   src/bison-closure.o
  CC   src/bison-complain.o
  CC   src/bison-conflicts.o
  CC   src/bison-derives.o
  CC   src/bison-files.o
  CC   src/bison-getargs.o
  CC   src/bison-gram.o
  CC   src/bison-graphviz.o
  CC   src/bison-lalr.o
  CC   src/bison-ielr.o
  CC   src/bison-location.o
  CC   src/bison-main.o
  CC   src/bison-muscle-tab.o
  CC   src/bison-named-ref.o
  CC   src/bison-nullable.o
  CC   src/bison-output.o
  CC   src/bison-parse-gram.o
  CC   src/bison-print-xml.o
  CC   src/bison-print.o
  CC   src/bison-print_graph.o
  CC   src/bison-reader.o
  CC   src/bison-reduce.o
  CC   src/bison-relation.o
  CC   src/bison-scan-code-c.o
  CC   src/bison-scan-gram-c.o
In file included from src/scan-gram-c.c:3:0:
src/scan-gram.c: In function 'gram_lex':
src/scan-gram.l:49:4: error: 'code_start' undeclared (first use in this
function)
code_start = scanner_cursor = loc->start;\
^
src/scan-gram.c:1402:3: note: in expansion of macro 'YY_USER_INIT'
   YY_USER_INIT;
   ^
src/scan-gram.l:49:4: note: each undeclared identifier is reported only once
for each function it appears in
code_start = scanner_cursor = loc->start;\
^
src/scan-gram.c:1402:3: note: in expansion of macro 'YY_USER_INIT'
   YY_USER_INIT;
   ^
make[2]: *** [src/bison-scan-gram-c.o] Error 1
make[2]: Leaving directory `/export/home/kim/tmp/bison-3.0.2'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/export/home/kim/tmp/bison-3.0.2'
make: *** [all] Error 2


The generated src/scan-gram.c is NOT the same as the one included in
bison-3.0.2.tar.gz.  The code in the definition of the YY_DECL function has
the user's preamble code placed after the first use of the code_start
variable.






___

Reply to this item at:

  

___
  Message sent via/by Savannah
  http://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #109570] build failure: timevar.o isn't included in lib/libbison.a

2018-10-17 Thread anonymous
URL:
  

 Summary: build failure: timevar.o isn't included in
lib/libbison.a
 Project: bison
Submitted by: None
Submitted on: Wed 17 Oct 2018 04:44:54 PM UTC
Category: None
Priority: 5 - Normal
Severity: 5 - Blocker
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: vonbr...@inf.utfsm.cl
 Open/Closed: Open
 Discussion Lock: Any
Operating System: GNU/Linux

___

Details:

This is version v3.1.90-1-gf5fc2124.

Build fails, due to the above. The lib/timevar.c file isn't even compiled.

Workaround is to:

`make lib/timevar.o`
`cd lib; ar r libbison.a timevar.o`

and then restart make.




___

Reply to this item at:

  

___
  Message sent via Savannah
  https://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #109571] Build assumes YACC is bison...

2018-10-17 Thread anonymous
URL:
  

 Summary: Build assumes YACC is bison...
 Project: bison
Submitted by: None
Submitted on: Wed 17 Oct 2018 04:47:31 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: vonbr...@inf.utfsm.cl
 Open/Closed: Open
 Discussion Lock: Any
Operating System: GNU/Linux

___

Details:

Version is v3.1.90-1-gf5fc2124

Here `/usr/bin/yacc` is byacc, so the build fails.

Workaround is `make YACC='bison -y'`




___

Reply to this item at:

  

___
  Message sent via Savannah
  https://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #109580] .PHOMY in examples/local.mk

2018-11-07 Thread anonymous
URL:
  

 Summary: .PHOMY in examples/local.mk
 Project: bison
Submitted by: None
Submitted on: Wed 07 Nov 2018 05:55:22 PM UTC
Category: None
Priority: 5 - Normal
Severity: 2 - Minor
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: vonbr...@inf.utfsm.cl
 Open/Closed: Open
 Discussion Lock: Any
Operating System: None

___

Details:

This appears in v3.2-17-g351e3630, examples/local.mk:

`dist-hook: examples-unline
.PHOMY: examples-unline
examples-unline:`

It is presumably .PHONY




___

Reply to this item at:

  

___
  Message sent via Savannah
  https://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison


[sr #110032] For C++98 stack_symbol_type defines only non-const operator=

2019-09-25 Thread anonymous
URL:
  

 Summary: For C++98 stack_symbol_type defines only non-const
operator=
 Project: Bison
Submitted by: None
Submitted on: Wed 25 Sep 2019 04:38:56 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: ad...@onica.com
 Open/Closed: Open
 Discussion Lock: Any
Operating System: None

___

Details:

Setting the output language to C++ and compiling the output with a C++98
compiler, compilation fails on the IAR C++ compiler (version 6.70.2.6274).

The std::vector class of the IAR compiler relies on operator= in its push_back
implementation. Defining 'stack_symbol_type &operator=(stack_symbol_type &)'
stops the compiler implicitly generating operator= for other arguments.
Specifically 'const stack_symbol_type &operator=(const stack_symbol_type &) is
missing which is needed by std::vector::push_back.

The lalr1.cc skeleton needs to be changed to also define the const operator=
for stack_symbol_type (and also others like sematic_type when using variants)




___

File Attachments:


---
Date: Wed 25 Sep 2019 04:38:56 PM UTC  Name: PropertyNameParser.y  Size: 800B 
 By: None


---
Date: Wed 25 Sep 2019 04:38:56 PM UTC  Name: iar_error.txt  Size: 2KiB   By:
None



___

Reply to this item at:

  

___
  Message sent via Savannah
  https://savannah.gnu.org/


___
help-bison@gnu.org https://lists.gnu.org/mailman/listinfo/help-bison